<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to create ucl for NAND Flash media for Linux in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/How-to-create-ucl-for-NAND-Flash-media-for-Linux/m-p/197083#M10540</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can some help me how to create a script in the ucl file for flashing uboot and Image to NAND flash. I can only see in the existing ucl file a "NAND(UBI)- Android" but none for NAND-Linux. I'm using imx502 device.&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 04 Dec 2012 08:34:18 GMT</pubDate>
    <dc:creator>oliverortega</dc:creator>
    <dc:date>2012-12-04T08:34:18Z</dc:date>
    <item>
      <title>How to create ucl for NAND Flash media for Linux</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-create-ucl-for-NAND-Flash-media-for-Linux/m-p/197083#M10540</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can some help me how to create a script in the ucl file for flashing uboot and Image to NAND flash. I can only see in the existing ucl file a "NAND(UBI)- Android" but none for NAND-Linux. I'm using imx502 device.&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Dec 2012 08:34:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-create-ucl-for-NAND-Flash-media-for-Linux/m-p/197083#M10540</guid>
      <dc:creator>oliverortega</dc:creator>
      <dc:date>2012-12-04T08:34:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to create ucl for NAND Flash media for Linux</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-create-ucl-for-NAND-Flash-media-for-Linux/m-p/197084#M10541</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There's already a script which writes into the nand. Maybe your ucl file doesn't come with this. Anyways i going to paste it.&lt;/P&gt;&lt;P&gt;If you get nay error you should check the following:&lt;/P&gt;&lt;P&gt;1) Your cpio file system should have mtd tools installed.&lt;/P&gt;&lt;P&gt;2) Your u-boot(the one to write in the nand) should support your nand and also should have the CONFIG_CMD_NAND macro enable when you compiled.&lt;/P&gt;&lt;P&gt;3) Ensure the linux kernel ( the one on the mfg tool) detect the nand and mount as mtd device.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can erase the ubi fs part if you don't need that.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;-Israel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the script:&lt;/P&gt;&lt;P&gt;&amp;lt;LIST name="Sabre-ARD-SABREAUTO-NAND" desc="Choose NAND as media"&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="find" body="Recovery" timeout="180"/&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="boot" body="Recovery" file ="u-boot-mx6q-sabreauto-nand.bin" &amp;gt;Loading uboot.&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD type="load" file="uImage-mx6q-sabreauto-nand" address="0x10800000"&lt;/P&gt;&lt;P&gt;&amp;nbsp; loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" &amp;gt;Doing Kernel.&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="load" file="initramfs.cpio.gz.uboot" address="0x10C00000"&lt;/P&gt;&lt;P&gt;&amp;nbsp; loadSection="OTH" setSection="OTH" HasFlashHeader="FALSE" &amp;gt;Doing Initramfs.&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="jump" &amp;gt; Jumping to OS image. &amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="find" body="Updater" timeout="180"/&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ flash_eraseall /dev/mtd0"&amp;gt;Erasing Kernel partition&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;!--burn the uboot to NAND: --&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="send" file="files/u-boot.bin"&amp;gt;Sending U-Boot&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ kobs-ng init --chip_0_device_path=/dev/mtd0 $FILE"&amp;gt;Flashing Bootloader&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;!--burn the kernel to NAND: --&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ flash_eraseall /dev/mtd1"&amp;gt;Erasing rootfs partition&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="send" file="files/uImage-mx6q-sabreauto-nand"&amp;gt;Sending Kernel Image&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ nandwrite /dev/mtd1 -p $FILE"&amp;gt;Flashing Kernel&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;!--burn the rootfs to NAND: --&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ flash_eraseall /dev/mtd2"&amp;gt;Erasing rootfs partition&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ ubiformat /dev/mtd2"/&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ ubiattach /dev/ubi_ctrl -m 2"&amp;gt;Attaching UBI partition&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ ubimkvol /dev/ubi0 -Nrootfs -s67108864"/&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ mkdir -p /mnt/mtd2"/&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ mount -t ubifs ubi0:rootfs /mnt/mtd2"/&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="pipe tar -jxv -C /mnt/mtd2" file="files/rootfs.tar.bz2"&amp;gt;Sending and writting rootfs&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="frf"&amp;gt;Finishing rootfs write&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ umount /mnt/mtd2"&amp;gt;Unmounting rootfs partition&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;CMD&amp;nbsp; type="push" body="$ echo Update Complete!"&amp;gt;Done&amp;lt;/CMD&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/LIST&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="mce_paste_marker"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Apr 2013 16:44:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-create-ucl-for-NAND-Flash-media-for-Linux/m-p/197084#M10541</guid>
      <dc:creator>israelpz</dc:creator>
      <dc:date>2013-04-01T16:44:39Z</dc:date>
    </item>
  </channel>
</rss>

