ISP, ICSP, UARTS and misteries of programming

Hi folks:

I’m recently getting into microprocessors again after almost 20 years of not touching them (let’s just say the last one I did we were using UV burners). As a result, I’ve become tremendously confused by all the programmer interfaces out there, and I’d appreciate it if someone could clear up the following points of confusion:

  1. Is the Atmel ICSP the same as the Microchip ICSP? I ask because very often I see the “ICSP” for the AVR in quotes, and the PIC datasheets all say it’s a trademark of theirs. The acronym ICSP cannot be found anywhere on the ATMega168 datasheet.

  2. What exactly does “high voltage programming” mean? I thought I knew in the context of PIC micros, but it appears to be something different when discussing AVRs.

  3. The variety of names given to the serial interfaces is bewildering. My little Pololu robot has a header labeled ISP, but refered to as ICSP in some of the web page documentation. My Arduino Duemilanova has a 6 pin header labeled ICSP. And my Freeduino based Bare Bones Board has an ICSP header and a 5 pin header supposedly for “serial programming”, which is what I thought ICSP was!

Could you help this oldtimer stop pulling his hair? Thanks.

-carlos

The programming interfaces for PICs and AVRs are completely different.

See the AVR documentation for a description of high-voltage programming. It isn’t used very often.

Arduinos have a bootloader programmed into the AVR which loads applications via the serial port. They also have an ISP connector.

ISP (In-system-programming) requires a device such as

I have one of these

http://www.atmel.com/dyn/products/tools … ol_id=2726

or newer - I have one of these too

http://www.atmel.com/dyn/products/tools … ol_id=3808

check e-bay, but beware China-clones

or this one with JTAG (breakpoints) and ISP… I have one of these

http://www.nkcelectronics.com/avr-jtag- … r-kit.html

or many others that you can find. SparkFun probably sells one too.

ISP = In system programming (typically through a SPI or UART)

ICSP ~ In Circuit Serial Programming (same concept as ISP, different name)

A chip that can be programmed/reprogrammed with out removing it from the board will typically be advertised as having ISP or ICSP. Each manufacturer uses a different protocol, so you can’t use one manufacturers ISP/ICSP to program another manufacturers chip.

Flash/EEPROM memory cells typically require 12V for erasing and setting. Before ISP/ICSP this required you to remove the chip from the circuit and place it in a High voltage programmer. Newer ISP/ICSP compatible chips generate this voltage internally.

jwd270:
Flash/EEPROM memory cells typically require 12V for erasing and setting. Before ISP/ICSP this required you to remove the chip from the circuit and place it in a High voltage programmer. Newer ISP/ICSP compatible chips generate this voltage internally.

I would put it this way: Microprocessors with on-chip flash for program storage most often can be in-system and in-circuit re-programmed (“flashed”), without changing power supplies. The reprogramming can be hardware-based using JTAG (a standard) which is built in to most microprocessors, or hardware based using an SPI interface independent of JTAG, or may be software-based via self-programming, where an in-flash bootstrap loader program accepts a new user program via a serial UART, ethernet or other means. Some microprocessors such as ARMs often have a factory-installed bootstrap loader in flash that is unlikely to be erased. Other microprocessors such as Atmel AVRs have a configuration to place a bootstrap in memory using an in-circuit programmer (as above). In this case, the in-circuit programmer is used once to install the boostrap loader.

With inexpensive JTAG and ISCP devices, for developers these are much preferred to slow serial port bootstrap methods. But if the programs are small, bootstrap loaders via a serial port is OK. Serial bootstrap loaders can also be used to accept disseminated programs, one to many.