Olimex AVR-PG1B Issues

I just started building the [serial programmer from olimex and hooked it up on my laptop with my usb-rs232 (with full rts/cts capabilities) and ponyprog wont read or write anything.

So I went to my desktop that has two onboard serial ports. I found COM1 by plugging in my max232 breakout and shorting rx/tx and I get loopback.

I plugged in the avr-pg1B and put my scope (Tek 2225 - 2ch 50mhz) applied power to my programming board without a chip. I get 5V at ICSP pin 2 and GND on ICSP 4/6/8/10 as one wants. I put my scope on pin7 (SCK) and pin1 (MOSI)

I then load pony prog and ignore the errors and do read/writes and watch the pins and I get nothing but noise on SCK and MOSI toggles from -12 to +12 about 10times then goes to +12 and alot of noise.

What am I doing wrong here? pony prog is set up as spi prog api - com1 and im using a 3ft serial cable.

Does anyone know a good serial port checker that will allow me to set each pin individually to make sure my port works correctly? Other than that I can only guess that pony prog cant access the hardware right.](http://www.olimex.com/dev/pdf/avr-pg1b.pdf)

serial port program - many. I like Bray’s terminal

Google brays terminal. One place

http://braypp.googlepages.com/terminal


MISO, MOSI, SCK are logic level signals. If you are seeing +/- 12V swings, either your scope is grounded wrong or some such, or there’s a big error in the circuitry like the zener diodes are missing, backwards, or some such.

It’s really worth the $30 or so to have a real Atmel ISP - these days they’re USB, not RS232.

The one your’ building tries to big-bank the logic levels via serial port toggles.

The avr was not in the cct no. The zerners are there to clamp the voltages to +5.1V I was just measuring before them to verify the ports output. With an avr is in the socket it gives the same VERY noisy signals and CLK only runs a few times then stays high.

Whats the usual sequence for programming. I would imagine RESET is held low, clock is a consistant square wave for the duration and serial data in on MOSI then reset. on the read command same thing except data on MISO.

Right now Reset is always high (serial pin 4 doesn’t toggle) serial pin 6&7 (CLK) toggle ~10times irradicly on the scope and then fuzzy noise on MOSI while the clock stays high.

I cant afford a new avrisp at the moment, $30 is two weeks of parking at school…

Hmm RTFM sometime I forget that one… Didn’t actually learn much from it but I didn’t even know that section was in there…

I found a terminal program called VBHexTerm that has all 9 pins with lights on them and 3 user settable and I discovered that my serial cable is nowhere near wired standard. I have all the pins on one end out of the header for easy breadbording so I tested and shorted pins and found their right spots.

I now have CLK, MOSI, MISO and RST in their proper places but their is still a few issues them being:

RST - Pin 3 never changes state. It pulses quickly ~100kHz but with like a 1% duty so its probably just noise. To program I know i need to pull RST low so I just jumpered it to gnd.

The CLK and MOSI signals are terribly noisy here is a pic with what im getting out of my scope. Ive tested a knowen signal and scope displays it fine so I know this is actual noise. I have scopes front ground to the sheath of the serial cable and my probe ref to pin 5 (gnd)

Bottom line is SCK, DC coupling, 2V/div upper is MOSI, DC Coupling, 2V/div, 50us/div

http://www.bespoketech.net/public/spark … _scope.JPG

with that scope, take a look at a known good signal near the same frequency. Make sure scope or probe isn’t causing the bad waveform appearance.

Ive tested a knowen signal and scope displays it fine so I know this is actual noise.

It reads perfectly on one of my projects pwm channel and I have swapped probes around and they both read the same.

Im gonna take another stab at it tonight I noticed that ponyprog’s .ini file if i edit it for a slower speed when I load the program is puts them all back to normal. Im gonna try an older version and see if this serial port just cant handle a very fast port toggle.

Thanks for that terminal program link, Ive been looking for one that good for a long time!