请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
器件型号:CC2650 Thread 中讨论的其他器件:SYSBIOS
你好! 我想使用硬件 RTC 以单时格式获取时间。
处理器大部分时间将处于待机模式。
Seconds.h 模块是否使用硬件 RTC、或者它是否仅处于工作模式?
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.
是的、它使用 RTC
uint32 seconds_get (void)
{
易失性 uint32秒;
UINT 键;
KEY = Hwi_disable();
curSeconds = AONRTCSecGet ();
curSeconds =(curSeconds - seconds_module->refSeconds)+
seconds_module->setSeconds;
Hwi_restore (key);
回波(秒);
}