Hi,
My Q24 would be restarted when keep on writing to flash? anyone can help me?
if I change times from 100 to 10, no problem.
static const ascii * hEventFlash = “EventDataStore”;
void FlashTest()
{
int i;
ascii buff[100];
s8 sRet;
wm_memset(buff,0,sizeof(buff));
adl_atSendResponse ( ADL_AT_RSP, "FlashTest...\r\n" );
adl_flhSubscribe ( hEventFlash, 310);
// for (i=0;i<10;i++) //no problem
for (i=0;i<100;i++)
{
sRet= adl_flhWrite (hEventFlash, 10, sizeof(buff), (u8* )buff );
if( sRet == OK )
{
adl_atSendResponse(ADL_AT_UNS,“Write OK \r\n” );
}
else if( sRet == ADL_RET_ERR_PARAM )
{
adl_atSendResponse(ADL_AT_UNS,"[Event Flash Write Error]: ADL_RET_ERR_PARAM" );
}
else if( sRet == ADL_RET_ERR_UNKNOWN_HDL )
{
adl_atSendResponse(ADL_AT_UNS,"[Event Flash Write Error]: ADL_RET_ERR_UNKNOWN_HDL" );
}
else if( sRet == ADL_FLH_RET_ERR_ID_OUT_OF_RANGE )
{
adl_atSendResponse(ADL_AT_UNS,"[Event Flash Write Error]: ADL_FLH_RET_ERR_ID_OUT_OF_RANGE" );
}
else if( sRet == ADL_FLH_RET_ERR_MEM_FULL )
{
adl_atSendResponse(ADL_AT_UNS,"[Event Flash Write Error]: ADL_FLH_RET_ERR_MEM_FULL" );
}
else if( sRet == ADL_FLH_RET_ERR_NO_ENOUGH_IDS )
{
adl_atSendResponse(ADL_AT_UNS,"[Event Flash Write Error]: ADL_FLH_RET_ERR_NO_ENOUGH_IDS" );
}
}
adl_atSendResponse ( ADL_AT_RSP, "Done...\r\n" );
}