Small dev board with USB HID and a couple of digital IOs - Page 1
Forum section: electronics / general

author: apelly
author_rank: Unknown
timestamp: February 01, 2016, 07:05:32 pm
content: Howdy guys,Maybe someone has this in their head already and can save me an hour of research:I have in mind a simple project to map a SPST switch to a keypress on a keyboard.I seem to remember one of the arduinos has USB HID in the CPU, and I recall this being more versatile than a separate device, but I can't remember why. Something programmable over USB would save me some drama too since I have limited gear on hand for the moment.I don't really care what device it is, but I'm imagining some Chinese arduino for a fiverAny thoughts?

author: Jeroen3
author_rank: Super Contributor
timestamp: February 01, 2016, 08:25:25 pm
content: Basically any USB capable micro will have an USB HID example project on their demo kit.

author: Brutte
author_rank: Frequent Contributor
timestamp: February 01, 2016, 08:29:47 pm
content: Any HID mice around?

author: android
author_rank: Regular Contributor
timestamp: February 01, 2016, 08:37:55 pm
content: This is one I designed a while back using a PIC18FK2550 (about $3)...http://www.instructables.com/id/PUB-Programmable-USB-Button/You could easily replace the rotary encoder with a SPST switch (but you would lose the programmability feature)

author: apelly
author_rank: Unknown
timestamp: February 01, 2016, 09:07:59 pm
content: Quote from: android on February 01, 2016, 08:37:55 pmNice. Looking for a dev board though.

author: firehopper
author_rank: Frequent Contributor
timestamp: February 01, 2016, 09:14:21 pm
content: arduino leonardo or pro micro both use the same chip and can do hid keyboard or mouse.

author: apelly
author_rank: Unknown
timestamp: February 01, 2016, 09:44:57 pm
content: Thanks firehopper. Just grabbed a pro micro clone from ebay.

author: AlxDroidDev
author_rank: Frequent Contributor
timestamp: February 01, 2016, 09:48:43 pm
content: Quote from: firehopper on February 01, 2016, 09:14:21 pmI was about to suggest the Leonardo too. Great little board, and can do wonders.

author: westfw
author_rank: Super Contributor
timestamp: February 02, 2016, 06:36:53 am
content: Also any of the "Teensy" boards fromhttp://pjrc.comLast time I actually DID something l iike this, I just ripped the controller out of a "physically damaged but electrically OK" keyboard like most of us have lying around.

author: Fred27
author_rank: Unknown
timestamp: February 02, 2016, 09:55:39 am
content: How about the MSP430F5529 LaunchPad?

author: Kilrah
author_rank: Unknown
timestamp: February 02, 2016, 02:39:59 pm
content: I'd go with the Teensy as well, the USB HID software libraries are simplified so much that you could literally do what you want in about 5 mins.

author: apelly
author_rank: Unknown
timestamp: February 02, 2016, 06:39:01 pm
content: Thanks guys. Maybe next time.

author: firehopper
author_rank: Frequent Contributor
timestamp: February 02, 2016, 06:40:53 pm
content: Quote from: apelly on February 01, 2016, 09:44:57 pmgo to sparkfun's leonardo page they give code snippets on how to do exactly what you seem to want.

author: apelly
author_rank: Unknown
timestamp: February 02, 2016, 07:00:30 pm
content: Quote from: firehopper on February 02, 2016, 06:40:53 pmYea. I kind of hate doing that; buy cheap shit then leech off people making an actual contribution.That's probably what Iwilldo though.I buy an occasional non-urgent thing from them to make up for it. That doesn't help the arduino guys I suppose. Whoevertheyare these days. But I'm going to use their environment anyway.

author: Brutte
author_rank: Frequent Contributor
timestamp: February 02, 2016, 08:18:03 pm
content: My favourite dev board is STM32L-Discovery. About $15, debugger is on board.USB library is the same as for popular STM32F103, lots of examples, not only from ST.Dev board comes with a 6 x 14-segment LCD and a CR2032 holder footprint at the back (but no holder or battery provided) which is good for field testing, logging etc.

author: apelly
author_rank: Unknown
timestamp: February 06, 2016, 09:13:32 pm
content: Quote from: Brutte on February 02, 2016, 08:18:03 pmNice. Good price too.Overkill for what I'm after though. In my digikey cart is one of the LXP ones. Quite cheap, with integrated debugger too.

author: TheDirty
author_rank: Frequent Contributor
timestamp: February 07, 2016, 02:42:33 am
content: Digispark will do this and is even simpler than the Teensy and you can e-bay it for cheap. The examples come with HID Mouse, Keyboard, CDC, ...

author: apelly
author_rank: Unknown
timestamp: February 07, 2016, 06:56:24 am
content: VUSB would have been fine. Had I known about it.Not to worry. I'm sorted now thanks.

author: Brutte
author_rank: Frequent Contributor
timestamp: February 07, 2016, 04:47:22 pm
content: Quote from: apelly on February 06, 2016, 09:13:32 pmIt is NXP. Their uCs are marked with LPCxxxx. The LPC1347 (64k flash+12k sram) is their flag USB device product. It comes onLPCXpresso LPC1347and it is around $20.So, if you are a Freescale fan, you can try KinetisFRDM-KL25Z, also $15, debugger on-board of course. This is a more sophisticated uC and can work as USB device or as USB host.

author: apelly
author_rank: Unknown
timestamp: February 07, 2016, 07:39:42 pm
content: Quote from: Brutte on February 07, 2016, 04:47:22 pmDon't know what I was thinking.Quote from: Brutte on February 07, 2016, 04:47:22 pmNice board at a nice price!