Saturday, January 22, 2011

Oh, SURE!

I've been pretty busy this week.  I made up for the lost day at work and then some.

I did play a little on Tuesday night and again tonight.

I received the following toy on Tuesday:


This is a clone (exact, it takes real Microchip firmware) of a PICKIT 3 programmer.  It's from Sure Electronics in Hong Kong and.. well it's available on everyone's favorite site, e-bay.  Overall it's an exact clone.  Having said that, it's a typical Microchip programmer.. could have been great if thought through a little better, but it is not quite there.  Most of the complaints you'll hear about the PICKIT 3 online are true.  But I needed something to program PIC32MX's as they are one of my favorite choices for Microcontrollers now as they are very powerful, not very power hungry, have lots of I/O and are as cheap or less than the 8-bit ATMEL's* (like the one I built below.)  The 3rd generation programmers like the PICKIT3 and the ICD3 are the only ones that do the newer PIC32MX's.  They also program the DSPIC33's like the SDR-Cube uses, so since my older serial-port and parallel port based programmers couldn't do these newer devices... I decided to go for it.

The Chinese clone was nice as it's a good $25 cheaper shipped... and for a couple of bux more you can get that nifty ZIF socket board for the older 5V DIP 8-bit PICs.  But unfortunately, do to the fact that the charge pumps suck in the PICKIT 3 design... not all will work while internally powered.  So you'll see in a future post me redoing a simple 7812/7912/7805 based supply that I built for small microcontroller work in the late 1980's to also add a TO-220 based +3.3V supply to it for use with the newer microcontrollers.  What I am saying is that the charge pump is really only good for the 20 mA that Microchip claims.. and some of the older devices are so close to that hairy edge in normal draw that they don't work in self-powered mode.  Life will be better when I stop trying to power the devices with te charge pump on the PICKit3 and instead use external power.  It's supposed to be an "in circuit programmer" so one (probably a marketing guy from Microchip) could say that the internal power is a "bonus."  It's really a "bogus" in actual use though.

I tried a PIC 16F877A in the socket with the PICKIT 3 self powered and it works fine.  A PIC 16F871, basically the same series.. draws too much current.. the supply sags to 3.5V and the device ID's okay, programs OK, Erases OK but can't read back!  If I hack a cable to provide external 5V (and 3.3V) to that ZIF socket board, I assume all will program fine.

There are also several older devices I use (like 12C and 16C devices) that the PICKIT2/3 can't program either..  so I'm disappointed that I can't chuck my older 2001 era serial port based programmers.

Anyway.. I read the SDR-CUBE's data in with it OK (which is externally powered, of course), a CUI32 board's (PIC32MX) data being powered from the PICKIT 3, the 16F877A was programmed and read back.  And tonight I got my e-bay special board ($1.65) from Thailand (etteam DSPic/PIC32 protocard) and a sample PIC32MX360F512L (which has the same pinout as the DSPic33 on the SDR-Cube, but unfortunately the wrong pitch at 0.4mm instead of 0.5mm) to program.


This bugger gave me fits.  The trick here is that ALL Vcc and Vss lines need to be attached-- including AVcc and AVss-- and most should be bypassed with 0.1 uF.  But in addition.. on the DSPic's and PIC32MX's the cores run at 1.8V on these 3.3V devices.  Microchip put on an internal regulator.. which is the squirrliest one I've ever used.  Follow Microchip's advice on this.  10 uF 10V or greater Tantalum capacitor.  Don't try an electrolytic.. even a low ESR one.. and don't try only a 1 uF Tant.. it won't work.  It looks like that regulator rings on startup with all but the correct 10 uF Tant...  It was muy muy bogus figuring that out.  I suppose if I had 50 10 uF's instead of 1 uF chip tantalums in the surplus section of the junk box I would have not figured this out.  I'll have to get me some from e-bay China :O)  I'm using a leaded tant tack soldered for now on this board.

I'm starting to wonder why I use DIP IC's for anything now.  There are easily 2x the IO lines on that board than the ATMEL board I'm using for the PA project.  This sucker has 2x the memory and 20 times the processing power, consumes less current.. has many 5V tolerant lines on it... I almost wonder if I should use it instead of the ATMEGA.  Not necessary as there need not be much processing power.. but now you see that you can use the most modern processors in your design.  They are faster, cheaper and better than the older processors.

I'd still like to port the SDR-Cube code over to this processor.  I have some TI CODEC's that I sampled around here.. and could probably make a "lite" version that's controlled over RS-232 instead of the very fine GUI for proof-of-concept in the port.  I'm sure this will take me awhile.  But I think the performance will be better than 2x the throughput of the DSPic33.  

I'm very tempted to sample off a MX7xx series part, a and a PHY, and try to get Ethernet running on my protoboards.. but I'll worry about that in a few months time.  The Lite MX SDR-Cube streaming UDP over Ethernet seems like an interesting concept, tho.

2 comments:

  1. You get what you pay for, so this is what you should expect when you buy a Chinese clone product. My REAL Microchip PICKIT3 easily drives 100 mA circuits without any problems. dsPIC33's, MX32's, etc. all program in-circuit just fine. Microchip regularly under-estimates the specs on their products. On the other hand companies like Sure Electronics sell products from bad designs using sub-standard parts. If that works for you, then fine; it's a cheap way to go. But you shouldn't expect it to be up to Microchip standards.

    ReplyDelete