OpenNuvoton / NUC980_NuWriter_CMD

NUC980 NuWriter Linux command line tool
GNU General Public License v3.0
6 stars 9 forks source link

DDR flash failure? #15

Closed alec-hewitt closed 3 years ago

alec-hewitt commented 3 years ago

Hello there. I've developed a custom board with the NUC980DK61YC based on the IIOT evaluation board. I am having trouble programming the chip. It looks like it is able to see the device, but not flash the internal DDR. I posted a schematic, is there any reason why this won't work? Programming through USB0.

Thank you

The error:

Number of devices: 1
Burn device 1 ...
init_xusb: Burn DDR to Device failed,bResult=-1
initail xusb failed -1
Failed

NUC980_schem.pdf

Edit: I'll add that the build and NuWriter setup is OK, and I'm able to flash & boot the IIOT Evaluation board.

yachen commented 3 years ago

Hi, Below is the reply from our hardware engineer.

Please remove U1 and test again. 1 SNx52x0 cannot be used on USB2.0. 2

alec-hewitt commented 3 years ago

Thank you. Although, I do not actually have this chip installed at the moment. The USB data traces do connect to those pads but the chip is not installed.

If my images work on the NUC980DK61Y, should they certainly work on the NUC980DK61YC?

The response seems to be intermittent: sometimes I receive the message above, sometimes "Device Not Found", and sometimes the parse.c command reaches the point of trying to load image0 ./pattern/u-boot-spl.bin but then says Failed which seems promising.

I do have an SPI NAND flash chip installed. Could this be the issue if it is not working?

Thanks again...

yachen commented 3 years ago

If my images work on the NUC980DK61Y, should they certainly work on the NUC980DK61YC?

Yes.

I do have an SPI NAND flash chip installed. Could this be the issue if it is not working?

No.

Still looks like a USB connection issue. Does your PCB routing follows the 90 Ohm impedance design rule for the DP/DM trace?

alec-hewitt commented 3 years ago

Okay, thanks very much.

I believe it does follow impedance rules, except the routing may be causing issues around U1 perhaps?

layout

yachen commented 3 years ago

Our hardware can't tell what goes wrong with the schematic. Can you contact local distributor for supporting? It should be easier to debug with the hardware in hand.

By the way, attached please find other schematic issues our hardware engineer found but do not cause the NuWriter failure. NUC980_schem suggestion.zip

alec-hewitt commented 3 years ago

Hi there,

Thank you for your responses.

I have built a NEW board with the DK61YC and I now have NOR Flash installed. Is there a default configuration that I should use to build my images and u-boot?

I have tried the nuc980_iot_defconfig and nuc980_defconfig. I CAN flash the chip and it DOES verify the image once flashed, but I can't access the console (I.E. it does not appear to be booting correctly).

Also, any recommendations for env.txt boot commands? Mine is currently:

baudrate=115200 bootcmd=sf probe 0 75000000; sf read 0x7FC0 0x200000 0x800000; bootm 0x7FC0 bootdelay=3 stderr=serial stdin=serial stdout=serial

Using the default settings for NOR Flash in run.ini.

Any help appreciated.

alec-hewitt commented 3 years ago

Nevermind, got it working. Thanks.