XMOS XTC Tools

To support interaction with the XMOS XTC Tools during production, an x86-64 SBC and XTAG programmer can be included in the PPC.

For example, to program the firmware of an XEF216 evaluation board:

Sample Test Plan

title: "XMOS XTC Tools integration"

# Requirements:
# - FT232RL
# - x86-64 SBC
#   - Ubuntu Linux
#   - XMOS XTC Tools v1.15.2
# - XMOS XTAG-3 programmer

suite:
 - title: Setup
   ident: SETUP
   steps:
    - command: define SBC.uart "UART2"
    - command: define FIRMWARE.xe "FIRMWARE.xe"
    - command: uartCfg %SBC.uart% 115200
      id: "0403:6010"

 - title: "Ubuntu login"
   ident: LOGIN
   retry: 2
   steps:
    - command: sleepms 500
    - command: uart %SBC.uart%
      send: "\x04\x03\r\n\x03\r\n\x04\x04"
    - command: sleepms 500
    - command: uart %SBC.uart%
      send: "\r\n"
      expect: "ppchost login:"
      retry: 3
      timeout: 15s
    - command: uart %SBC.uart%
      send: "testuser\r"
      expect: "Password:"
      timeout: 3s
    - command: uart %SBC.uart%
      send: "testpass\r"
      expect: "testuser@ppchost:~$"
      timeout: 30s

 - title: Test XTC Tools
   ident: XTCTOOLS
   steps:
    - command: sleepms 10
    - command: uart %SBC.uart%
      send: "\r\n"
    - command: uart %SBC.uart%
      send: "killall -9 xflash xgcc xgdb xrun\r"
    - command: uart %SBC.uart%
      send: "cd /opt/XMOS/XTC/15.2.1 && echo cd:$?:PASS\r"
      expect: "cd:0:PASS"
    - command: uart %SBC.uart%
      send: "source SetEnv\r"
    - command: uart %SBC.uart%
      send: "xflash -l && echo xflash.l:$?:PASS\r"
      expect: "xflash.l:0:PASS"
      timeout: 5s

 - title: Program Firmware
   ident: PROGRAM
   steps:
    - command: sleepms 10
    - command: uart %SBC.uart%
      send: "xflash %FIRMARE.xe% ; echo xflash.p:$?:DONE\r"
      extract: "xflash.p:(\\d+):DONE"
      extractKey: RETVAL
      timeout: 2m
    - command: eval "RETVAL == '0'"

References