# Enable the SK-AM62P-LP
In this document we will look at the main steps to enable the SK-AM62P-LP board.
This is not always necessary since TI might send us an already enabled board.
```{admonition} Tool Required
:class: warning
You'll need the `xdsdfu` tool to enable the DUT. The tool has been give to us by TI to let us enable
the boards ourselves. At the moment, only Linaro employees are authorized to make use of it and public
distribution is prohibited. Please get in touch with the LAA team in order to have access.
```
```{admonition} Firmware Required
:class: warning
You'll additionally need a specific firmware. It was give to us by TI to let us enable
the boards ourselves. At the moment, only Linaro employees are authorized to make use of it and public
distribution is prohibited. Please get in touch with the LAA team in order to have access.
In this document we will refer to the firmware file with `firmware_3.0.0.35_71173da2364c309abf00941b6c4d4d4e.bin`.
```
## Test Automation Interface
For LAVA the SK-AM62P-LP is enabled when the "Test Automation Interface" is enabled on the board.
The "Test Automation Interface" should be available via the XDS port.
{align=center}
Once you cannot the DUT to your PC you should be able to the XDS serial:
```shell
$ ls -l /dev/serial/by-id/
total 0
lrwxrwxrwx 1 root root 13 Feb 26 10:59 usb-Texas_Instruments_XDS110_XXX
```
Where XXX is different depending on the interface version on the board.
We can check if the Test Automation Interface is already enabled by connecting to the serial and see if it is responding. Here is an example:
```shell
$ sudo tio /dev/serial/by-id/usb-Texas_Instruments_XDS110__03.00.00.35__Embed_with_CMSIS-DAP_S62G0012-if03
[11:12:55.321] tio v2.5
[11:12:55.321] Press ctrl-t q to quit
[11:12:55.322] Connected
Test Automation Interface - v12.8.0.00186-3141-34-g6df2824c2f
auto reset :Warm reset DUT
auto por :Power on reset DUT
auto hold_por :Hold Power on reset DUT
auto release_por :Release Power on reset DUT
auto power :Power on|off DUT
auto sysboot :e.g. 110000
auto boot list :List supported boot modes for device
auto dut list :List supported devices
auto set dut :Initialize i2c for DUT
auto scan i2c :Scan i2c bus for devices
auto probe i2c :Probe i2c bus for addr
auto ina help :Print help menu for INA interface
auto measure temperature :Read temperature sensors
auto measure power :Measure DUT power
dfu :Put the Test Automation Interface device into DFU mode
version :Show SW version
help :Print this menu
```
If `Test Automation Interface - vXX.X.X.XXXXX` comes out, then the board should already be working with LAVA.
If no output comes out or you want to update the board, please continue reading the document.
## Flashing
Assuming we have both `xdsdfu` and `firmware_3.0.0.35_71173da2364c309abf00941b6c4d4d4e.bin` in the working directory. Also please disconnect `tio`.
```shell
$ chmod +x xdsdfu
```
Set the configuration on the DUT.
```shell
$ sudo ./xdsdfu -m
$ sudo ./xdsdfu -c 5 -r
```
```{admonition} Problem: "Unable to load libusb."
:class: warning
Run the following:
sudo apt-get install libusb-1.0-0-dev
```
```{admonition} Problem: "Scanning USB buses for supported XDS110 devices... The requested device was not found on the bus."
:class: warning
Run with sudo
```
```{admonition} Problem: Again "Scanning USB buses for supported XDS110 devices... The requested device was not found on the bus."
:class: warning
The command enables the Test Automation immediately, in my case it made the JTAG interface not responsive any longer to "xdsdfu"
Solution
It is possible to change the configuration also from the Test Automation interface via the "dfu" command. Connect via `tio`. The Test Automation Interface does not have this issue.
```shell
sudo tio /dev/serial/by-id/usb-Texas_Instruments_XDS110__03.00.00.26__Embed_with_CMSIS-DAP_S62G0012-if00
dfu :Put the Test Automation Interface device into DFU mode
=> dfu
```
```{admonition} Configuration Options
:class: note
You can list the different configuration options with:
```shell
$ sudo ./xdsdfu -c ?
```
Flash the firmware
```shell
$ sudo ./xdsdfu -m
$ sudo ./xdsdfu -f firmware_3.0.0.35_71173da2364c309abf00941b6c4d4d4e.bin -r
```
Once finished, please check the serial again.
```shell
$ sudo tio /dev/serial/by-id/usb-Texas_Instruments_XDS110__03.00.00.35__Embed_with_CMSIS-DAP_S62G0012-if03
[11:12:55.321] tio v2.5
[11:12:55.321] Press ctrl-t q to quit
[11:12:55.322] Connected
Test Automation Interface - v12.8.0.00186-3141-34-g6df2824c2f
auto reset :Warm reset DUT
auto por :Power on reset DUT
auto hold_por :Hold Power on reset DUT
auto release_por :Release Power on reset DUT
auto power :Power on|off DUT
auto sysboot :e.g. 110000
auto boot list :List supported boot modes for device
auto dut list :List supported devices
auto set dut :Initialize i2c for DUT
auto scan i2c :Scan i2c bus for devices
auto probe i2c :Probe i2c bus for addr
auto ina help :Print help menu for INA interface
auto measure temperature :Read temperature sensors
auto measure power :Measure DUT power
dfu :Put the Test Automation Interface device into DFU mode
version :Show SW version
help :Print this menu
```
Your SK-AM62P-LP board should have not the `Test Automation Interface` enabled and can be used from LAVA.