Hello,
I'm testing extended sleep mode with Beacon reference source (3.40.6).
In arch_main.c, rwip_sleep() is called and returns mode_sleeping and mode_idle. With mode_sleep it seems entering extended sleep mode correctly, but mode_idle, radio and peripherals seems keeping active.
I would like to set radio and peripherals sleeping without mode_idle. Would you tell me how to do this?
谢谢,
关键词:
设备:
嗨Kamagasako,
您可以在Arch_main.c函数中查看命令setbits16(pmu_ctrl_reg,radio_sleep,1);对于Radio和SetBits16(PMU_CTRL_REG,PERIPH_SLEEP,1);对于外围设备。在mode_idle中关闭收音机可能并不是一个好主意,但它没有测试,可能会导致问题。
Thanks MT_dialog
嗨mt_dialog,
我很遗憾最近回答。
当返回mode_idle时,在main_func()中,只需在没有无线电/外围设备睡眠的情况下调用WFI(),似乎增加了功耗。
Would you tell me how to decrease power consumption even if mode_idle? And what is the case when mode_idle is returned?
嗨Kamagasako,
Mode idle returns when the da has nothing to do but its instructed also not to sleep, therefore it passes by the instructions that close the peripherals and the radio and waits for an interrupt to occur. Closing the radio while in mode_idle its probably not such a good idea, but you can give it a try by using thesetbits16(pmu_ctrl_reg,radio_sleep,1);此外,我认为它可以通过使用SetBits16(PMU_CTRL_REG,PERIPH_SLEEP,1)来淘压您尝试它的外围设备;
Thanks MT_dialog
Hi,
我在DA14583DEVKT-B板上使用SDK 5.0.3软件。
我拍摄了“BLE_APP_PERITELAL”(给出了BLE示例项目)。
我希望优化功耗。我需要指导我们如何使DA14583在最低功耗下运行而不影响功能(即BLE数据的传输,甚至有可用的数据)。
问候,
Mahesh Chandana.
嗨mahesh,
The idea for the lowest power consumption is to sleep as long as you can (longer advertising and long connection intervals) and wake up only when nessecary. Besides that you can check the beacon reference design (in advertising mode), where the advertising event period is a bit shorter and allows the 580 to stay awake for each event for a shorter period.
Thanks MT_dialog
Hi,
谢谢你的快速回复。
where I can configure the sleep mode or no sleep mode (i.e normal mode of working). Any document is there for thorough understanding the Power consumption.
问候,
Mahesh Chandana.
嗨mahesh,
In the user_config.h file at the app_default_sleep_mode you can place the values ARCH_SLEEP_OFF for no sleep and ARCH_EXT_SLEEP_ON for sleep. The 580 is awake and cosnumes power during an advertising event and a connection event, and of course when the application keeps it awake, for more info regarding power consumption you can have a look at the AN-B-015 document.
Thanks MT_dialog
Hi,
I have gone through the "AN-B-015". This document describes about how to measure the power consumption.
在我的上下文中,我的应用程序函数必须调用主函数(在无限循环中)。在哪里可以调用我的应用程序函数。如果我将“app_default_sleep_mode”配置为“Arch_ext_sleep_on”,则当应用程序需要CPU时间时,它将如何从睡眠唤醒以执行我的应用程序功能。
在“AN-B-015”中,没有多少信息,如何从睡眠模式切换到正常模式和VISE VESE。
Please guide me to understand how it is handled.
问候,
Mahesh Chandana.
嗨mahesh,
The app_default_sleep_mode will set a default sleep mode for the 580, if you want to configure the sleep mode of your device during runtime you can use the arch_disable_sleep(), arch_set_extended_sleep() and arch_set_deep_sleep() function which can put your device in no sleep mode, extended sleep mode and deep sleep mode accordingly. Also what you can do in order to force your device to stay awake without changing the sleep mode is to use the app_on_ble_powered callback. This callback returns GOTO_SLEEP in order for the 580 to procced in sleeping state or returns KEEP_POWERED and forces the while loop to re-execute the rwip_shedule() and start over. You can have a look at the UM-B-006 document Sleep mode configuration, the functions are a bit different since the document is based on SDK3 but the functionality is the same, or you can have a look at the UM-B-051 document at section 7 where the sleeping mechanism is described in SDK5 terms.
Thanks MT_dialog
Hi,
I taken the "ble_app_peripheral" example code. Just change the "app_default_sleep_mode" to "ARCH_EXT_SLEEP_ON" (in "user_config.h" file).
然后我无法在手机上看到BLE设备名称。
有什么我需要做另外的。
偶然,而我经历了“UM-B-006”文件。
问候,
Mahesh Chandana.
嗨mahesh,
通过停止脱胶过程,否则无法做任何其他事情,您应该能够看到您的设备广告。
Thanks MT_dialog
Hi,
I have tried. I have seen the device name (i.e. "DIALOG-PRPH") initially for few seconds. later I couldn't see the device name.
Only change in the code is to modify the "app_default_sleep_mode" to "ARCH_EXT_SLEEP_ON" (in "user_config.h" file).
重新雷德斯,
Mahesh Chandana.
Hi,
我需要使用哪个API,以便在同步和异步方法中唤醒控制器从延长睡眠到正常模式。
问候,
Mahesh Chandana.
嗨mahesh,
The 580 wakes up syncronously via the BLE timer (the time that is instructed to sleep is controlled via the SDK and it is set to the next BLE event -connection or advertising interval- every time the 580 falls to sleep). Asynchronously you can wake it up either via a wake up interrupt from the Wakeup timer or via the Quadrature decoder or by using a kernel timer. You can check how to use and set the external wake up in the UM-B-051.pdf in section 10.7. For waking up via a kernel timer is quite simple, just set the timer app_easy_timer() and then the 580 will wake up. In both cases the SDK will check if there are any pending BLE event if there aren't any it will fall back to sleep, so if you want to keep your device awake you will have to use the arch_disable_sleep() function do whatever your application needs to do and then enable the sleeping feature (arch_set_extended_sleep()) once more in order to fall back to sleep.
Thanks MT_dialog