IMX.258 uboot and uImage update without Mfgtool

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

IMX.258 uboot and uImage update without Mfgtool

787 Views
recepyigitbasi
Contributor I

Hi Everyone.

I have an IMX.258 board and I want to update u-boot and uImage without MfgTool. Previously, board is programmed with Mtgtool. I can access to telnet console. u-boot and uImage files in filesystem.

rootfs has nandwrite and flash_eraseall commands and ability to write flash is successful. After write process, I am getting a dump with nanddump command. I am able to see the same file contents.

Mfgtool ucl.xm file contents here;(This is working)

<LIST name="UpdateUImage" desc="update kernel">
<CMD type="find" body="BootStrap" timeout="60"/>
<CMD type="init" body="Memory" file ="mx25ddr2.xml" />
<CMD type="load" file="uImage" address="0x80100000" loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" >Doing preLoad."</CMD>
<CMD type="load" file="initramfs.cpio.gz.uboot" address="0x80800000" loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" >Doing preLoad."</CMD>
<CMD type="load" file="u-boot.bin" address="0x83F00000" loadSection="OTH" setSection="APP" HasFlashHeader="TRUE" >Loading OS image.</CMD>
<CMD type="jump" > Jumping to OS image. </CMD>
<CMD type="find" body="Updater" timeout="180"> Wait for MSC device. </CMD>
<CMD type="push" body="mknod class/mtd,mtd0,/dev/mtd0">create new node: MTD0 </CMD>
<CMD type="push" body="mknod class/mtd,mtd1,/dev/mtd1">create new node: MTD1 </CMD>
<CMD type="push" body="mknod class/mtd,mtd2,/dev/mtd2">create new node: MTD2 </CMD>
<CMD type="push" body="mknod class/misc,ubi_ctrl,/dev/ubi_ctrl">create new node: ubi_ctrl </CMD>
<CMD type="push" body="$ flash_eraseall /dev/mtd0">Erasing image partition</CMD>
<CMD type="push" body="$ flash_eraseall /dev/mtd1">Erasing kernel partition</CMD>

<CMD type="push" body="$ echo 1 > /sys/devices/platform/mxc_nandv2_flash.0/disable_bi_swap">disable bi swap</CMD>
<CMD type="push" body="send" file="files/u-boot-signed.bin">Sending signed u-boot.bin</CMD>
<CMD type="push" body="$ nandwrite /dev/mtd0 $FILE -p">Flashing firmware</CMD>
<CMD type="push" body="$ echo 0 > /sys/devices/platform/mxc_nandv2_flash.0/disable_bi_swap">enable bi swap</CMD>

<CMD type="push" body="$ free && echo 3 > /proc/sys/vm/drop_caches && free" timeout="60">release memory</CMD>

<CMD type="push" body="send" file="files/uImage">Sending uImage</CMD>
<CMD type="push" body="$ nandwrite /dev/mtd1 $FILE -p">Flashing firmware</CMD>

<CMD type="push" body="frf">Finish Flashing NAND</CMD>
<CMD type="push" body="$ echo Update Complete!">Done</CMD>
</LIST>

Similarly, I am using these commands to program uboot and uImage in runtime(This is not working)

flash_eraseall /dev/mtd0
flash_eraseall /dev/mtd1
nandwrite /dev/mtd0 /home/user/u-boot-signed.bin -p
nandwrite /dev/mtd1 /home/user/uImage -p

But OS is not booting because after power off and power on, device is opened in programming mode. 

Notes:

*Files using for programming are the same for both cases.(image files in filesystem and Mfgtool image files)

*Without u-boot write, only uImage write is working and booting successfully

Your suggestions are appreciated. Thank you

 

Regards

Labels (4)
0 Kudos
4 Replies

529 Views
recepyigitbasi
Contributor I

Does Custom application run in board itself(for arm)or other machine(win 10)? 

There is a Source code for atk on that link. But it's extension is exe. 

0 Kudos

529 Views
igorpadykov
NXP Employee
NXP Employee

Hi recep

for nand programming without MfgTool may be recommended to use ATK Tool :

Programmers (Flash, etc.) (2)
Flash tool for downloading, programing, dumping and erasing images in Flash memory to the i.MX EVK(REV 1.71)
http://www.nxp.com/products/automotive-products/energy-power-management/pmics/power-management-for-i...

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

529 Views
recepyigitbasi
Contributor I

Hi igor

The main purpose of the programming via console is remote kernel update. Thé board must update kernel itself. I have to program via console or native application in file system

 Thank for your reply. 

0 Kudos

529 Views
igorpadykov
NXP Employee
NXP Employee

Hi recep

there are ATK sources on that link so one can write own custom

application for such purposes.

Best regards
igor

0 Kudos