Unable to Read from Nand Flash in TWRK70f120M

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Unable to Read from Nand Flash in TWRK70f120M

823件の閲覧回数
snehahegde
Contributor I

Hi Team,

PFB the code for Reading some of the parameters from Flash:

CWasherFormula *pPumpAMount=NULL;

//for(BYTE byWasherId=0; byWasherId<MAX_WASHERS;byWasherId++)

{

//Location=0;

//byBlockNum=(MAX_WASHERS*2)MAX_PUMPS1+byWasherId;

pPumpAMount=m_argpDataMgr->GetWasherFormulaPtr(0);

if(NULL!=pPumpAMount)

{

Location=(m_dwNumOfVirtPagesPerBlock*(76));

fseek(mpFlashPtr, Location, IO_SEEK_SET);

if(sizeof(CWasherFormula)==read(mpFlashPtr,pPumpAMount,sizeof(CWasherFormula)))

{

m_argpDataMgr->SetWasherFormulaConfig(0,pPumpAMount);

printf("Check ");

}

}

}

I have written the parameters into 76th block of Flash and reading it from the same block. But I find that the control doesn't get into the if block, which is why I am unable to set the data that is read. Kindly let me know how the issue can be resolved.

Thanks and Regards,

Sneha Hegde

0 件の賞賛
返信
1 返信

715件の閲覧回数
Carlos_Musich
NXP Employee
NXP Employee

Hi Sneha,

please find attached an example.

Regards,

Carlos

0 件の賞賛
返信