These are simple AVR programmers. I designed and built four different programmers for various envilonments: LPT controlled parallel programmer, LPT controlled ISP adapter, COM controlled ISP adapter and COM controlled generic SPI bridge. Additionaly, COM controlled adapters can be used as a communication cable between host PC and target board, it is useful for debugging.
These AVR programmers have no controller on the programmer and directly controlled with port signals. Therefore, programming time is reduced shorter than any other programmers because there is not any communication delay such as command/result sequense between PC and programmer. These programmer can also be used with AVR studio :-).
If you have a JTAG download cable controlled via LPT port for Xilinx, Lattice or Altera devices, it can also be used to program AVR.
Item | Parallel Programmer | ISP Adapter (LPT/COM) |
|
---|---|---|---|
Control Port | LPT | LPT/COM(USB) | |
Programming Mode | Parallel Mode | ISP Mode | |
Power Supply | 5V | Not Required | |
Supportd Devices |
1200/2313 | OK | OK |
4414/8515 | OK*1 | OK | |
2333/4433 | OK*1 | OK | |
4434/8535 | OK*1 | OK | |
2323/2343 | OK*1 | OK | |
tiny10/11 | OK*1 | - *2 | |
tiny12 | OK*1 | OK | |
tiny13/25/45/85/24/44/84 | OK*1 | OK | |
tiny15 | OK*1 | OK | |
tiny22 | OK*1 | OK | |
tiny26 | OK*1 | OK | |
tiny28 | OK*1 | - *2 | |
tiny2313 | OK | OK | |
mega161/162/8515 | OK*1 | OK | |
mega165/325/645 | OK*1 | OK | |
mega169/329/649 | OK*1 | OK | |
mega3250/6450/3290/6490 | OK*1 | OK | |
mega163/323/8535/16/32/644 | OK*1 | OK | |
mega8/48/88/168 | OK*1 | OK | |
mega603/103/64/128 | OK*1 | OK | |
mega640/1280/1281/2560/2561 | OK*1 | OK | |
|
AT90S2313 (2KB) |
|
AT90S8535 (8KB) |
|
ATmega323 (32KB) |
|
ATmega128 (128KB) |
|
AVR has two different programming modes called Parallel Programming Mode (Parallel Mode) and Serial Downloading Mode (ISP mode).
At the Parallel Mode, the device to be programmed is put on the programmer's socket and +12 volts programming voltage is required to its RESET pin. Communicating between the programmer and the device is done in parallel programming commands, so that the programing speed is two times faster than ISP mode. This programming mode is used to pre-program many devices or/and ISP mode cannot use due to the board design. However, most programmers except STK500 seem not to support this programming mode.
At the ISP Mode, the device communicates via its SPI interface to program and verify. This mode requires only three signal lines without +12 volts programming voltage, so that it can also program in the terget system, this is called ISP (In-System Programming). However, the ISP mode cannot change fuse bits at some devces, and some devices don't have ISP feature. Such devices must be programmed in Parallel Mode. But most AVR programmers use this programming mode even if it has a socket, they have the same problem.
Additionally, there is serial programming mode using +12V programming voltage that called High-Voltage Serial Programming Mode. This programming mode is equivalent to the Paralell Mode and available in only 8/14 pin devices. For details on the each programming mode, please refer to the device data sheets.
Right image shows built paralell programmer, it is built compact by using many surface mount devices. Circuit diagram of this programmer is very simple but it supports both high voltage programming modes Parallel mode and HVS mode. This programming method is required when the following case.
Therefore the parallel programmer is not that required for most case, only an ISP adapter will do. However 8 pin devices will often require HVS programming mode in order to configure the reset pin as an I/O port.
This programmer is using a 20 pin ZIF socket for device mounting, so that it requires any socket converter when program not 20 pin devices (8,28,40). SOIC, TQFP, PLCC are also require socket converter for each package.
High level output voltage on the LPT port may not reach 3.5 volts on some PCs. In this case, a TTL-CMOS level converter, such as 74HCT541, must be put to the place indicated with a dashed line. The parallel programmer is controled with AVRXP.COM(DOS) or AVRPP.EXE(Win32).
This ISP adapter is designed to reduce cost and to be easy to build. The simplified adapters are not using any semiconductor part, port signals are tied to target device directly as shown in the circuit diagrams. Thus this adapter is very simple so that it will be built within several minutes, and will be good for evaluation use. But this programmer limits target supply voltage range to 4.5V-5.5V because they don't convert signal levels between PC and target, it may not fit to the target signal level.
This programming software supports five programmer types, original circuit, STK200 dongle and JTAG cables for Xilinx, Lattice, Altera devices controlled via LPT port. The connection between JTAG signals and AVR-ISP signals are: TDO-MISO, TDI-MOSI, TCK-SCK and TMS-RESET. In this case, the target supply voltage will able to be 3V-5V. The programmer type attached to the LPT port is detected automatically. The LPT port controlled ISP programmer is controlled with AVRXS.COM(DOS) or AVRSP.EXE(Win32).
This is an ISP adapter which is controlled via COM port. Signal levels of the RS-232C line is converted to the target level, so that target device can operate in entire range of the VCC. And also it can be used as an communication cable to communicate between host PC and terget program (this is explained in the following section). This ISP adapter will sufficient to develop most of the AVR applications.
Right image shows the built ISP adapter for COM port. It has a switch to connect/disconnect the ISP adapter from the target board. This feature is good for debugging process saied that "Load-Runner" (program/run again and again).
When build it, to put the level converter near the target board is better from viewpoint of stability and handling. I had built and used some ISP adapters and setteled this form. This ISP adapter is controlled with AVRSS.COM(DOS), AVRSP.EXE(Win32) or avrdude 5.0+.
This is a general purpose Serial to SPI bridge which is designed for AVR programming and to control any SPI slave devices. It is controlled via Windows API so that it does not require any direct I/O driver. When build it as a USB-Serial-SPI bridge like the photo shown in right, it can also supply target power via its down load cable. The SPI bridge has two different operating modes: Cooked Mode and Through Mode. The Cooked Mode acts as a serial to SPI bridge. The Through Mode passes through the data signals between PC and target like ISP adapter explained in previous paragraph. This enables debugging using software UART. This SPI bridge is controlled with AVRSP.EXE(Win32).
There are some control programs for each AVR programmers and they run on the console window. They can also be used in quick Drag and Drop operation with proper PIF (DOS) or .ini (Win32) settings.
The main feature on the control programs is they can detect device type automaticaly, and act on the properties of the detected device. Therefore, only specifying the hex files to be programmed will do. Any device option is not required. The command line options also able to be set with PIF file or .ini file as default.
For parallel programmer, a DOS based test program which can manipulate any socket pin manually is available. For ISP programmer, avrsp -z outputs a test signal on the SCK line to examine the system compatibility.
When use an AVR with ISP mode, target board must be designed with consider ISP function, the ISP pins, RESET, SCK, MISO and MOSI must be reserved for ISP function. However, number of ports may be insufficient in actual application.
ISP pins will able to share both I/O and ISP functions when some terms are satisfied. When using any I/O pin that also assigned to ISP function, the following must be observed.
Atmel recommends this pin layout, 3x2 header pin spacing of 2.54 milimeters. When build ISP cable or circuit board, this pin layout of the ISP connector is recommended.
When the target board has no ISP connector, it will able to ISP action with a contact plobe like shown in the right image.
This is a special feature on the COM controlled ISP adapter. This ISP adapter can be used to communicate between host PC and target board with any terminal programs because contrive to assignment of control signals as COM port. Thus, it can directly communicate or debug with the ISP cable. To enable this feature, following conditions must be satisfied.