View Full Version : PIC to USB
Christopher4187
- 26th February 2006, 01:12
Hi,
Has anyone used a PIC to communicate with a USB port in Visual Basic 2005? I know Microchip makes at least four different PIC's that can communicate via USB but I had a different idea. However, if you have done that I am curious how difficult it was to create the code. I was thinking about using the Linx Technologies module SDM-USB-QS-S for this. I was going to try and use a 16F676 to the SDM-USB-QS-S to the USB port. If anyone has done this, please chime in and let me know how this has turned out.
Thanks,
Chris
Tissy
- 26th February 2006, 03:23
I have used the PIC18F2550 / 2455 and the PIC18F4550 and it they are reasonably easy to use.
If you are obviously using PIC Basic then i strongly recommend you download EasyHID which will generate a base code in PIC Basic and VB for use with this PICs. With this base platform in both languages generated for you, it will assist as a excellent starting block for your project.
It generates the HID and PID codes also for you for specific USB device recognition.
EasyHID can be downloaded free at http://www.mecanique.co.uk/products/usb/easyhid.html
Sending data too and from the PIC is reasonably easy.
The other option is to use standard RS-232 but then use one of FTDI range of chips to give you that simple USB interface with no additional components.
Hope this helps,
Steve
Christopher4187
- 26th February 2006, 04:43
Thanks for the reply. I have looked at the Easy HID but I wasn't sure exactly what I need it for. If I know PBP and know VB, do I still need easy HID? I have heard mixed results about it and I wasn't sure if I should still download it. Really, the only part I am not experience in is how to get the data from VB to the USB port. This is an new experience for me and this is where I am most confused.
Thanks,
Crhis
taos
- 26th February 2006, 08:39
I think this can be valid too:
Use a RS232 serial connection with PC (MAX232,etc...) that it's very simple (using comm ports in VB) and buy a RS-232 Serial to USB adapter and you can avoid USB interface with VB and PIC and use traditional serial programming and any PIC.
http://www.ramelectronics.net/html/usb_serial.htm
Regards.
dhouston
- 26th February 2006, 12:23
The Linx chip appears to be based on FTDI technology. (They use FTDI drivers)
http://www.ftdichip.com/
Silicon Labs has a less expensive, full speed single chip solution in a 5x5mm MLF package.
http://www.silabs.com/public/documents/tpub_doc/dshort/Microcontrollers/Interface/en/CP2102_short.pdf
Christopher4187
- 26th February 2006, 13:08
Thanks for the replies. I was so tired I spelled my first name wrong. I think the most cost effective way is to just use one of the PIC USB chips and go that route. Sooner or later, computers most likely won't have a serial port so I think I would have to start sometime. I have seen some schematics on the internet for a PIC to USB connection with some sample coding. I'll give that a try and see what I come up with.
Chris
Powered by vBulletin® Version 4.1.7 Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.