Micron MT29F NAND driver

The READ ID (90h) command is used to read ONFI signature programmed into the target. This command is accepted by the target only when all die (LUNs) on the target are idle.

Parameters:
[out]flash_width*buffer: buffer contains device id
Returns:
Return code
Return values:
NAND_SUCCESS
Pseudo Code Steps
  1. Send read id command (90h)
  2. Send address for read id (00h)
  3. Wait tWHR nanoseconds before read
  4. Read the ONFI signature

Definition at line 205 of file nand_MT29F_lld.c.

References ADDR_READ_ID_ONFI, CMD_READID, NAND_SUCCESS, NUM_OF_READIDONFI_BYTES, PLATFORM_Close(), PLATFORM_Open(), PLATFORM_ReadData(), PLATFORM_SendAddr(), PLATFORM_SendCmd(), PLATFORM_Wait(), and TIME_WHR.

                                                {
   MT_uint32 i;

   /* init board transfer */
    PLATFORM_Open();

    /* send command and/or address */
    PLATFORM_SendCmd(CMD_READID);
    PLATFORM_SendAddr(ADDR_READ_ID_ONFI);

    /* wait (see datasheet for details) */
    PLATFORM_Wait(TIME_WHR);

    /* read output */
    for(i=0; i<NUM_OF_READIDONFI_BYTES; i++)
      buffer[i] = PLATFORM_ReadData();

    /* close board transfer */
    PLATFORM_Close();

    return NAND_SUCCESS;
}