5

The Arduino Uno has an ICSP header that I imagine is for programming the board using a separate ICSP programmer. That is, its ICSP header turn the board into a target.

Can one use that same ICSP to program other boards, turning the Arduino Uno effectively into a ICSP AVR programmer? How?

I'm assuming that the target boards would also be Arduinos and wanted the Uno to program them using the Arduino IDE. Is that possible?

Reading the AVR In-System Programming Application Note it looks to me that the only issue would be to make the programmer (the Arduino Uno) control the target board reset line. I've seen something like that in ArduinoISP sketch, but in that sketch, the target reset is controlled by port D10. But one could program the reset line to be an output, right? So could we change the ArduinoISP sketch to use its own reset line as output to control the target board reset line? If not, why not?

5

First of all, as configured, the RESET pin can not be used as an output pin. In order to use it as an I/O pin, you would have to program the RSTDISBL fuse. But once you do that, as jippie said, it becomes near-impossible to reprogram your Arduino (if you have the socketed through hole variety of the MCU, you could pull it out and put it into a high voltage programmer; in all other cases, it's effectively impossible).

So in theory, you can use the ICSP header the way you suggest. In practice, it's under almost any conceivable circumstance a terrible idea.

5

I recommend going out and buying an AVR Dragon - costs aroud $US50. That gives you ISCP programming plus debugwire debugging (using the Atmel Studio IDE).

  • Atmel Studio only runs on Windows. That's fine if you have Windows, not so great if you are using Linux or Mac. – Nick Gammon Jul 8 '15 at 1:42
3

Yes you can program the Arduino's reset input pin as an output and use that to program another AVR, but you can no longer program your Arduino as that relies on the controller being reset through its own reset pin.

Coming to think about it, I am not sure how the other devices (like the USB controller) responds to being reset by Arduino's controller itself. It resets the USB controller which may or may not reset the connection to the computer, possibly loosing data. With the USB controller being reset, GPIO-pins D0 and D1 (the serial interface between PC and Arduino's AVR) may corrupt the datastream.

  • 2
    In the R3, the nRESET line of the USB controller is not connected to the nRESET line of the main MCU, but only to its own ISP connector. Cutting a trace will disconnect the nRESET line of the main MCU, and jumpering a pair of pads ("RESET EN") will reenable it. – Ignacio Vazquez-Abrams Mar 30 '14 at 22:21
3

To answer my own question, just to report that I found something close to what I was looking for, which I link and describe briefly below.

Gammon Software Solutions forum - Atmega Bootloader Programmer - Programming Cable

On that page, the author suggest that we cut pin 5 from the 6-pin ICSP programming cable, solder a pin to it, and wire it to pin D10. Like so:

Modified ICSP programming cable

Then, you can load the Arduino Uno with the ArduinoISP sketch and program the target board as usual.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.