TK1 custom Board Flashing with SD Card

Hello,
I have made a custom Tegra K1 board, I want to boot from SD card. I followed http://demotomohiro.github.io/hardware/jetson_tk1/setup/external_storage.html as it is. But it is failing.
Kindly if you can let me know!

Terminal:

owais@ubuntu:~/Tegra/Linux_for_Tegra$ sudo ./flash.sh jetson-tk1 mmcblk1p1
copying bctfile(/home/owais/Tegra/Linux_for_Tegra/bootloader/ardbeg/BCT/PM375_Hynix_2GB_H5TC4G63AFR_H5TC4G63CFR_RDA_924MHz.cfg)... done.
copying bootloader(/home/owais/Tegra/Linux_for_Tegra/bootloader/ardbeg/u-boot.bin)... done.
	populating kernel to rootfs... done.
	populating jetson-tk1_extlinux.conf.sdcard to rootfs... done.
done.
copying dtbfile(/home/owais/Tegra/Linux_for_Tegra/kernel/dtb/tegra124-jetson_tk1-pm375-000-c00-00.dtb)... done.
copying cfgfile(/home/owais/Tegra/Linux_for_Tegra/bootloader/ardbeg/cfg/gnu_linux_fastboot_emmc_full.cfg) to flash.cfg... done.
creating gpt(ppt.img)... 

*** GPT Parameters ***
Device Sector Size ------- 512
device size -------------- 15766388736
bootpart size ------------ 8388608
userpart size ------------ 15758000128
Erase Block Size --------- 2097152
FS Buffer size ----------- 4096
Partition Config file ---- flash.cfg
Visible partition flag --- GP1
Primary GPT output ------- PPT->ppt.img
Secondary GPT output ----- GPT->gpt.img
Target device name ------- none

*** PARTITION LAYOUT(20 partitions) ***
[     BCT] BH            0        16383       8.0MiB 
[     PPT] UH            0         4095       2.0MiB ppt.img
[      PT] UH         4096         8191       2.0MiB 
[     EBT] UH         8192        16383       4.0MiB u-boot.bin
[     LNX] UH        16384        49151      16.0MiB 
[     SOS] UH        49152        61439       6.0MiB 
[     NVC] UH        61440        65535       2.0MiB 
[     MPB] UH        65536        77823       6.0MiB 
[     MBP] UH        77824        90111       6.0MiB 
[     GP1] UH        90112        94207       2.0MiB 
[     APP] UV        94208     29454335   14336.0MiB 
[     DTB] UV     29454336     29462527       4.0MiB tegra124-jetson_tk1-pm375-000-c00-00.dtb
[     EFI] UV     29462528     29593599      64.0MiB 
[     USP] UV     29593600     29601791       4.0MiB 
[     TP1] UV     29601792     29609983       4.0MiB 
[     TP2] UV     29609984     29618175       4.0MiB 
[     TP3] UV     29618176     29626367       4.0MiB 
[     WB0] UV     29626368     29630463       2.0MiB 
[     UDA] UV     29630464     30773247     558.0MiB 
[     GPT] UH     30773248     30777343       2.0MiB gpt.img
copying flasher(/home/owais/Tegra/Linux_for_Tegra/bootloader/ardbeg/fastboot.bin)... done.
Existing flashapp(/home/owais/Tegra/Linux_for_Tegra/bootloader/nvflash) reused.
*** Flashing target device started. ***
./nvflash --boardid 0x177 0x00 0x03 --bct PM375_Hynix_2GB_H5TC4G63AFR_H5TC4G63CFR_RDA_924MHz.cfg --setbct --configfile flash.cfg  --create --bl fastboot.bin --odmdata 0x6009C000 --go
Nvflash 4.13.0000 started
BR_CID: 0x34001001741141021c000000060001c0
rcm version 0X400001
Skipping BoardID read at miniloader level
System Information:
   chip name: unknown
   chip id: 0x40 major: 1 minor: 1
   chip sku: 0x0
   chip uid: 0x00000001741141021c000000060001c0
   macrovision: disabled
   hdcp: disabled
   jtag: disabled
   sbk burned: false
   board id: 0
   warranty fuse: 0
   dk burned: false
   boot device: emmc
   operating mode: 3
   device config strap: 0
   device config fuse: 0
   sdram config strap: 0

