UART

During development, it may be beneficial to leverage the primary UART debug interface for loading your boot binaries onto the phyCORE-AM62x development kit. This guide will walk through the process of booting into U-Boot via UART.

Preparing the phyCORE-AM62Ax Development kit for UART Boot

The phyCORE-AM62Ax development kit is configured to boot from an SD Card slot by default and basic steps for performing this and establishing serial communication are outlined in the Quickstart. We need to modify the default boot configuration to UART Boot AND connect the development kit’s Debug UART interface to your Ubuntu Host Machine (these steps are not currently supported from a Windows Host Environment).

  • S7 should be ON to override the default boot settings.

UART Boot Switch Settings phyBOARD-AM62x Boot Switch Location
  • Once configured, connect your phyCORE-AM62x Development kit’s Debug UART interface to your Ubuntu Host Machine. This can typically be done in the Virtual Machine settings but exact steps vary depending on the VM software you are using.

Note

This guide assumes the following:
  1. The console is connected to ttyUSB0 of the Ubuntu Host Machine.

  2. lrzsz package is installed on the Ubuntu Host Machine.

Host (Ubuntu)
  # To install 'lrzsz' on Ubuntu
  sudo apt update && sudo apt install lrzsz
  • Power-on the development kit.

  • To test your setup thus far, open a serial console within your Ubuntu Host Machine:

    • Use the following command to start a serial connection with the development kit:

      Host (Ubuntu)
      minicom -b 115200 -D /dev/ttyUSB0
      
    • In UART Boot mode, you should see the following string of characters printed to the terminal:

      minicom Session - Host (Ubuntu)
      01000000011a0000616d36326100000000000000475020200008000000080000CC
      
    • You should also see the final “C” character continuously printed to the terminal.

    • You must now close the minicom session for the remaining steps to work. To close minicom, first enter Ctrl-A and then hit the X key (Ctrl-A and then the Z key will give you a command reference for more options).

Loading the Boot Binaries

Enter the following commands in your Ubuntu Host Machine in order to load the multiple stages of the bootloaders in sequence (be sure to replace the “<path to>” substring within each command to reflect the appropriate filesystem path your build system has these files stored):

Host (Ubuntu)
stty -F /dev/ttyUSB0 115200
sb --xmodem <path to>/tiboot3.bin > /dev/ttyUSB0 < /dev/ttyUSB0
sb --ymodem <path to>/tispl.bin > /dev/ttyUSB0 < /dev/ttyUSB0
sb --ymodem <path to>/u-boot.img > /dev/ttyUSB0 < /dev/ttyUSB0

Once complete, you can reopen minicom to access the U-Boot console:

Host (Ubuntu)
minicom -b 115200 -D /dev/ttyUSB0