Running etherboot
1) Compile the etherboot code:
In app_swallow_etherboot/src/demo.xc
Find the file's struct struct swallow_xlinkboot_cfg
- set boards_w and boards_h
2) make app_swallow_etherboot
: cd sw_swallow_etherboot ; make
3) Verify that the ethernet board is connected to USB and power: xrun -l
— should show "L1[0]" present.
4a) Run on ethernet board: xrun --io app_swallow_etherboot/bin/swallow_etherboot.xe
4b) Connect ethernet cable and ensure PC has IP on subnet 192.168.128.xxx
, and is NOT 192.168.128.3
4a) Ping 192.168.128.3
- should work
4b) Or telnet to 192.168.128.3
To build software
1) Make some code.
- remember that the main function must be in a separate file.
int main()
must include:
#include <platform.h>
#define MCMAIN
#include "mcsc_chan.h"
#include "yourCode.h"
2) RTFR in tool_xmp16_manycore to run the tool:
swallow-mcsc.py manycoremain.xc [extra files] [compiler parameters]
(remember to add the path).
2a) e.g with optimised flags: swallow-mcsc.py mcmain.xc ledtest.xc -O3 -o test.sgb
Boot software
1) Download binary using tftp
tftp> connect 192.168.128.3 69
tftp> mode binary
tftp> put Swallow_V2-ID_LEDs.sgb
2) (Optional): Read back booted board configuration
tftp> get board_dims
Streaming data in and out
To get ethernet p2p working:
1) sudo arping -c 1 -A -I eth0 192.168.128.2
2) tftp code
3) run python send/receive script.
For streaming from PC to board:
Output on port 5b5b: nc -lku 192.168.128.2 $((0x5b5b))
Current code:
- Uses JTAG debug, since xscope seems to hang.
- test.py sends the strings in 'pkt' definition in the code to port 0x1b1b
- This then prints onto the screen.
- Ensure that the endpoint is declared streaming and that the test.py script targets the correct ID (which can be printed from the grid_example code).