Hi,
I'm trying to implement any sleep mode on the DA14531 which does not cause a system reset. Can you please provide which sleep modes cause a reset and if a specific sleep mode does not trigger a reset, where does the execution continue from and what will be the state of the BLE connection?
From looking at the proxr_reporter code,
Extended sleep - Continues execution on wakeup
Deep Sleep - Triggers a reset on wakeup
Hibernation - Continues execution on wakeup
请确认是否这些observations are correct and also can you share the link to any documentation which pertains to sleep modes other thanhttp://lpccs-docs.dialog-semiconductor.com/DA14531_Sleep_Mode+/index.html
Thanks,
Gowtham
Keywords:
Device:
Hi Gowtham,
If you've not already done so, I'd recommend reviewing the following document:
http://lpccs-docs.dialog-semiconductor.com/Tutorial_SDK6/index.html
The first couple of chapters provide a high level explaination of the operation of the SDK and the associated callbacks, and give some details of sleep modes.
I'd also recommend the empty_peripheral_template as a starting point for any code you are going to write yourself (and this is the basis of the tutorial i mentioned above).
Best regards
IM_Dialog
Hi IM_Dialog,
I followed your suggestion and started a new project with empty_peripheral_template. I have a few more questions
Thanks
Hi tsgowtham,
I assume that, when you are using the Power Profiler, you are running code on the DA14531 under the control of the debugger. This is OK, however once you start the code running you need to disconnect the debugger by pressing "Ctrl+F5", otherwise the debugger remains active and draws current.
Best regards
IM_Dialog
Hi IM_Dialog,
Thanks for a quick reply. Disabling the debugger fixed that. Now the current consumption is around 0.7 mA when it's in extended sleep mode. But this is still way higher than the 1.2 µA mentioned for Buck mode in the sleep mode tutorial document. Granted that the tutorial used 5 sec as the advertising interval but I doubt the difference is supposed to be this drastic. Anything I'm missing here?
Could you also please provide answers for my 2 other questions I had mentioned in myy last comment. I'm posting it again down here:
Thanks
Hi tsgowtham,
Please refer to my answer to your questions below:
When the sleep interval is long enough (such as 2s), the two external sleep modes are meaningful
Br, Yibin
Hi Yibin,
Your answers were really informative and helpful. Thank you!
One last thing I'm stuck at is the high power consumpion in Extended Sleep mode( Mentioned in my last reply) which is at 0.7 mA approximately, without the debugger attached. How can I bring this value closer to the 1.2 µA mentioned in the sleep mode tutorial.
Thanks
Hi,
In order to eliminate the interference of other factors, can you do a test first, as follows:
0. Unplug all jumpers on J19 on 531 dev-kit
1. Download the firmware of prox_reporter project in SDK into FLASH on 531 dev-kit
2. Unplug and reinsert the USB cable
3. Open SS toolbox -> select UART/SPI interface -> open power-profile tool
Pls tell me what you see on the screen of power-profile tool.
Br, Yibin
Hi Yibin,
I have attached the power profiler output for the proxr project. I used the pre built downloadable firmware available in the Flash Programer tool. This output seems closer to what is expected. Why is there such a huge difference in the current consumption between these two projects? Is there any other project configuration which might be causing this?
@Jon_ODonnell
Try calibrating the power profiler, maybe that might help in giving a proper reading for the prox reporter project. Also, 0.167 mA for the barebones project looks like a bit too much for the extended sleep mode, would be better if Yibin clarifies this though.
Thanks,
Gowtham
@Yibin,
I set the calibration to 0 mA and ran with no board installed. The average current was 1.77 mA! I tried putting -1.77 in the calibration offset, but then I got negative current. The numbers jumped around.
I suspect both the offset and gain are having problems. Do I have a bad board? I just purchased it from Digi-key.
I attached a pic of the board to show jumpers, etc. and some screen shots.
Jon
I found the problem!For some reason, the current drawn from the SPI-Flash is also measured and it is not going into the low power sleep. If I remove the J1 V_FL jumper, the current goes down to 0.02 mA during the calibration.
I removed the jumper and added a wire from J1-1 to J9-2 to power the flash without measuring the current.
The average current for the DA14531-DA14585-586_Service_Data_Beacon is now onlt 0.008 mA with peak of 2.816 mA. The prox_reporter still measures a 0.000000 mA flat-line. The barebones gives 0.156 mA average and 2.893 mA peak.
An update to my last comment:
I tried flashing my empty-peripheral-template project with Extended sleep enabled to the Flash. I saw an average currrent consumption of 0.24596 mA and a peak currrent of 3.97961 mA. The average current still seems a bit high too high for extended sleep.
I am having the same problem. I started with DA14531-DA14585-586_Service_Data_Beacon which sets
app_default_sleep_mode = ARCH_EXT_SLEEP_ON;
but the current between advertisements in the unmodified example is about 1.7mA. Changing to ARCH_SLEEP_OFF increases the current to 1.9mA.
This is with using the SmartBond Flash Programmer and cycling power to the Dev Kit before making the measurements.
I downloaded prox_reporter (both built from SDK source and the pre-built "Download online firmware" version from the SmartBond Flash Programmer) and the both the peak and average current measured as requested is 0.00000 mA. The graph is a straight line at the bottom (see attached pdf).
I verifed with BLE Scanner that the DLG-PROXR device was advertizing every 689ms.
I also tried the pre-built ble_app_barebone_531.out.bin from the online resources. The current looked more normal with an average of 0.16758 mA and peak of 3.181 mA.
Please let me know if I should move this discussion to a different thread. It appears to be the same problem, but I do not want to hijack the thread.
Jon
Hi Jon,
So w/o the SPI flash issue you are facing one problem of the "zero current consumption" with prox_reporter? Can you confirm the steps suggested by Yibin?
0. Unplug all jumpers on J19 on 531 dev-kit
1. Download the firmware of prox_reporter project in SDK into FLASH on 531 dev-kit
2. Unplug and reinsert the USB cable
3. Open SS toolbox -> select UART/SPI interface -> open power-profile tool
Br,
PW_Dialog
Those are the steps I performed. With the F_FL jumper on J1 installed, the zero current measures 1.7 mA. When I remove the jumper and repeat the test, the zero current is 0.020 mA. Changing the calibration offset to -0.02 results in an average current of -0.0005 mA.
Hi,
In my last comment I have posted a screen shot of the power profiler and the averag current consumed is 0.02mA after I programmed the flash. This is still higher than the expected 1.2µA. What else should I try to reduce the current consumption?
Thanks
Hi tsgowtham,
Could you please take a look at the Sleep mode tutorial from our support website? Link is provided below.
http://lpccs-docs.dialog-semiconductor.com/DA14531_Sleep_Mode+/index.html
Thanks, PM_Dialog
Hi PM_Dialog,
I have gone through this document. As a matter of fact, I have even added it in my original post.
I'll post my final query here again for clarity:
The average current consumed in Extended Sleep mode is 0.02 mA(measured using the power profiler) and the sleep mode tutorial says that it should be around 1.2 micro Amps. I have written the program to the SPI Flash in the DA14531 module and disconnected the jumpers for the Flash on the motherboard. How can I get the average current consumption close to the given 1.2 micro amps range?
Thanks
Hi tsgowtham,
In the Sleep mode tutorial, the tables with extended sleep mode currents are for the DA14531. In your initial post, the DA14531 module is tagged. Please refer to the module’s datasheet and see Table 4: DC Characteristics.
You mentioned that the average current consumption is 0.02 mA. What is the advertising interval that you are using? Here, the device is advertising and goes into extended sleep mode between advertising intervals and it will automatically wakes up via the BLE timer.
If you follow that sleep mode tutorial, you will see that the after the advertising period, the chip will stop advertising and is going into permanent sleep mode (without BLE activity). How mush is the current consumption in permanent sleep mode?
Additionally, can you please indicate the project that you are using? If you could share it with me it would be helpful in order to run it in my side too.
Thanks, PM_Dialog
Hi PM_Dialog,
Sorry for replying after a long time.
The average consumption is 0.02 mA with the advertising interval at 687.5 ms. This is with the prox_reporter project. The current consumption when it is in permanent sleep is 0.01 mA.
I tried using the template project with Extended sleep mode enabled to test the current consumption. With this project, I observed a 0.2 mA current consumption with advertising interval of 687.5 ms . I have attached this project and it's just a one line change in the template project.
Edit: Is there any difference in these 2 projects which result in such a large difference in current consumption even though both are using Extended sleep mode and the same advertising interval?
Hi tsgowtham,
empty_peripheral_template不停止广告ising, so the device sleep between advertising or connection intervals. The prox_reporter is using advertising with time-out, so the system is going into sleep mode not only between advertising or connection intervals, bus once the advertising is stopped and it goes into permanent sleep mode. However, the prox_reporter is using the SPI flash, so to reduce the power consumption, you need to power it down and release it once the device wakes up.
Thanks, PM_Dialog
Hi PM_Dialog,
I had spoken to Dialog's represantative in my city and he gave me a similar suggestion and told me to configure the SPI pins. This solved my problem and drastically reduced the power consumption.
Thanks a lot for helping with my questions!!
A suggestion, it would be great if your suggestion could be mentioned in some documentation for the DA14531 module. I'm pretty sure a person new to using these kinds of Flash ICs would not think of this.
Thanks
Hi tsgowtham,
Glad that you are able to reduce the power consumption and thanks for accepting my answer. Thanks for your feedback too!
Regards, PM_Dialog