PORTS Forum

Ports and Interfaces => USB => Topic started by: ivordurham on August 07, 2013, 01:50:29 pm

Title: Seeking RS232 to USB-HID advice
Post by: ivordurham on August 07, 2013, 01:50:29 pm
I need to connect several types of animal microchip (RFID) scanner which have RS232 interfaces to USB. I have this working with standard serial to USB adapter cables but the user has to run a software keyboard wedge to have the RFID reader deliver keyboard input like, say, a bar code reader. (I haven't even looked for a Mac wedge yet.) Making sure the wedge is running with the right baud rate etc. for the COM port would be a challenge for some of the mostly non-techie animal rescuers I'm trying to help. The local city shelter IT departments aren't going to allow a random piece of software to be installed on their users' desktops. So I probably need to find/build a HID solution that is just plug-n-play.

I found one product by Intelletto (http://intelletto.com/converter_cable_overview.htm) but that is both prohibitively expensive ($99) and not found in retail outlets. I'm wondering if it makes sense to try something like Silicon Labs HID USB to UART Development Kit ($39; http://www.mouser.com/ds/2/368/CP2110-EK-25881.pdf) since it is a programmable solution with both RS232 and USB interfaces. I've even wondered about trying a DB9-PS/2 adapter and then a USB to PS/2 keyboard/mouse adapter. So if anyone else has already tackled the RS232 to USB-HID problem or has any suggestions on other pragmatic and relatively inexpensive approaches to building an RS232 to USB-HID adapter, I'd be very grateful. Thanks.
Title: Re: Seeking RS232 to USB-HID advice
Post by: Jan Axelson on August 07, 2013, 02:57:37 pm
If you want a hardware-only solution to duplicate what you have, a search on

keyboard wedge hardware serial

brings up some products that will make serial data look like data from a keyboard. Some also convert to USB, saving the expense of a serial/USB converter.

The Silicon Labs kit looks like it enumerates as a generic HID, not a keyboard, so you would need to provide an application to read the data.

For the DB9 - PS/2 - USB adapters idea to work, I think the DB9 would need to receive serial keyboard data, not raw serial data.
Title: Re: Seeking RS232 to USB-HID advice
Post by: ivordurham on August 11, 2013, 04:33:17 pm
Thank you. It looks like each of the available hardware options has at least one disqualifying drawback mostly very high cost or lacking particular serial speed support (WedgeLink HW $239, Vetray SmartPipe VIP-335, $179, no 19.2Kb support). It looks like I need to read your book and decide whether or not I could tackle this as a recreational DIY project.
Title: Re: Seeking RS232 to USB-HID advice
Post by: bpaddock on August 15, 2013, 12:57:32 pm
If this is a one-off or small number for units pick up a Freescale Freedom Board for about $12 depending on your location:

https://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=FRDM-KL25Z

I have working HID code with serial I/O.  This is not a direct conversion you'll have to tweak the simple demo program.
  You'd need to add a box. You'd have to had a TTL to RS232 level convert chip.

I want to put the HID code on Github, but I could put it in a .zip file sooner.



Title: Re: Seeking RS232 to USB-HID advice
Post by: ivordurham on August 18, 2013, 04:31:21 pm
This sounds promising! I already have a couple of RS232 to TTL boards. I can order a FRDM-KL25Z. It looks like I need to solder on headers for prototyping. Please let me know when you have the code on github. No need to make a special package because I can only work on this as a background task now. Thanks.