Burning the bootloader

Before you can flash firmware to the ATMega328P chip, you'll need to burn a bootloader using an ISP programmer (note that you only need to do this once). Subsequent programming/updating of the firmware can be done through the programming header using an FTDI cable.

If you don't have an ISP programmer, you can use another Arduino (in our case, the Mega 2560 used by the control board) using the ArduinoISP sketch. All you'll need are 6 Male/Female jumper wires (e.g., https://www.sparkfun.com/products/9140).

Step 1: Connect the ISP header on the target board to the Arduino Mega 2560 using 6 M/F jumper wires

ISP headers have the following pinout:

6-pin ISP header

Using jumper wires make the connections in the following table:

Target board ISP header pin Arduino Mega 2560 pin Color of wire in photos
1: MISO 50 yellow
2: VCC +5V red
3: SCK 52 green
4: MOSI 51 blue
5: SS/RST 53 yellow
6: GND GND black

Here's a photo showing both boards connected by jumper wires and ready for flashing:

Connecting the target ISP header to an Arduino Mega 2560 programmer

Here's a close-up of the target board's ISP header:

Close-up of the signal generator board ISP header connections

and a close-up of the Arduino Mega 2560 connections (note that the +5V and GND connections are not shown):

Close-up of Arduino Mega 2560 connections

Step 2: Program the ArduinoISP sketch to the Arduino Mega 2560

  1. If you haven't already, download and install the Arduino 1.0.x or 1.5.x IDE available here.
  2. Make sure that the Arduino Mega 2560 is plugged into the USB port.
  3. From the "Tools/Port" menu, select the appropriate port that corresponds to the Mega 2560.
  4. From the "Tools/Board" menu, select "Arduino Mega or Mega 2560".
  5. Load the "ArduinoISP" sketch from the menu: "File/Examples/ArduinoISP".
  6. Click the "Upload" button.
  7. Wait for the status message "Done Uploading."

Step 3: Flash the bootloader

  1. From the "Tools/Board" menu, select "Arduino Uno".
  2. From the "Tools/Programmer" menu, select "Arduino as ISP".
  3. From the "Tools" menu, select "Burn bootloader".
  4. After about a minute, the status message should say "Done burning bootloader".
Last modified 3 years ago Last modified on 10/07/14 16:58:09

Attachments (4)

Download all attachments as: .zip