0

How does one go about programming the 16u2 on an Uno? I have the isp header (for the 16u2) hooked up to another Uno programmed as ArduinoISP I'm not talking about DFU or USB->UART, I'm talking about using it like a standalone chip (Like, say, a Leonardo or Yun [the 32u4, not the Linux, obviously])

Alexander M
  • 358
  • 1
  • 11
  • Do you want to use it for something else, or do you want to extent the current firmware on it? I've done the latter to duplicate the reset-output to one of the JP2 headers, so I could use the uno board to program and external atmega over serial. I used DFU to upload, but if you don't care about this DFU bootloader you can use an Arduino-as-ISP to program it. To use the arduino IDE you'd have to create a new board. You can probably copy all/most of it from an ATMega32u4 board. – Gerben Jun 13 '15 at 13:20

1 Answers1

1

First you need to write a program for it. There is no Arduino core for the 'XU2, so you will need to write it out longhand. Then you compile it. Then you upload it using ISP. Then you run it. Note that the only pins you have access to on the board are the UART pins, the two on the LEDs, and the 3 on the ISP header.

Ignacio Vazquez-Abrams
  • 17,663
  • 1
  • 27
  • 32