cyw20706 怎么同步系统时间

公告

大中华汽车电子生态圈社区并入开发者社区- 更多资讯点击此

Tip / 登入 to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
joli_4610801
Level 1
Level 1
5 replies posted First question asked First reply posted

请问,

第一:调用哪个函数,可以设置系统RTC时间?

第二:设置完系统时间后,如果设备进入power save模式,当设备由中断或者timer唤醒的时候,RTC时间会清楚吗?如果会,可以有什么办法保存RTC时间吗

0 点赞
1 解答
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

20~30%的数值是从我们FW engineer那里得到的数据,实际测试下来误差也是在这个附近。

在原帖中查看解决方案

0 点赞
7 回复数
lock attach
Attachments are accessible only for community members.
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

请参考附件的工程,设置系统进入HIDOFF 10s之后醒来,根据wiced_power_save_retrieve_state判断是否是从HIDOFF醒来,然后重新配置RTC的时钟。

请注意,RTC使用的是芯片内部的LPO时钟,精度为±20~30%,请评估一下是否满足需求。如果需要更高的精度,需要使用外部时钟。

也可以在每次建立BLE连接时,从对端获取准确的时间进行校准。

0 点赞

cyw20706内部有几个晶振?

精度为±20~30%,的概念是什么?10秒钟,设备内部的LPO时钟会快(或者慢)2~3秒吗?这个一天不得有5,6个小时的时差了吗?

0 点赞
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

HIDOFF状态下,使用的是内部LPO,这个时钟的精度是±20~30%,如果无法满足要求,需要添加外部32k的晶振。或者和对端设备定时校准。

0 点赞

你好,HIDOFF状态,内部LPO的频率是多少?

不进入HIDOFF状态,是不是程序跑起来,RTC也用你们的32K晶振?

cyw20706上有一个24M的晶振,有没有方法用它跑RTC

0 点赞
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

不进入HIDOFF时,RTC使用的也是LPO时钟,频率为32k。如果要提高精度,需要增加外部32k时钟。

0 点赞

你好,在这个文档里面《CYW20706_and_CYW20719_Low-Power_Modes》,提到

Internal LPOs: The internal LPOs belong to the Lean High Land (LHL) domain; therefore, they are always powered

  1. ON. There are two internal LPOs: one which has lower accuracy (~500 ppm) and consumes less current (~2-3 µA),

and another with higher accuracy (~50 ppm) but consumes more current (~10 µA). The PMU calibrates these clocks at

regular intervals to improve their accuracy.

文档里面最大500ppm,和你之前说的±20~30%不一样。到底哪个是正确的?

0 点赞
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

20~30%的数值是从我们FW engineer那里得到的数据,实际测试下来误差也是在这个附近。

0 点赞