RCM communication completed
auxInfo->NCTBoardInfo->proc_board_id is 375
auxInfo->NCTBoardInfo->proc_sku is 0
auxInfo->NCTBoardInfo->proc_fab is 3
BCT sent successfully
sending file: tegra124-jetson_tk1-pm375-000-c00-00.dtb
- 59661/59661 bytes sent
tegra124-jetson_tk1-pm375-000-c00-00.dtb sent successfully
odm data: 0x6009c000
downloading bootloader -- load address: 0x83d88000 entry point: 0x83d88000
sending file: fastboot.bin
- 594363/594363 bytes sent
fastboot.bin sent successfully
waiting for bootloader to initialize
bootloader downloaded successfully
ML execution and Cpu Handover took 4 Secs
Partition backup took 0 Secs
setting device: 2 3
deleting device partitions
creating partition: BCT
creating partition: PPT
creating partition: PT
creating partition: EBT
creating partition: LNX
creating partition: SOS
creating partition: NVC
creating partition: MPB
creating partition: MBP
creating partition: GP1
creating partition: APP
creating partition: DTB
creating partition: EFI
creating partition: USP
creating partition: TP1
creating partition: TP2
creating partition: TP3
creating partition: WB0
creating partition: UDA
creating partition: GPT
sending file: ppt.img
\ 2097152/2097152 bytes sent
ppt.img sent successfully
sending file: u-boot.bin
- 439856/439856 bytes sent
u-boot.bin sent successfully
sending file: tegra124-jetson_tk1-pm375-000-c00-00.dtb
- 59661/59661 bytes sent
tegra124-jetson_tk1-pm375-000-c00-00.dtb sent successfully
sending file: gpt.img
\ 2097152/2097152 bytes sent
gpt.img sent successfully
Create, format and download  took 6 Secs
failed executing command 26 NvError 0x120002
command failure/warning: sync failed (bad data)
bootloader status: partition table is invalid, missing required information (code: 14) message: nverror:0x2 (0x2) Sync 5485 flags: 0

Failed flashing ardbeg.

Serial Log:

[0000.000] [TegraBoot] (version UNDEF_BUILD)                                    
[0000.003] Reset reason: power on reset                                         
[0000.007] Processing in recovery mode                                          
[0000.010] Established communication link with host                             
[0001.050] Downloaded bct successfully                                          
[0001.060] No Battery Present                                                   
[0001.063] Sdram initialization is successful                                   
[0001.103] Downloaded DTB successfully                                          
[0001.117] No Battery Present                                                   
[0001.413] Downloaded bootloader successfully                                   
[0001.417] CPU-bootloader entry address: 0x83d88000                             
[0001.422] BoardId: 375                                                         
[0001.424] Vpr Carveout Base=0x0f4600000 Size=0x00ba00000                       
[0001.429] Tsec Carveout Base=0x0f2600000 Size=0x002000000                      
[0001.434] Lp0 Carveout Base=0x0f25ff000 Size=0x000001000                       
[0001.439] Xusb Carveout Base=0x0f2300000 Size=0x000200000                      
[0001.445] Platform-DebugCarveout: 0                                            
[0001.471] CPU power rail is up                                                 
[0001.474] Performing RAM repair                                                
[0001.477] CPU clock init successful                                            
[0001.480] Starting CPU & Halting co-processor
0x00120002, "packet was nacked"

This is a USB error. Was your host a VM? Is the cable known good for use as data and not a third party charger cable?

Hi there,
I have tried both VM and non VM solution. USB cable is the original one that comes with jetson, plus tried couple of others too. Even tried with an active USB hub.But all have the same issue!

Can you let me know if there is any way to test the emmc of my custom Tegra k1 card? I am using RP-SEMC16DA1 as emmc. Memory characterization was passed at 204Mhz, we successfully booted jetson kit with it, but the same process fails at our custom board. (tried on two customs boards, same issue)

It does seem to be a USB error, and perhaps memory is related, but I would not be able to answer about testing since it passed characterization. Would someone from NVIDIA be able to comment on ways to verify if memory is related to the USB failure?

See two relative posts:
[url]https://devtalk.nvidia.com/default/topic/961328/?comment=4964165[/url]
[url]https://devtalk.nvidia.com/default/topic/961327/?comment=4964164[/url]
Please check if it helps.
For more informarion, do you use r21.7?

This looks to be duplicate of 1044037