Hi,
All of the example projects have a call to patch_func() in the periph_init() function, it's commented as "ROM patch" ... what does this do? And does it need to be called at every wakeup, or could it just be called once?
I've noticed that periph_init() seems to be the place recommended for general initialisation, but for normal BLE apps that use extended sleep this gets called at every wakeup, and if you're looking to optimise for power this can be handled differently.
So things like powering down the module flash can be done once (I'm doing it in reset_indication()) and, in fact, if you don't need to use any pins for that particular wake-up you can just leave the latch and do nothing ... so periph_init() becomes those things only essential on every wakeup ... and the only thing left in there for me is patch_func().
Lee.
嗨,李,
I have escalated your question internally.
Thx, Paolo
Hi Lee.
According to our Team internally, it is recommended to keep this patch_func() API in every wakeup process, The list of patch is large and we cannot definitely say that if patch_func API call does not modify any register value those are related to radio link communication, the some patches are stored in the memories those will be retained in extended sleep mode.
If you are looking for power optimization, the following link might be relatively close to understand what can be done in terms of power optimization in DA14531/30.
http://lpccs-docs.dialog-semiconductor.com/SW_Example/SDK6/DA14531_Power_optimized_dynamic_advertising/description.html
Thanks, PM_Dialog
Thanks ... this is really useful.