XU216-512-TQ128 QFlash xflash problem Topic is solved

If you have a simple question and just want an answer.
User avatar
zhengyang0512
Member++
Posts: 27
Joined: Tue Aug 23, 2016 6:14 am

XU216-512-TQ128 QFlash xflash problem

Post by zhengyang0512 »

I have customized a board using the XU216-512-TQ128. The reference design is the Multichannel Audio Board,which uses the XE216-512-TQ128. The QSPI memory type is the IS25LQ080B.
First, using the xtag run as the program, everything works well.
Next, I flash the binary, but the xtimecomposer create the wrong orders:please verify that sqi flash is supported and that correct sqi ports are defined within your xn files

I have read the 《xTIMEcomposer-User-Guide》, IS25LQ080B is in the
30 List of devices natively supported by libquadflash
So I guess the SQI type is good.

My code is simple

Code: Select all

#include <stdio.h>
#include <xs1.h>
#include <platform.h>
port test_led = on tile[0]: {XS1_PORT_1A};

void led_test()
{
    while(1)
    {
        printf("this is a good test\n");
        test_led <: 0;
        delay_milliseconds(1000);
        test_led <: 1;
        delay_milliseconds(1000);
    }
}

int main()
{
    par
    {
        on tile[0]: led_test();
    }
    return 0;
}
And this is my .xn file

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" ManuallySpecifiedRouting="true">
  <Type>Board</Type>
  <Name>XS2 MC Audio</Name>
  <Declarations>
    <Declaration>tileref tile[2]</Declaration>
    <Declaration>tileref usb_tile</Declaration>
  </Declarations>
  <Packages>
    <Package id="0" Type="XS2-UnA-512-FB236">
      <Nodes>
        <Node Id="0" InPackageId="0" Type="XS2-L16A-512" Oscillator="24MHz" SystemFrequency="500MHz" referencefrequency="100MHz">
          <Boot>
            <Source Location="bootFlash"/>
          </Boot>
          <Tile Number="0" Reference="tile[0]">
            <Port Location="XS1_PORT_1B" Name="PORT_SQI_CS"/>
            <Port Location="XS1_PORT_1C" Name="PORT_SQI_SCLK"/>
            <Port Location="XS1_PORT_4B" Name="PORT_SQI_SIO"/>
          </Tile>
          <Tile Number="1" Reference="tile[1]"/>
        </Node>
        <Node Id="1" InPackageId="1" Type="periph:XS1-SU" Reference="usb_tile" Oscillator="24MHz">
        </Node>
      </Nodes>
      <Links>
        <Link Encoding="5wire">
          <LinkEndpoint NodeId="0" Link="8" Delays="52clk,52clk"/>
          <LinkEndpoint NodeId="1" Link="XL0" Delays="1clk,1clk"/>
        </Link>
      </Links>
    </Package>
  </Packages>
  <ExternalDevices>
    <Device NodeId="0" Tile="0" Class="SQIFlash" Name="bootFlash" Type="IS25LQ080B">
      <Attribute Name="PORT_SQI_CS" Value="PORT_SQI_CS"/>
      <Attribute Name="PORT_SQI_SCLK"   Value="PORT_SQI_SCLK"/>
      <Attribute Name="PORT_SQI_SIO"  Value="PORT_SQI_SIO"/>
    </Device>
  </ExternalDevices>
  <JTAGChain>
    <JTAGDevice NodeId="0"/>
    <JTAGDevice NodeId="1"/>
  </JTAGChain>
</Network>
Reading the XU216-512-TQ128 datasheet
8.1 Boot from QSPI master
it says that the pins used for QSPI boot are hardcoded in the boot ROM and cannot be changed.And my design also obey the rules.

By using the cmd tools, "xflash --verbose myprogram.xe", the output is

Code: Select all

