I'm trying to get the XScope running on my XK-1A through XTAG2. Without XScope, the programs (be it my own, or the app_xscope_printing_timed_example from XMOS) run without problems, and if I remove the config.xscope file, I even see the printf output in the console.
Problem is, whenever I switch in the XScope tab of Run Configurations to either Offline or Real-Time, the program hangs on startup. I tried both Run and Debug with same results, and when I press Suspend in Debug to see where the program is waiting, it shows xscope_constructor().
Is there something I'm missing? It looks like either the device can't connect to the XScope server, or I'm supposed to somehow tell the server to start the app, but I don't see where.
The Run Configuration I'm using:
(I also tried the "xSCOPE (via xCONNECT/UART)" in the "Target I/O options") Makefile:
Code: Select all
TARGET = XK-1A
APP_NAME =
USED_MODULES =
XCC_FLAGS = -g -O3 -fxscope
VERBOSE = 1
XMOS_MAKE_PATH ?= ../..
ifneq ($(wildcard $(XMOS_MAKE_PATH)/xcommon/module_xcommon/build/Makefile.common),)
include $(XMOS_MAKE_PATH)/xcommon/module_xcommon/build/Makefile.common
else
include ../module_xcommon/build/Makefile.common
endif
Code: Select all
<xSCOPEconfig ioMode="timed" enabled="true"/>
Code: Select all
#include <xs1.h>
#include <platform.h>
#include <stdio.h>
#include <xscope.h>
int main (void) {
for (int i = 0; i < 10; i++) {
printf("value of i is %d\n", i);
}
}
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<Network xmlns="http://www.xmos.com"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.xmos.com http://www.xmos.com">
<Type>Board</Type>
<Name>XK-1A Development Board</Name>
<BoardId>0005021X</BoardId>
<Declarations>
<Declaration>tileref tile[1]</Declaration>
</Declarations>
<Packages>
<Package id="0" Type="XS1-L1A-TQ128">
<Nodes>
<Node Id="0" InPackageId="0" Type="XS1-L1A" Oscillator="20MHz" SystemFrequency="400MHz">
<Boot>
<Source Location="SPI:bootFlash"/>
</Boot>
<Tile Number="0" Reference="tile[0]">
<Port Location="XS1_PORT_1I" Name="PORT_UART_RX"/>
<Port Location="XS1_PORT_1J" Name="PORT_UART_TX"/>
<Port Location="XS1_PORT_1K" Name="PORT_BUT_1"/>
<Port Location="XS1_PORT_1L" Name="PORT_BUT_2"/>
<Port Location="XS1_PORT_1M" Name="PORT_SPI_MISO"/>
<Port Location="XS1_PORT_1N" Name="PORT_SPI_SS"/>
<Port Location="XS1_PORT_1O" Name="PORT_SPI_CLK"/>
<Port Location="XS1_PORT_1P" Name="PORT_SPI_MOSI"/>
<Port Location="XS1_PORT_4F" Name="PORT_LED"/>
</Tile>
</Node>
</Nodes>
</Package>
</Packages>
<Nodes>
<Node Id="1" Type="device:" routingId="0x8000">
<Service Id="0" Proto="xscope_host_data(chanend c);">
<Chanend Identifier="c" end="3"/>
</Service>
</Node>
</Nodes>
<Links>
<Link Encoding="2wire" Delays="4,4" Flags="XSCOPE">
<LinkEndpoint NodeId="0" Link="X0LC" />
<LinkEndpoint NodeId="1" Chanend="1" />
</Link>
</Links>
<ExternalDevices>
<Device NodeId="0" Tile="0" Class="SPIFlash" Name="bootFlash" Type="AT25FS010">
<Attribute Name="PORT_SPI_MISO" Value="PORT_SPI_MISO"/>
<Attribute Name="PORT_SPI_SS" Value="PORT_SPI_SS"/>
<Attribute Name="PORT_SPI_CLK" Value="PORT_SPI_CLK"/>
<Attribute Name="PORT_SPI_MOSI" Value="PORT_SPI_MOSI"/>
</Device>
</ExternalDevices>
<JTAGChain>
<JTAGDevice NodeId="0"/>
</JTAGChain>
</Network>