Is there any way for me to set up my Mindstorms robot so that when I push one of the touch sensors it sends a signal to the computer to press a key?

  • Is the computer in question capable of receiving Bluetooth messages?
    – Ambo100
    Commented Oct 5, 2013 at 17:38

1 Answer 1


Yes, this is possible.

First, you'll want to connect your NXT to the computer using Bluetooth. Make sure you can connect to it with the official LEGO Software programming environment, NXT-G, and that the computer connection will show up when you go to Bluetooth > Connections.

Next, you'll want to create a simple program in NXT-G and download it to your NXT. It should basically send a Bluetooth message to the computer, using Mailbox #1 and a number variable containing the value of the key pressed. If you need help with this part, I can provide detailed steps.

Finally, you'll want to use a program called InstantEXE 3.0 (the free version works!) to receive the Bluetooth signal and use the command "Keys" to simulate the key or key sequence that you want to be triggered when the button is pressed. You can expand this with your sensors, e.g. when touch sensor #1 is pressed send it with a value and intercept this on the computer, using InstantEXE 3.0 to convert it into a keysequence. If you need help with this part, I can provide detailed steps and/or a sample program for you to use. You could use some basic labels like the following script:


Keys "L"


Keys "C"


Keys "R"

  • 1
    I know this is an older post but I've just bumped into the same problem. May I ask where can I find InstantEXE 3.0 nowadays? The original site is down and I don't really want to use any of the "download" sites that claim they have it. If its completely dead, may I ask where can I find a similar program that can do practically the same? (If I get it right then it converts bluetooth messages to keystrokes)
    – Tornith
    Commented Oct 15, 2016 at 11:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.