Can anyone offer any advice. I'd like to make a small device that has a single momentary button, that I can connect to a USB port on my PC, and have the PC perform an action when I press the button.
I've used an Arduino demi in a project and was really impressed with how easy it was. I could quite easily make what I want using one, but it's a bit overkill.
Can anyone point me at any resources for the simplest way to hook up a microcontroller to a single switch and a USB interface? Something like the u-hid would also do the job, but I can't seem to find any UK suppliers, and it's not all that cheap either. I also like the idea of a programmable microcontroller attached to the switch so I could write whatever software I wanted for the PC, rather than use a keypress like interface.
Thanks for the help. I like the look of the teensy a lot, but getting it from the US could bump the costs up. I hadn't thought about ripping a control pad apart, but that's a very interesting idea too, I'll have to look into that.
I've also just found this AVR-Stick that I'm going to look into a bit too. It certainly fits the small and cheap requirement
The game pad approach is probably the simplest and lowest cost assuming that you can map the gamepad events to something useful like a keypress event in a the gamepad driver.
Something else you might want to look at is to see how the USB Palm cradles worked; you can still buy interface cables and cradles on Ebay on occasion (mostly the former from shenzhen; I typically see cradles at thrift stores). Since there are drivers and such for Linux, finding the code to see how they work shouldn't be too difficult...
It says it can be a keyboard, so maybe that is all you need to do.
Give your PC program focus, and it could maybe send the right key to do what you want.