TI中文支持网
TI专业的中文技术问题搜集分享网站

CC1310: 软件复位时,如果正在操作flash,会出现什么问题

Part Number:CC1310

如题,如果有一个任务正在操作擦写flash,此时另一个任务调用SysCtrlSystemReset去复位芯片。

底层是否会等待flash擦写结束后再去复位芯片?

Cherry Zhou:

您好,我们已收到您的问题并升级到英文论坛寻求帮助,如有答复将尽快回复您。谢谢!

,

Cherry Zhou:

您好,

不存在底层等待闪存擦除完成的情况。以下是 SysCtrlSystemReset 的代码:

SysCtrlSystemReset( void )
{// Disable CPU interruptsCPUcpsid();// Write reset registerHWREGBITW( AON_SYSCTL_BASE + AON_SYSCTL_O_RESETCTL, AON_SYSCTL_RESETCTL_SYSRESET_BITN ) = 1;// Finally, wait until the above write propagateswhile ( 1 ) {// Do nothing, just wait for the reset (and never return from here)}
}

但我们认为,在擦除闪存时,让闪存擦除任务被抢先并不太好。 此外,请参阅driverlib 文档中的以下内容:

Please note that code can not execute in flash while any part of the flash is being programmed or erased. The application must disable interrupts that have interrupt routines in flash. This function calls a ROM function which handles the actual program operation.

所以建议您在闪存被擦除时阻止任何其他任务运行。 

赞(0)
未经允许不得转载:TI中文支持网 » CC1310: 软件复位时,如果正在操作flash,会出现什么问题
分享到: 更多 (0)