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.

Not able to re-run NAND Flash example provided with the StarterWare

Other Parts Discussed in Thread: OMAPL138

Hi there, I am trying to run the NAND example on the OMAPL138 LCDK and its working. However, if I re-run the example it complains that the block is bad ans can't continue. 

I have try to go through the steps the example is doing and there is only one place when the sw will mark the block as bad. And that is only if the erase block function fails to complete. 

With adding breakpoints and removing the function call to mark the block as bad .. it still fails when I try to re-run the example and write to the same location. 

Should I need to do a random write/ read, before using PageWrite command for same block and page? 

I am using -> OMAPL138_StarterWare_1_10_04_01

Thanks in advance.

Regards

Mitesh

  • Mitest process or flashing LCDK and booting from NAND is described herE:
    processors.wiki.ti.com/.../C6748_Development_Kit_(LCDK)

    Regards,
    Rahul

  • Hi there, I am trying to run the NAND example on the OMAPL138 LCDK and its working. However, if I re-run the example it complains that the block is bad ans can't continue.

    How you are re-run the example ?
    Power OFF and Power ON the board and running the example or reloading the code in CCS again and running the code ?

    Please do make sure that you are ersing the flasg before write.

    Also you can define "NAND_DATAINTEGRITY_TEST_WITH_FIXED_ADDR" to test the particular bloack and pages.
    Else you should enter the page no and block no to test.

    How you are testing this example ?
  • Hi Guys, thanks for reply.
    Yes, Titus, I am re-running by reloading the application from CCS. But before every run, I am powering board on / off . And in the UART, I am providing same block and page addresses.

    I have tried to debug the problem and I believe that the problem is with the ECC calculation logic.
    In the example, the eccData buffer on start is set to zero and then in the process of the NandPageWrite, the ECC is enabled and calculated. But while the ECC is written back to the spare bits of page 0,1 & last of a block, It starts with the offset 6! but since the first 6 (0 to 5) bytes were zeros in the eccData buffer the block is marked as BAD! (Because all 64 bytes are written)

    And hence, I am not able to reuse the block again!!

    To recreate the problem:
    Run the example design from CCS and write to block say 0 and page 0 which should complete and then restart the board ans rerun the example design and try to rewrite to the same location!

    Thanks.
  • Yes, some ECC issue is there.
    I'm able to see the problem what you reported, I'm also not able to re use the same block which we tested in earlier.
    I'm not able to see the problem if used the pages 2 to 62 for testing.

  • Hi Titus, it may be because the Bad Block information is stored in page 0, 1 & last? 

    I have a work-around for that: I have initialized the eccData buffer to be all 0xFF. And it all seems to be fine.

    Now, I am trying to use the Internal Data Movement Operations of Nand Flash with ECC enabled, but for some reason I am not able to. Do you guys have some information about how to use it? Thanks. 

    Regards,

    Mitesh

  • Hi Titus, just as a clarification,
    I would like to use the ECC algorithm but for not standard 512 bytes, is this possible?
  • Hi Titus, any update on the issue? You did mention they is some other problem related to ECC.
    I have changed the example such that, it writes and read from same location but it's failing to write second time to the same memory location...

  • Hi Titus, 

    I have created a simple design using the NAND example from StarterWare and having problem with the read write.. 

    I am running this design on the LCDK using all the same timing information. Are the timing information accurate enough? 

    The reason I ask is, in my design I am trying to write data to the same memory location (Same page of the same block) I am always getting ECC errors.

    As a debug I tried writing data with disabling the ECC and I see lots of bit error when I read the data back.. Hence, I am not sure about the timing information.

    I have tried writing in CPU mode and DMA mode but still no difference.

    But if I try to write and read to different memory location, then it's all fine... 

    I don't understand Why???