A programmer for the AVR to be used with the serial port. ========================================================= The programmer uses simple bitbanging to program the AVR. High voltages from the serial port are converted to TTL levels by using a Max232, which derives its power from the target board. The SPI pins are connected through the Max232. Due to the limited no. of ports on the Max232, and since we do not really need high frequency conversion on the RESET line, it is connected directly, using a transistor both to act as a buffer and a level shifter. The serial port on most PCs is not able to work provide the current needed to pull RESET low. The Max232 should be mounted on the short end of the wire, so that the TTL levels dont die out along the line. Since the PC is giving RS232 signals, the line to the level converter can be as long as the standard allows. The pin configuration is the same as the SIPROG programmer found on the PonyProg website. (http://www.lancos.com/prog.html). In LancOS' schematics level conversion is done using discrete components. We have replaced them with an IC (Max232) PROGRAMMING ------------ * PONYPROG (http://www.lancos.com/prog.html) -=-==-=-=-=-=- In order to program using PonyProg, you must invert the three SPI pins 1. Setup->Interface 2. Click Serial 3. From the drop-down box select "SI Prog API" 4. Ensure that "Invert D-In" "Invert D-OUT" and "Invert SCKL" checkboxes are ticked. 5. Ensure "Invert RESET" is unchecked. * AVRDUDE (http://www.bsdhome.com/avrdude/) -=-=-=-=-=- A programmer entry must be added in avrdude.conf Copy the following in avrdude.conf # SIPROG Inverted programmer # reset=!txd sck=rts mosi=dtr miso=cts programmer id = "siprogn"; desc = "Inverted Lancos SI-Prog "; type = serbb; reset = ~3; sck = ~7; mosi = ~4; miso = ~8; ; Then use avrdude giving the switch -c siprogn. Tested with ----------- * ATMega32 ====================================================================================== DOCUMENT Updated: 2nd June 2007, Zohair Ahmad, zohair[dot]ahmad[at]gmail[dot]com ======================================================================================