This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Flashing A Nand Flash ?



Hi All,

I have problem now, I have developed a small project on my DVEVM  DM355 based board, I used nfs file system and a connected it via ethernet to my PC. I have done every thing and It is working very well. I have bought some new Nand Flashes and I want to assembly them to my PCB then I want to load my nfs file system on these NandFlashes. I would like to start my board via NandFlashes Which I have newly bought. How can I load my program to these new Flashes via JTAG? How can I load them UBL and Uboot? I think xds510 can load them UBL and Uboot , but What about Filesystem and my Kernel Image? How can I load them?

 

Best Regards

 

Canibek   

  • Typically, you can load UBL, U-boot, and uImage via CCS and JTAG.  File System may be a little tougher since it is not necessarily ELF format; I am not sure if format depends on file system type chosen (YAFFS2, JFFS...), but normally this is done thru u-boot.  In the end, u-boot is just software so I do not see why you could not port necessary u-boot code and do things via CCS.

    That said, CCS/JTAG is not necessarily the best choice either.  At manufacturing time, having JTAGs at every station can get expensive; an option worth considering is the serial utility posted here

    http://wiki.davincidsp.com/index.php?title=Serial_Boot_and_Flash_Loading_Utility

    Also, the source code for the serial utility is available from link; whereas no such utility source code is available for CCS/JTAG route, meaning you have more source code to write.

  • Infact I have to use JTAG for Flashing nand flash , I am wondering that, Can CCS load File System to nand flash? I want to buy Peedi for nand flash programming. Have you ever had any experince with peedi?
  • Unfortunately, I do not have any experience with peedi.  I have been pinging other people with more CCS experince, but have not heard anything back on accomplishing this via CCS.

  • Dear .juan,

    I changed my mind and Now I try to use DVFlasher. I think this is DVFlasher "http://wiki.davincidsp.com/~davincid/wiki/index.php?title=Serial_Boot_and_Flash_Loading_Utility" on this wiki page .I have download it on my host machine which is open suse 10.3 . I didnt build it . I just extract it and try to use.

    "mono sfh_DM35x....... " command . I achieve erase my nandflash but I didnt load UBL.

     

    I have some questions, I am very new on linux so my linux background is not well.

    Do I have to build this Utility?

    If I should,   which gcc I have to use?

    I use MT29F16G08QAA nandflash on my EVM board, Is this utility support it? I checked  the table D-1 on spraai4, but didn't understand.

    I think for loading UBL - U-BOOT , KERNELIMAGE (U-IMAGE) and FILESYSTEM (MTD3), I need some LoadAddr for nand flash , how can I get them for my MT29F16G08QAA nand flash?

     

    Best Regards

     

    Canibek

     

  • 1) You can use prebuild binaries to run under Windows XP with our EVMs, but you need to ensure .Net framework 2.0 or higher is installed.

    2) If you are not using our EVM and especially if you are using a difference NAND part than the one found on our EVM, you may need to modify the DVFlasher Utility to work with your particular NAND device. (this is also true of any CCS-based application).

    3) spraai4 lists table of NAND Devices supported by RBL for booting purposes.  If you plan on booting from NAND, you need to make sure you pick one oof the devices listed in the table; all NAND devices have a device ID (normally found on NAND part data-sheet), you need to make sure this device ID is listed in the table.

    4) The load address you  need to use is dependant on the block size of the NAND device you choose.  The following wiki article may offer some insight. (similar thought process for othe software components)

    http://wiki.davincidsp.com/index.php?title=Writing_Kernel_Image_to_NAND_Flash

  • Dear Juan;

    I have achieved ,  loading Ubl, U-Boot and uImages via UART. But I wonder that how may I load my file system to my board? We have designed a new DM355 based PCB. There is no Ethernet connection and SD/MMC reader on our pcb . We just have UART and JTAG . At the beginnig we have plan to use PEEDI for loading filesystem via JTAG but we couldn't do it yet. We are working on it. On the other hand we don't want to loose so much time and want to load our file system by an other way. Do you have any suggesiton for us?

     

    Best Regards

     

    Canibek Sagin

  • If you have USB pinned out on your board you may be able to mount a USB mass storage device as an alternative, though if all you really have is UART and JTAG I do not know of a simple solution. I would imagine you could download a filesystem image and burn it to flash using U-Boot with commands like loadb or loads, though I have never tried this myself.

  • I tried to use serial nand flasher for a new nandflash , but I didn't manage to  do this. My new nand flash is MT29F16G08FAA , but on my console it consistly saying same message . I have add this message below .Could you give me some suggestions?

    Best Regards

     

    Canibek Sağın

    -----------------------------------------------------
      TI Serial Flasher Host Program for DM35x
      (C) 2008, Texas Instruments, Inc.
      Ver. 1.10
    -----------------------------------------------------


    Platform is Unix/Linux.
    Flashing NAND with ubl.bin and u-boot.bin.


    Attempting to connect to device /dev/ttyS0...
    Press any key to end this program at any time.


    Waiting for the DM35x...
    BOOTME commmand received. Returning ACK and header...
    ACK command sent. Waiting for BEGIN command...
    Target: BEGIN
    BEGIN commmand received. Sending CRC table...
    CRC table sent. Waiting for DONE...
    DONE received. Sending the UBL...
    DONE received. UBL was accepted.
    UBL transmitted successfully.

    Target:Chip initialization passed!
    Target:TI SFT Version: 1.10
    Target:Booting Catalog Boot Loader
    Target:BootMode = UART

    Waiting for SFT on the DM35x...
    Target:Starting UART Boot...
    Target:BOOTUBL
    BOOTUBL commmand received. Returning CMD and command...
    CMD value sent. Waiting for DONE...
    Target: DONE
    DONE received. Command was accepted.
    Sending the UBL image
    Waiting for SENDIMG sequence...

    Waiting for SFT on the DM35x...
    Target:Starting UART Boot...
    Target:BOOTUBL
    BOOTUBL commmand received. Returning CMD and command...
    CMD value sent. Waiting for DONE...
    Target: DONE
    DONE received. Command was accepted.
    Sending the UBL image
    Waiting for SENDIMG sequence...

    Waiting for SFT on the DM35x...

  • The flash you mention should be supported so I am not sure why it is hanging like this, it appears that the host side is timing out waiting for SENDIMG and trying to start SFT again.

    This sounds like something you may want to report to the Davinci Linux Open Source mailing list, as I believe the author watches for serial loader issues there (in the case it is not seen here).

  • I just tried this sucessfully on my DM355 EVM, see the end of the following post http://community.ti.com/forums/p/2717/9976.aspx#9976

     

  • Hey, I read in the earlier status that you have been able to download the rest of the images using JTAG. Why not use JTAG, download the file system image to the RAM on board, access the U-boot on the serial and use the nand-write commands to flash the image to the NAND device??? This skips to use network on the board. You can use the Download File option in CCS to download it to a memroy location specified!...

    What say??

  • Dear SundarIyer,

    I don't know, your method works or not, but the main problem is our filesystem is 150 MByte and boards DRAM is 128 MByte, I think it doesnt work.

  • Hi,

    What I would propose is to make a small modification in the TI NAND-Flasher utility on the CCS. Basically, the edition that you will need to do is to crack the application to

    1. Read a Block size data from the filesystem image on the host computer via a fread into a local DRAM buffer;

    2. Write the buffer to the block of NAND specific to where you want to start the file system.

    3. Loop through this process until you have written the entire 150MB of image into the flash.

    Once this is done, and you verify it, you must now move this change into the DVFlasher utlity which will allow you to break up the entire FS image into block-sized data and write it to the NAND.

    The CCS portion is to only ensure that you are up with a running file system on your NAND and to make sure that the piece of trick code works!

    Thanx!

    Sundar