SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By b_w_
Ive been working on a project where Ill be driving say 30 or 40 unipolar stepper motors with the most minimal circuit I could imagine. Heres the first completed and fully working board:


Its basically a surface mount PICAXE08M (<- S.F. should really carry these), AKA a bootloaded 12F675, connected to a ULN2003 darlington array, with some 1k resistors and fancy wiring so 2 pins control the 4 coils of the motor, and a big 5w 5ohm current limit resistor going to the stepper. (Yes it does get hot but thats to be expected and it works anyway.)

My big hurdle was how to program the chips without an ICSP of one flavor or another. (I was being stingy on board real estate.) I decided to build a small 'programmer' for just the chip using the FTDI232R and a flip top burn in socket for SOIC08 chips. See here:


Flip the socket open and you see the little micro hiding inside...


Problem is it doesnt work and this is where I need some help. I based the entire thing off of the Sparkfun tutorial on eagle layout using the FTDI232R as an example.... ... 9-EaglePCB

Here is my version of the schematic:


The only changes I made to the Sparkfun design was to add a power LED off of the 3.3v out of the FTDI chip (mainly as a 'health' indicator) and I built in the 2 resistors that are required by the PICAXE for the serial programming. Here is their required circuit designed to plug into a serial cable of one form or another:


With me so far? When connected to the pc, the board powers up (I get my green light), the drivers installed the first time as usual, it assigns a com number and AFA the pc is concerned (windows vista) the com port is there and functioning as normal. But when I try the Programming Editor it sees the com port but will not download a program.

I have used my DMM to track down everything on the board and nothing AFAIK is shorted or doesnt connect to anything. I have verified that I get +5v at pin1 of the chip and GND at pin 8. What should be the TX pin of the FTDI chip is connected to the Serial In (pin2) of the PICAXE and the RX pin is connected to the Serial Out (pin7) of the PICAXE.

I must have totally spaced on something or another because I just cant figure out what I did wrong. Was the Sparkfun example correct and working? (I know not the first time but I made sure to connect my ground.) Is there something else I should have done or needed to get this thing to work? Any other thoughts or comments?

Thanks in advance for the time to look this over for me.

BTW, this is my first batch of boards directly through Gold Phoenix and I must say, with the help of Julian Bleeker's blog tutorial, the process was quick, painless, and Im wonderfully happy. Total turnaround in 7 days including weekends.
By busonerd

A typical PICAXE programmer takes RS232 serial levels and clamps them to 0-5V to feed the pic, which means 0V is a logical 1, and 5V is a logical zero [since -9V on the RS232 bus is a 1, and +9 is 0]. Your programmer is sending 0V as a 0, and 5V as a 1. If my guess is correct, you'll need to invert the TX/RX signals.


--David Carne
By b_w_
David, you are as usual totally correct. Following your advice and similar advice on the picaxe forum I did some research and found that this can be done in the eeprom of the chip. I downloaded Mprog from FTDI's website and followed their user manual to open up a profile, edited it to invert RX & TX, re-wrote the eeprom, and then re-cycled the device (to force windows to reload the driver). It worked like a charm in the programming editor and downloaded perfectly!

long long title how many chars? lets see 123 ok more? yes 60

We have created lots of YouTube videos just so you can achieve [...]

Another post test yes yes yes or no, maybe ni? :-/

The best flat phpBB theme around. Period. Fine craftmanship and [...]

Do you need a super MOD? Well here it is. chew on this

All you need is right here. Content tag, SEO, listing, Pizza and spaghetti [...]

Lasagna on me this time ok? I got plenty of cash

this should be fantastic. but what about links,images, bbcodes etc etc? [...]