Go Down

Topic: Arduino PC key event ? (Read 656 times) previous topic - next topic

Fs40k

Hey ,
i'm new in the Forum and just 13 years old , so sorry for my bad english.My qustion is how i can do that when i press a button that the Pc see that as a Key event without any usb shild or so... ?

PaulS

Quote
My qustion is how i can do that when i press a button that the Pc see that as a Key event

The Arduino has no idea what a key event is. The only way for an application on the PC to communicate with the Arduino is via the serial port.

So, you'll need to create an application on the PC that recognizes key events and sends something to the Arduino, via the serial port.

Various languages can be used to develop such an application, and there are links on the Playground to help you with some of them. I like C# because it makes communicating with the serial port very easy. There are free versions of Visual C# available from Microsoft if you want to go that route.

Processing is another good choice (http://Processing.org)

Fs40k

first thank you ! can you show me a link on playground or on processing ?  :smiley-surprise:

PaulS

Quote
can you show me a link on playground

http://arduino.cc/playground/Main/InterfacingWithSoftware
Scroll down to find a list of the languages that people have documented how to use. Pick one you are familiar with. If none, pick one you want to learn.

Quote
or on processing

Download and install Processing. Just like the Arduino IDE, Processing comes with a lot of examples. Use File + Examples... to open a dialog. Scroll down to Libraries + Serial I/O to see how to send data to/read data from the serial port. Look at Basics + Input to find keyboard examples.

Go Up