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.

No NAND device found

Guru 20755 points

Hello,

I am using DM8148 custom board with flash nand, but I get "No NAND device found" in u-boot prompt.
I checked the pinmux and it is OK.

I2C: ready

DRAM: 512 MiB
NAND: HW ECC BCH8 Selected
No NAND device found!!!
0 MiB
MMC: OMAP SD/MMC: 0

Thanks for any suggestions,

Ran

  • Hi ,

    What device are you booting from?

    And would you let me know the DVRRDK version?

    BR,

    Eason

  • Hi Eason

    I am booting from uart with DM8148, using DVRRDK 4.1.0.2

    Thanks

    Ran

  • 6366.BB_001_NAND_GPMC.out.txt

    Hi Would you try the test program and see if NAND really works?

  • Hi Eason,

    I got the following 

    "

    [CortexA8] Test Suite version number is 1.0.
    Build Date = Sep 14 2011 : Time = 10:56:06.


    01 Testing NAND Flash...
    NAND MFGID = 12
    NAND DEVID = 12
    Unsupported Manf ID.
    FAIL... error code -1... quitting

    ***ALL Tests Done***

    "

    Now that's strange becuase when I look at datasheet I see:

    manufacture ID: 0x2c

    device ID: 0xAC

    So it seems as if only the low octat is being read, right ?

    Regards,

    Ran

  • 2548.PG2.1_DM814x_baseboard.zip

    Attached is the EVM BSL project.

    You can open it in CCS and check why the Manufacture ID matters.

    If it is a unsupported NAND part number, I am afraid you need to change your NAND flash Type.

  • Ran,

    Make sure also you have the correct setting in the GPMC_CONFIG1_i[13:12] DEVICESIZE bitfield

    For 8-bit NAND chip, set DEVICESIZE to 0x0

    For 16-bit NAND chip, set DEVICESIZE to 0x1

    Regards,
    Pavel

  • Thanks very much! 
    I have some issue when compiling the test program for CCS:
    when I'm trying to compile the CCS test (so that I can make changes in source code), but on load program I get no response in CCS, and the dissasembly window is blank, while with the already compiled bin, I see the code and symbols in assembly and the programs start running on pressing "run". 
    It seems as if something in my compilation of the CCS project is wrong. Do you have any ideas what's the problem with that ?

    Thanks!
    Ran

  • Ran,

    Ran S. said:

    Now that's strange becuase when I look at datasheet I see:

    manufacture ID: 0x2c

    device ID: 0xAC

    So it seems as if only the low octat is being read, right ?

    This test works fine with the DM814x EVM NAND chip (MT29F2G16AADWP:D). This is what I have:

    [CortexA8] Test Suite version number is 1.0.
    Build Date =  Sep 14 2011 : Time = 10:56:06.


    01  Testing NAND Flash...
    NAND MFGID = 2c
    NAND DEVID = ca
    Testing 4 blocks
    Erasing NAND blocks
    NAND Errase successful.
    NAND Errase successful.
    NAND Errase successful.
    NAND Errase successful.
    --> 0 block erase errors
    Programming NAND pages
    Comparing data
    --> 0 page verify errors
        PASS

    ***ALL Tests Done***

    What is your NAND chip? And what exactly you want to change in the source code of the NAND test?

    Best regards,
    Pavel

  • Hi Pavel,

    Right, I also succeeded with the already *.out in the /bin directory , but when I compile and use the new generated .out, than I get no response. Did you try to compile and run the generated binary ?
    It seems that something is wrong with the default build setting in the test project. I download, import and compiled the DM814x RevC from Mistral disgnotics.
    I wanted to change the ddr bandwidth which you mention before, becuase we are using in custom board 8-bit nand, but I can't even change and run in EVM, so I'm stuck...


    Thanks,

    Ran

  • Ran,

    For importing existing CCS project, please refer to the below wiki pages:

    http://processors.wiki.ti.com/index.php/Importing_Projects_into_CCS#Or.2C_use_the_new_TI.C2.A0Resource_Explorer_integrated_into_CCSv5.2_and_later

    http://processors.wiki.ti.com/index.php/Code_Composer_Studio_v5_Users_Guide#Importing_C.2FC.2B.2B_Projects

    Regards,
    Pavel

  • Hi Pavel,

    I did it as instructed, and it seems to imported and compile OK, but when I try to load the program, I see that the compiled binary does not work while the given binary in the zip works fine. I suspect it is a matter of builder compiler settings.

    Does the imported build setting use arm gcc compiler in CCS on windows ?

    Is it possible to attach your EVN test for revC compiled in Windows ?

    Thanks,

    Ran

  • Ran,

    I have Ubuntu OS on my Desktop PC (no Windows at all), thus I am using the linux version of the CCS.

    Could you provide me your flow, step by step, to see if this works fine on the Linux side?

    Regards,
    Pavel

  • Hi Pavel,

    This is the flow on window machine:

    1. download DM814x_Rev_C1.zip from Mistral web page (EVM test for revC base board)

    2. unzip the file

    3. open CCS and file->import and choose: code composer studio->existing CCS Eclipse project, and select all projects

    4. build CMN_OOO_Lib project

    5. build BB_001_NAND_GPMC project

    6. launch target configuration, load GEL DM8148_EVM and connect target (automatic starts the connect script from gel)

    7.  Run->Load->Load program and point to XXX\DM814x Rev C\Release_4.A_PG2.1_baseboard\Base_Board\NAND\Debug\BB_001_NAND_GPMC.out

    The above does not stop in main and PC is garbage, but if instead of 7 I do the following then it works

    7.B.  Run->Load->Load program and point to XXX\bin\BB_001_NAND_GPMC.out

     

    Thanks

    Ran

  • Ran,

    Ran S. said:
    3. open CCS and file->import and choose: code composer studio->existing CCS Eclipse project, and select all projects

    Can you try with importing "Legacy CCSv3.3 Projects" instead of "Existing CCS Eclipse Projects". Does it make any difference?

    Regards,
    Pavel

  • Ran,

    Ran S. said:

    4. build CMN_OOO_Lib project

    5. build BB_001_NAND_GPMC project

    Can you provide me the CCS Console output when you build these two projects.

    Best regards,
    Pavel

  • Hi Pavel,

    It's Attached,

    6406.ccs_build.txt
    **** Clean-only build of configuration Debug for project CMN_000_Lib ****
    
    "D:\\ti\\ccsv5\\utils\\bin\\gmake" -k clean 
    DEL /F  "CMN_000_Lib.lib"
    DEL /F "DM814x_EVM.pp" "DM814x_i2c.pp" "DM814x_i2cGpioExp.pp" 
    DEL /F "DM814x_EVM.obj" "DM814x_i2c.obj" "DM814x_i2cGpioExp.obj" 
    'Finished clean'
    ' '
    
    **** Build Finished ****
    
    **** Build of configuration Debug for project CMN_000_Lib ****
    
    "D:\\ti\\ccsv5\\utils\\bin\\gmake" -k all 
    'Building file: ../DM814x_EVM.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="DM814x_EVM.pp"  "../DM814x_EVM.c"
    'Finished building: ../DM814x_EVM.c'
    ' '
    'Building file: ../DM814x_i2c.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="DM814x_i2c.pp"  "../DM814x_i2c.c"
    'Finished building: ../DM814x_i2c.c'
    ' '
    'Building file: ../DM814x_i2cGpioExp.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="DM814x_i2cGpioExp.pp"  "../DM814x_i2cGpioExp.c"
    'Finished building: ../DM814x_i2cGpioExp.c'
    ' '
    'Building target: CMN_000_Lib.lib'
    'Invoking: TMS470 Archiver'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armar" r "CMN_000_Lib.lib"  "./DM814x_i2cGpioExp.obj" "./DM814x_i2c.obj" "./DM814x_EVM.obj" 
      ==>  new archive 'CMN_000_Lib.lib'
      ==>  building archive 'CMN_000_Lib.lib'
    'Finished building target: CMN_000_Lib.lib'
    ' '
    postBuild.cmd
    process_begin: CreateProcess(NULL, postBuild.cmd, ...) failed.
    make (e=2): The system cannot find the file specified.
    
    gmake[1]: [post-build] Error 2 (ignored)
    ' '
    
    **** Build Finished ****
    
    
    
    
    
    
    
    
    
    **** Clean-only build of configuration Debug for project BB_001_NAND_GPMC ****
    
    "D:\\ti\\ccsv5\\utils\\bin\\gmake" -k clean 
    DEL /F  "BB_001_NAND_GPMC.out"
    DEL /F "main.pp" "nandflash.pp" "nandflash_test.pp" 
    DEL /F "main.obj" "nandflash.obj" "nandflash_test.obj" 
    'Finished clean'
    ' '
    
    **** Build Finished ****
    
    **** Build of configuration Debug for project BB_001_NAND_GPMC ****
    
    "D:\\ti\\ccsv5\\utils\\bin\\gmake" -k all 
    'Building file: ../main.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="main.pp"  "../main.c"
    'Finished building: ../main.c'
    ' '
    'Building file: ../nandflash.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="nandflash.pp"  "../nandflash.c"
    "../nandflash.c", line 78: warning: variable "u16Buff" was set but never used
    'Finished building: ../nandflash.c'
    ' '
    'Building file: ../nandflash_test.c'
    'Invoking: TMS470 Compiler'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --include_path="D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --include_path="D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/inc" --diag_warning=225 -me --enum_type=packed --code_state=32 --preproc_with_compile --preproc_dependency="nandflash_test.pp"  "../nandflash_test.c"
    'Finished building: ../nandflash_test.c'
    ' '
    'Building target: BB_001_NAND_GPMC.out'
    'Invoking: TMS470 Linker'
    "D:/ti/ccsv5/tools/compiler/arm_5.1.1/bin/armcl" -mv7A8 -g --diag_warning=225 -me --enum_type=packed --code_state=32 -z -m"BB_001_NAND_GPMC.map" --warn_sections -i"D:/ti/ccsv5/tools/compiler/arm_5.1.1/lib" -i"D:/EVM8148/DM814x Rev C/Release_4.A_PG2.1_baseboard/common/ccs/Debug" -i"D:/ti/ccsv5/tools/compiler/arm_5.1.1/include" --reread_libs --xml_link_info="BB_001_NAND_GPMC_linkInfo.xml" --rom_model -o "BB_001_NAND_GPMC.out"  -l"CMN_000_Lib.lib" "./nandflash_test.obj" "./nandflash.obj" "./main.obj" "../linker.cmd" -l"libc.a" 
    <Linking>
    warning: creating output section ".data" without a SECTIONS specification
    'Finished building target: BB_001_NAND_GPMC.out'
    ' '
    
    **** Build Finished ****
    

    Best Regards,

    Ran

  • Ran,

    Can you also attach the two *.out files, the one that is working fine and the one that is not working.

    Regards,
    Pavel

  • Hi Pavel,

    Thanks very much for assistance!

    Did you find anything ?

    Regards, Ran

  • Hi Pavel,

    I got the solution from Code Composer forum.

    http://e2e.ti.com/support/development_tools/code_composer_studio/f/81/p/1309735/reply.aspx

    Thank you very much for the support and help !!!

    Ran

  • I now been able to modify the nand project and run it, but I still get wrong manufacture and device ID (0x12 both)

    The pinmux seems to be OK, can it be a matter of gpmc cs values ?
    I see that these registers are defined by default (on powerup before u-boot starts) 0x50000060 ...

    Can it be related to these values ?

    Regards,

    Ran

  • Ran,

    Ran S. said:
    can it be a matter of gpmc cs values ?

    Yes, it can.

    Make sure you have the correct setting in the GPMC_CONFIG1_i[13:12] DEVICESIZE bitfield

    For 8-bit NAND chip, set DEVICESIZE to 0x0

    For 16-bit NAND chip, set DEVICESIZE to 0x1

    Verify also GPMC correct settings in other GPMC registers (like GPMC_CONFIG, GPMC_CONFIG1_i, GPMC_CONFIG7_i).

    Regards,
    Pavel

  • Ran,

    See also the below links:

    http://processors.wiki.ti.com/index.php/TI81XX_PSP_FAQ#NAND

    http://processors.wiki.ti.com/index.php/Determining_compatibility_between_ROM_Bootloader_%28RBL%29_and_Raw_NAND_devices

    http://e2e.ti.com/support/dsp/omap_applications_processors/f/42/t/190187.aspx

    http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/100/t/236870.aspx

    http://e2e.ti.com/support/arm/sitara_arm/f/791/t/242878.aspx

    http://e2e.ti.com/support/arm/sitara_arm/f/791/t/226017.aspx

    http://e2e.ti.com/support/dsp/omap_applications_processors/f/447/t/32706.aspx

    http://e2e.ti.com/support/arm/sitara_arm/f/791/t/202469.aspx

    Regards,
    Pavel