2.5.2 Prepare the Programming Environment
This section describes how to establish communication between the SAM-BA host application and the ROM code monitor of the target (SAM9X60), and how to use the SAM-BA host applets nandFlash and sdmmc to erase and then write the boot.bin (at91bootstrap) and harmony.bin (MPLAB Harmony3 application) binary images to the NAND Flash memory.
Proceed as follows:
- To enable communication with the target’s ROM code monitor (SAM-BA monitor), the SAM-BA software must be installed on the host computer.
- Ensure that no SD memory card inserted.
- Open the NAND boot jumper (J4) on the SAM9X60-Curiosity board to disable NAND Flash access.
- Connect a USB FTDI cable to J11 on the SAM9X60-Curiosity board. This link is used by the ROM code console terminal to display information and debug traces sent by the applets.
- Power the SAM9X60-Curiosity board by connecting a Micro-B USB cable to the USBA port (J1) on the board.
- Reset the board by pressing and releasing the RESET button.
- Wait for the ”ROM boot” message on the ROM code console
- Close the J4 NAND boot jumper to enable back the NAND Flash access.
At this point, the ROM code runs the standard (SAM-BA) monitor and can connect and communicate with SAM-BA on the host.
To test the connection, the ROM code version can be requested with the following command:
./sam-ba -p serial –device sam9x60 -m version //get ROM code version with SAM-BA
