AnsweredAssumed Answered

MFGTool: push command alwais fail

Question asked by Kirill Brilliantov on Aug 11, 2013
Latest reply on Mar 25, 2014 by Karina Valencia Aguilar
Branched to a new discussion

Hello!

I use MFGTool 1.6.2.0.42-g92b97ee and uuc-11.09.01 from LTIB, now I try write all components on NAND.

My ucl.xml:

<LIST name="MobileCam-NAND" desc="Flash system on NAND">

        <CMD type="boot" body="BootStrap" file ="u-boot_mfg.bin" >Load U-Boot.</CMD>

        <CMD type="load" file="uImage" address="0x70800000" loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" >Load Linux.</CMD>

        <CMD type="load" file="initramfs.img" address="0x70B00000" loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" >Doing Initramfs.</CMD>

        <CMD type="jump" >Jumping to OS image.</CMD>

        <CMD type="find" body="Updater" timeout="180"/>

        <CMD type="push" body="send" file="uImage">Send uImage</CMD>

        <CMD type="push" body="$ /root/flash_erase /dev/mtd2 0 0">Erase /dev/mtd2</CMD>

        <CMD type="push" body="$ /root/nandwrite -mp /dev/mtd2" file="uImage">Write Linux on /dev/mtd2</CMD>

        <CMD type="push" body="$ /root/flash_erase /dev/mtd3 0 0">Erase /dev/mtd3</CMD>

        <CMD type="push" body="$ /root/nandwrite -mp /dev/mtd3" file="uImage">Write Linux on /dev/mtd3</CMD>

        <CMD type="push" body="$ mkdir /mnt">Create mount point</CMD>

        <CMD type="push" body="$ mount -t jffs2 /dev/mtdblock4 /mnt">Mount /dev/mtdblock4 to /mnt</CMD>

        <CMD type="push" body="$ rm -rf /mnt/*">Erase /dev/mtdblock4</CMD>

        <CMD type="push" body="pipe tar -xv -C /mnt" file="rootfs.tar">Unpack rootfs</CMD>

        <CMD type="push" body="$ umount /mnt">Umount /mnt</CMD>

</LIST>

 

Unfortunally all stopped on first push command.

Via console I not see any error:
UTP: received command '$ /root/flash_erase /dev/mtd2 0 0'
UTP: executing "/root/flash_erase /dev/mtd2 0 0"
Erasing 128 Kibyte @ 3e0000 -- 100 % complete
UTP: sending Success to kernel for command $ /root/flash_erase /dev/mtd2 0 0.

 

But in log:

Panel A Start <CMD/> type="push" body="$ /root/flash_erase /dev/mtd2 0 0" file="" timeout="10" onError="" text="Erase /dev/mtd2".

1 - Panel A Finished <CMD/> type="push" body="$ /root/flash_erase /dev/mtd2 0 0" file="" timeout="10" onError="" text="Erase /dev/mtd2" FAIL code=-1.

Panel A: failed to run command: type="push" body="$ /root/flash_erase /dev/mtd2 0 0" file="" timeout="10" onError="" text="Erase /dev/mtd2" ,, Error code:-1

 

I not understand this. I try change all shell command on pipe and this work for flashing Linux, I think, but this not work for unpack rootfs, I always found rootfs in directory /mnt, not on NAND.

 

I try use flush command for wait mount, unfortunally it not work, uuc not know it:

Panel A Start <CMD/> type="push" body="flush" file="" timeout="10" onError="" text="Wait mount /dev/mtdblock4".

1 - Panel A Finished <CMD/> type="push" body="flush" file="" timeout="10" onError="" text="Wait mount /dev/mtdblock4" FAIL code=-1.

Panel A: failed to run command: type="push" body="flush" file="" timeout="10" onError="" text="Wait mount /dev/mtdblock4" ,, Error code:-1

 

Why all console commands fail and how can I solve this problem?

Thank you and excuse me my bad englsih.

Outcomes