XFlash_Options::ListDevices : xgdb --batch -q --ex listdevices devl-e259ed56
XFlash_Application found _start :40000 on Node 0
XFlash_Application found _DoSyscall :40608 on Node 0
XFlash_Application found _DoException :402d0 on Node 0
XFlash_Application found _start :40000 on Node 0
XFlash_Application found _DoSyscall :40444 on Node 0
XFlash_Application found _DoException :40234 on Node 0
XFlash_Application : Attempting to Compress Binary Data
libcompressor marker 1=99
libcompressor marker 2=158
libcompressor marker 3=181
libcompressor best marker length 3 2 2 
libcompressor best marker length 3 2 3 
libcompressor best marker length 3 2 4 
libcompressor DoCompression_Compress took : 132ms
libcompressor compile command=xcc -nostartfiles -Xmapper --bootstyle=forsim -x assembler-with-cpp "decompressor-9556aff5" -x xn "target-xn-v0-be23a400" -o decompressor-21685516
libcompressor validating decompressor decompressor-21685516
libcompressor launching simulator decompressor-21685516 --disable-syscalls --max-cycles 100000000
libcompressor simulator starting @0x40000
libcompressor simulator terminate @0x7ff74
libcompressor decompressor validated
XFlash_Application on Node : 0 compressed from : 5932 bytes to : 4872 bytes (17.87%)
libcompressor marker 1=59
libcompressor marker 2=62
libcompressor marker 3=89
libcompressor best marker length 3 2 2 
libcompressor best marker length 3 2 3 
libcompressor best marker length 3 2 4 
libcompressor best marker length 3 2 5 
libcompressor best marker length 4 2 3 
libcompressor best marker length 4 2 4 
libcompressor best marker length 4 2 5 
libcompressor DoCompression_Compress took : 94ms
libcompressor compile command=xcc -nostartfiles -Xmapper --bootstyle=forsim -x assembler-with-cpp "decompressor-688e2241" -x xn "target-xn-v0-be23a400" -o decompressor-74c0d6fe
libcompressor validating decompressor decompressor-74c0d6fe
libcompressor launching simulator decompressor-74c0d6fe --disable-syscalls --max-cycles 100000000
libcompressor simulator starting @0x40000
libcompressor simulator terminate @0x7ff76
libcompressor decompressor validated
XFlash_Application on Node : 0 compressed from : 3384 bytes to : 2684 bytes (20.69%)
XFlash::DoXFlash
XFlash::DoImageProgramming
XFlash::GetDeviceInfo
XFlash_DeviceInfo::GetDeviceInfo_Hardware
XFlash_DeviceInfo::GetDeviceInfo_Hardware_IssueCompileCommand : xcc -Xmapper --dontenablesodlinks -Xmapper --wnoXN -x xc "spiinfo-17d9f84d" -x xn "target-xn-v0-be23a400" -o "spiinfo-6ec9b307" -lquadflash -D xnPORT_SQI_CS0=PORT_SQI_CS -D xnPORT_SQI_SCLK0=PORT_SQI_SCLK -D xnPORT_SQI_SIO0=PORT_SQI_SIO 
XFlash_Utils::BuildRunCommand : xrun --io spiinfo-6ec9b307 
If anyone knows the problem, please help, than you very much.
View Solution
User avatar
zhengyang0512
Member++
Posts: 27
Joined: Tue Aug 23, 2016 6:14 am

Post by zhengyang0512 »

Yeah, I have solved the problem. The reason is the SQI type, because we choose the same type SQI , but their manufactures are different. And I move the SQI flash on the Multichannel board to the customized board, and the flash works well.
User avatar
Bianco
XCore Expert
Posts: 754
Joined: Thu Dec 10, 2009 6:56 pm

Post by Bianco »

zhengyang0512 wrote:Yeah, I have solved the problem. The reason is the SQI type, because we choose the same type SQI , but their manufactures are different. And I move the SQI flash on the Multichannel board to the customized board, and the flash works well.

Are you saying that you used a IS25LQ080B not produced by ISSI?
User avatar
zhengyang0512
Member++
Posts: 27
Joined: Tue Aug 23, 2016 6:14 am

Post by zhengyang0512 »

Bianco wrote:
zhengyang0512 wrote:Yeah, I have solved the problem. The reason is the SQI type, because we choose the same type SQI , but their manufactures are different. And I move the SQI flash on the Multichannel board to the customized board, and the flash works well.

Are you saying that you used a IS25LQ080B not produced by ISSI?
Yes,although their types are both IS25LQ080B , they have different sizes.