PIC programming

Martin Naef EMAIL HIDDEN
Sun Jan 25 13:08:34 CET 2009


Hi Peter

Peter Korsten wrote:
> Has anyone of you ever built a dedicated PCB using a Microchip PIC 
> microcontroller?

Sorry, nope - just used the Midibox stuff on the PIC side.

> This PCB would present itself as two USB devices, and provide two serial 
> interfaces. Hence the choice for PIC and not AVR, because Atmel doesn't 
> seem to have MCUs with built-in USB support in a PDIP package, and I 
> don't see myself soldering an SMD component.

There are other solutions available in AVR land, though. But if the PIC 
does what you need, go for it.

If all you need is a USB to TTL serial port, there are a lot of turnkey 
solutions available that include the USB header, a dedicated controller 
chip in SMD format - e.g. 
http://www.sparkfun.com/commerce/product_info.php?products_id=8165 or 
even one the "USB cables" with TTL serial on the other end.

You can also use a normal TinyAVR to run the complete USB stack, there 
is free source code available on the net.

Anyway, that's not to convince you to use an AVR, just to show that 
there might be other ideas.

> Anyway, the chip is one thing, but it needs to be programmed as well. 
> And that's where my question comes in. Basically, I have three choices:
> 1: Build a programmer myself. But the designs you find on the net are 
> usually not for 20-pin and/or PIC18 devices.
> 2: Get the PicKit2 programmer for some $35 + shipping + tax.
> 3: Get one of these kits for some $50 + shipping + tax.

Whatever you do, make sure you can program your chip in the system; like 
on my multiswitch project http://www.navisto.ch/diy.electronics.html, 
where a small 6pin header (top right) connects to the AVR ISP. It's a 
pain if you have to remove the chip from your board for programming (as 
with the lower example on the same page).

> What would be the best option? It would really be an exercise in low 
> cost, but I would also like to retain the option of building and 
> programming a couple more and selling them.

Low cost in total development terms, or low cost per board?

Martin




More information about the music-bar mailing list