- Attention
- This document contains the details for AM243X-EVM and AM243X-LP board setup under each section. User should select the right board setup in the sections.
Cable Connections
AM243X-LP
- The figure below shows some important cable connections, ports and switches.
- Take note of the location of the "BOOTMODE" switch, this is used to switch between different boot modes like OSPI, UART, NOBOOT mode
AM243X-LP
- Power Supply for LP board
- AM243X-LP has USB Type-C connector(J10) used for power input.
- Need to input 5V with 3A power supply through the USB Type-C cable.
- If there is error in power input then LD9 Red LED will glow continuously as shown in below image.
Power Error LED
- If proper power input is supplied to LP board then LD9 RED Led will blink once and green leds will glow as shown in the below image
Power Indication LEDs
AM243X-EVM
- The figure below shows some important cable connections, ports and switches.
- Take note of the location of the "BOOTMODE" switch, this is used to switch between different boot modes like OSPI, UART, SD, NOBOOT mode
AM243X-EVM
Setup UART Terminal
AM243X-LP
- Many examples use a standard UART terminal to log the output from the examples. You can use any UART terminal program for the same. Below steps show how to setup the UART terminal from CCS.
- First identify the UART port as enumerated on the host machine.
- Make sure that the AM243X-LP and UART cable connected as shown in Cable Connections
- AM243X-LP supports single UART Port from XDS110 JTAG which is used for console.
- In windows, you can use the "Device Manager" to see the detected UART ports
- Search "Device Manager" in Windows Search Box in the Windows taskbar.
Identify UART Port in Windows Device Manager
- In CCS, goto "View > Terminal"
UART Terminal Menu
Open New UART Terminal
- Select the UART port, keep other options to default, i.e 115200 baud rate - 8 data bits - No parity - 1 stop bit,
- We use UART serial port, as seen in the device manager, for below in the SDK
- Flashing application via UART
- Booting application via UART
- Console output for examples which run from R5F
Connect to UART port
- In this screenshot this happens to be COM148, however on your machine this could be different. One tip to make sure there is no mistake in identifying the UART port is to disconnect all other UART to USB devices other than this AM243X-LP before checking in device manager.
AM243X-EVM
- Many examples use a standard UART terminal to log the output from the examples. You can use any UART terminal program for the same. Below steps show how to setup the UART terminal from CCS.
- First identify the UART port as enumerated on the host machine.
- Make sure that the EVM and UART cable connected as shown in Cable Connections
- In windows, you can use the "Device Manager" to see the detected UART ports
- Search "Device Manager" in Windows Search Box in the Windows taskbar.
- If dont see any USB serial ports listed in "Device Manager" under "Ports (COM & LPT)", then make sure you have installed the UART to USB driver from FTDI, https://www.ftdichip.com/FTDrivers.htm.
Identify UART Port in Windows Device Manager
- In CCS, goto "View > Terminal"
UART Terminal Menu
Open New UART Terminal
- Select the UART port, keep other options to default, i.e 115200 baud rate - 8 data bits - No parity - 1 stop bit,
- We use the 1st USB serial port, as seen in the device manager, for below in the SDK
- Flashing application via UART
- Booting application via UART
- Console output for examples which run from R5F
- We use the 2nd USB serial port, as seen in the device manager, as terminal output for examples which run from M4F
Connect to UART port
- In this screenshot this happens to be COM13 and COM14, however on your machine this could be different. One tip to make sure there is no mistake in identifying the UART port is to disconnect all other UART to USB devices other than this EVM before checking in device manager.
Flash SOC Initialization Binary
AM243X-LP
- Attention
- This is a recommended one time step that needs to be done before you can load and run programs via CCS
-
If this step fails, maybe due to bad flash in EVM, then try one of the other SOC initialization steps mentioned at SOC Initialization
-
This step needs to be done once unless the OSPI flash has been erased or some other application has been flashed
- A quick recap of steps done so far that are needed for the flashing to work
- Make sure the UART port used for terminal is identified as mentioned in Setup UART Terminal
- Make sure python3 is installed as mentioned in Python3
- Make sure you have the EVM power cable and UART cable connected as shown in Cable Connections
- POWER-OFF the AM243X-LP
- Set boot mode to UART BOOTMODE as shown in below image
UART BOOT MODE
- POWER-ON the AM243X-LP
- You should see character "C" getting printed on the UART terminal every 2-3 seconds as shown below
UART output in UART BOOT MODE
- Close the UART terminal as shown below. This is important, else the UART script in next step wont be able to connect to the UART port.
Close UART terminal
Flash in progress
- After all the flashing is done, you will see something like below
Flashing successful
- If flashing has failed, see Flash tool error messages and solutions, and resolve the errors.
- If flashing is successful, do the next steps ...
- POWER-OFF the AM243X-LP
- Switch the LP boot mode to OSPI mode as shown below,
OSPI BOOT MODE
- Re-connect the UART terminal in CCS window as shown in Setup UART Terminal
- POWER-ON the AM243X-LP
- You should see output like below on the UART terminal
Starting NULL Bootloader ...
DMSC Firmware Version 21.1.1--v2021.01a (Terrific Lla
DMSC Firmware revision 0x15
DMSC ABI revision 3.1
INFO: Bootloader_runCpu:147: CPU r5f1-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:147: CPU r5f1-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:147: CPU m4f0-0 is initialized to 400000000 Hz !!!
INFO: Bootloader_loadSelfCpu:199: CPU r5f0-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_loadSelfCpu:199: CPU r5f0-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runSelfCpu:209: All done, reseting self ...
- Congratulations now the AM243X-LP is setup for loading and running from CCS !!!
- You dont need to do these steps again unless you have flashed some other binary to the flash.
- Now you can build a example of interest (see Build a Hello World example) and then run it (see CCS Launch, Load and Run)
AM243X-EVM
- Attention
- This is a recommended one time step that needs to be done before you can load and run programs via CCS
-
If this step fails, maybe due to bad flash in EVM, then try one of the other SOC initialization steps mentioned at SOC Initialization
-
This step needs to be done once unless the OSPI flash has been erased or some other application has been flashed
- A quick recap of steps done so far that are needed for the flashing to work
- Make sure the UART port used for terminal is identified as mentioned in Setup UART Terminal
- Make sure python3 is installed as mentioned in Python3
- Make sure you have the EVM power cable and UART cable connected as shown in Cable Connections
- POWER-OFF the EVM
- Set boot mode to UART BOOTMODE as shown in below image
UART BOOT MODE
- POWER-ON the EVM
- You should see character "C" getting printed on the UART terminal every 2-3 seconds as shown below
UART output in UART BOOT MODE
- Close the UART terminal as shown below. This is important, else the UART script in next step wont be able to connect to the UART port.
Close UART terminal
Flash in progress
- After all the flashing is done, you will see something like below
Flashing successful
- If flashing has failed, see Flash tool error messages and solutions, and resolve the errors.
- If flashing is successful, do the next steps ...
- POWER-OFF the EVM
- Switch the EVM boot mode to OSPI mode as shown below,
OSPI BOOT MODE
- Re-connect the UART terminal in CCS window as shown in Setup UART Terminal
- POWER-ON the EVM
- You should see output like below on the UART terminal
Starting NULL Bootloader ...
DMSC Firmware Version 21.1.1--v2021.01a (Terrific Lla
DMSC Firmware revision 0x15
DMSC ABI revision 3.1
INFO: Bootloader_runCpu:151: CPU r5f1-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:151: CPU r5f1-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:151: CPU m4f0-0 is initialized to 400000000 Hz !!!
INFO: Bootloader_loadSelfCpu:203: CPU r5f0-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_loadSelfCpu:203: CPU r5f0-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runSelfCpu:215: All done, reseting self ...
- Congratulations now the EVM is setup for loading and running from CCS !!!
- You dont need to do these steps again unless you have flashed some other binary to the flash.
- Now you can build a example of interest (see Build a Hello World example) and then run it (see CCS Launch, Load and Run)
DDR Initialization
- Attention
- As AM243X-LP has no DDR memory, These DDR Initialization steps applicable only for AM243X-EVM.
AM243X-EVM
- By default none of the SOC initialization methods initialize DDR, or for that matter any other peripherals.
- The SOC initialization only enables all the CPUs, set them to a valid clock and make them run a
while(1)
loop.
- To initialize DDR, in particular, do the additional step below from CCS GEL menu.
- Launch CCS debug session as mentioned here, Launch CCS
- Connect to
MAIN_Cortex_R5_0_0
Connect to R5F0-0
- Run the DDR initialization from GEL menu as shown below,
DDR initialization via GEL menu
Additional Details
- Note
- This section has more details on AM243X-EVM and AM243X-LP. This is mainly for reference and can be skiped unless referred to by other pages in this user guide.
SOC Initialization
Before any program can be loaded and run on the EVM, the SOC needs to be initialized. Below sections describes the various options available for SOC initialization.
It is recommended to use the method mentioned in Flash SOC Initialization Binary. However in some cases, additional methods described below can be used esp when running on your own custom EVM and flash driver is not yet available for that EVM.
SOC Initialization Using SD BOOT
- Attention
- These steps applicable only for AM243X-EVM, AM243X-LP has no SD support.
- Note
- This step needs to be done once, unless the SD card is reformatted and/or the boot file is changed
SD BOOT MODE
- Insert the formated SD card in the SD card slot in the EVM
- Open a UART terminal as mentioned in Setup UART Terminal
- POWER-ON the EVM
- You should see output like below on the UART terminal
Starting NULL Bootloader ...
DMSC Firmware Version 21.1.1--v2021.01a (Terrific Lla
DMSC Firmware revision 0x15
DMSC ABI revision 3.1
INFO: Bootloader_runCpu:151: CPU r5f1-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:151: CPU r5f1-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runCpu:151: CPU m4f0-0 is initialized to 400000000 Hz !!!
INFO: Bootloader_loadSelfCpu:203: CPU r5f0-0 is initialized to 800000000 Hz !!!
INFO: Bootloader_loadSelfCpu:203: CPU r5f0-1 is initialized to 800000000 Hz !!!
INFO: Bootloader_runSelfCpu:215: All done, reseting self ...
- Congratulations now the EVM is setup for loading and running from CCS !!!
- You dont need to do these steps again unless you have changed or re-formatted or deleted/changed the
tiboot3.bin
file.
SOC Initialization Using CCS Scripting
Set Environment Variable
- Note
- This step needs to be done once and is needed for the SOC initialization script
load_dmsc.js
to find certain initialization files within the SDK folder. This variable is not used otherwise in the build process. If you dont like adding variables in the environment, then you need to edit the file ${SDK_INSTALL_PATH}/tools/ccs_load/am64x_am243x/load_dmsc.js
and specify the SDK path in the file itself.
- Add path to the SDK folder as a environment variable in the host machine.
- In windows, goto "Windows Task Bar Search" and search for "environment variables for your account"
Environment Variables For Your Account
- Add a new variable named
MCU_PLUS_SDK_AM243X_PATH
and point it to the path where the SDK is installed
Add New Environment Variable For Your Account
Run the SOC Initialization Script
AM243X-LP
- Attention
- This step needs to be done every time the AM243X-LP is power-cycled.
- POWER-OFF the AM243X-LP
- Make sure below cables are connected as shown in Cable Connections
- Set AM243X-LP in NOBOOT mode as shown below
NO BOOT MODE
Launch Target Configuration
- You will see the AM243X target configuration in the "Debug" window as shown below
Target Configuration After Launch
- Goto "CCS Toolbar > View > Scripting Console"
- Type the below command in the scripting console and press "enter", to load DMSC FW and initialize the SOC
Scripting Console
- In Linux, run the same command, only the path would be a Linux path like
/home/{username}/ti/mcu_plus_sdk_{soc}_{sdk version}/tools/ccs_load/am64x_am243x/load_dmsc.js
- After successful execution of this script one would see logs as below
- In the scripting console, this is log from the script itself.
Scripting Console Log
- In the AM243X "CIO" console, this is log from the R5F.
AM243X CIO Console R5F Log
- In the AM243X console, this is log from the GEL scripts.
Select AM243X GEL Console
AM243X Console GEL Log
- For success, all the three consoles should have no errors in their logs.
- If the script is run without providing power to the AM243X-LP or if the AM243X-LP BOOTMODE is not set to NOBOOT MODE then you will see errors in the console and/or unexpected behaviour and error messages.
- SOLUTION: Power cycle AM243X-LP and repeat the steps.
AM243X-EVM
- Attention
- This step needs to be done every time the EVM is power-cycled.
- POWER-OFF the EVM
- Make sure below cables are connected as shown in Cable Connections
- Set EVM in NOBOOT mode as shown below
NO BOOT MODE
Launch Target Configuration
- You will see the AM243X target configuration in the "Debug" window as shown below
Target Configuration After Launch
- Goto "CCS Toolbar > View > Scripting Console"
- Type the below command in the scripting console and press "enter", to load DMSC FW and initialize the SOC
Scripting Console
- In Linux, run the same command, only the path would be a Linux path like
/home/{username}/ti/mcu_plus_sdk_{soc}_{sdk version}/tools/ccs_load/am64x_am243x/load_dmsc.js
- After successful execution of this script one would see logs as below
- In the scripting console, this is log from the script itself.
Scripting Console Log
- In the AM243X "CIO" console, this is log from the R5F.
AM243X CIO Console R5F Log
- In the AM243X console, this is log from the GEL scripts.
Select AM243X GEL Console
AM243X Console GEL Log
- For success, all the three consoles should have no errors in their logs.
- If the script is run without providing power to the EVM or if the EVM BOOTMODE is not set to NOBOOT MODE then you will see errors in the console and/or unexpected behaviour and error messages.
- SOLUTION: Power cycle EVM and repeat the steps.
BOOT MODE
UART BOOT MODE
AM243X-LP
This mode is used to flash files to the AM243X-LP flash via UART. It can also be used to boot applications via UART.
\code
BOOTMODE [ 1 : 8 ] (SW4) = 1110 0000
\endcode
UART BOOT MODE
AM243X-EVM
This mode is used to flash files to the EVM flash via UART. It can also be used to boot applications via UART.
\code
BOOTMODE [ 0 : 7 ] (SW2) = 1101 1100
BOOTMODE [ 8 : 15 ] (SW3) = 1011 0000
\endcode
UART BOOT MODE
OSPI BOOT MODE
AM243X-LP
This mode is used to boot flashed applications via AM243X-LP flash like OSPI flash
BOOTMODE [ 1 : 8 ] (SW4) = 0100 0100
OSPI BOOT MODE
AM243X-EVM
This mode is used to boot flashed applications via EVM flash like OSPI flash
BOOTMODE [ 0 : 7 ] (SW2) = 1100 1110
BOOTMODE [ 8 : 15 ] (SW3) = 0100 0000
OSPI BOOT MODE
SD BOOT MODE
- Attention
- As AM243X-LP has no SD support, This is applicable only for AM243X-EVM
AM243X-EVM
This mode is used to boot applications via SD card on the EVM.
BOOTMODE [ 0 : 7 ] (SW2) = 1100 0011
BOOTMODE [ 8 : 15 ] (SW3) = 0110 1100
SD BOOT MODE
- Note
- Booting user applications from SD card is not yet supported. Use this only as part of SOC Initialization Using SD BOOT
NOBOOT MODE
AM243X-LP
This mode is used in conjunction with the load_dmsc.js
script described here SOC Initialization Using CCS Scripting,
BOOTMODE [ 1 : 8 ] (SW4) = 1111 0000
NO BOOT MODE
AM243X-EVM
This mode is used in conjunction with the load_dmsc.js
script described here SOC Initialization Using CCS Scripting,
BOOTMODE [ 0 : 7 ] (SW2) = 1101 1111
BOOTMODE [ 8 : 15 ] (SW3) = 0000 0000
NO BOOT MODE