XSCOPE Error: XN11049 Network positioning failed

All technical discussions and projects around startKIT
Posts: 19
Joined: Tue Jun 16, 2015 10:50 pm

XSCOPE Error: XN11049 Network positioning failed

Post by extremeRider »

I'm trying to use the xScope to debug a driver for a quadrature encoder.
I'm currently using the XK-1A board.

I'm following the tutorial available at this link:

https://www.xmos.com/support/tools/docu ... nent=14796

but when I try to compile the code, I get the error:

..\.\XK-1A.xn: Error: XN11049 Network positioning failed (cannot satisfy constraints on routing IDs).

My idea would be just to plot the phase A and phase B of the encoder. Here is the code (I've just slightly modified the tutorial code):

Code: Select all

#include <xscope.h>
#include <xs1.h>

in port pa   = XS1_PORT_1A;
in port pb   = XS1_PORT_1B;

void xscope_user_init(void) {

int main() {
  while (1) {
    int sample;
    pa :> sample;
    // xscope_uint(0, sample); <-- function not defined. Maybe the tutorial refers to an old version?
    xscope_core_int(0, sample);
    pb :> sample;
    // xscope_uint(0, sample); 
    xscope_core_int(1, sample);
while this is the Xk-1A.xn configuration file:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<Network xmlns="http://www.xmos.com"
xsi:schemaLocation="http://www.xmos.com http://www.xmos.com">
  <Name>XK-1A Development Board</Name>

    <Declaration>tileref tile[1]</Declaration>

    <Package id="0" Type="XS1-L1A-TQ128">
        <Node Id="0" InPackageId="0" Type="XS1-L1A" Oscillator="20MHz" SystemFrequency="400MHz">
            <Source Location="SPI:bootFlash"/>
          <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"/>

  <Node Id="1" Type="device:" routingId="0x8000">
    <Service Id="0" Proto="xscope_host_data(chanend c);">
      <Chanend Identifier="c" end="3"/>

    <Link Encoding="2wire" Delays="4,4" Flags="XSCOPE">
        <LinkEndpoint NodeId="0" Link="X0LC" />
        <LinkEndpoint NodeId="1" Chanend="1" />
    <Link Encoding="2wire" Delays="4,4" Flags="XSCOPE">
  <LinkEndpoint NodeId="0" Link="X0LD"/>
  <LinkEndpoint RoutingId="0x8000" Chanend="1"/>

    <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"/>

     <JTAGDevice NodeId="0"/>


I wasn't able to setup the "Run Configuration" since it requires the the code is firstly successfully compiled.

Any suggestions?

Respected Member
Posts: 318
Joined: Tue Dec 15, 2009 12:46 am

Post by richard »

The standard .xn file for the XK-1A already includes an xscope link so there is no need to added a second xscope link to the .xn file. In particular you should be able to remove the following from your .xn file:

Code: Select all

<Link Encoding="2wire" Delays="4,4" Flags="XSCOPE">
  <LinkEndpoint NodeId="0" Link="X0LD"/>
  <LinkEndpoint RoutingId="0x8000" Chanend="1"/>
The tools produce an error because with two XSCOPE links the tools try to create two nodes with the same fixed node ID (0x8000) which means it impossible to route messages between all the nodes in the network.