View previous topic :: View next topic |
Author |
Message |
vinniewryan
Joined: 29 Jul 2009 Posts: 154 Location: at work
|
PC detecting PIC as USB device |
Posted: Wed Sep 23, 2009 12:31 am |
|
|
I've never programmed for USB, and I'm just wondering if I can achieve what I need with the PIC I have.
I'm using the 16f684, and I want to add a USB port to it, with a program that automatically installs to the connected PC so it recognized the device, then connects to the internet and downloads a firmware upgrade for the PIC, and installs it to the PIC, so the PIC now has an updated program. This all needs to be automatic though. I don't want the user to have to do anything other than click "automatically install this hardware" after plugging the usb cable into their PC.
Can this be done without any external hardware? If not, what should I expect to look into? I've read up on USB connections, but couldn't find anything like this. _________________ Vinnie Ryan |
|
|
FvM
Joined: 27 Aug 2008 Posts: 2337 Location: Germany
|
|
Posted: Wed Sep 23, 2009 1:45 am |
|
|
Quote: | Can this be done without any external hardware? | No. Not with a PIC16.
Read about PIC processors with USB interface, e.g. PIC18F4550. |
|
|
John P
Joined: 17 Sep 2003 Posts: 331
|
|
Posted: Wed Sep 23, 2009 8:18 am |
|
|
I'm pretty sure the PIC16F684 has no UART and can't reprogram itself; to reprogam, it has to be totally shut down. It's not the chip for the job. |
|
|
treitmey
Joined: 23 Jan 2004 Posts: 1094 Location: Appleton,WI USA
|
|
Posted: Wed Sep 23, 2009 8:43 am |
|
|
Take note of what John said above.
But if you did have a hardware UART and the chip was able to self-program,
I would humbly suggest a FTDI FT232R chip.
http://www.ftdichip.com/Documents/DataSheets/DS_FT232R_V204.pdf
With just a little external hardware it is up and running.
To the PC and PIC side it looks like a serial port.
That means boot loaders should work without changes.
That is probably the easiest way for a beginner. |
|
|
|