Learn MoreFAQsTutorials

7 posts / 0 new
Last post
stanley_yeh
Offline
Last seen:1 year 8 months ago
加入:2016-12-23 06:52
SWITCH pin

Hi there,
We use an oscilloscope to estimate the SWITCH pin (QFN40, no.21 pin),https://imgur.com/a/COPbF
As we know, we can use this pin to know whether DA14585 is in extend sleep mode or not, right?
It is really weird that if I burn the code into SysRAM by using the booter function of SmartSnippets, the SWITCH will always high (never be low).
However, If I burn the same code into Flash, the SWITCH pin will be high only when the DA14585 is awake.
What's the reason?
Thanks you very much!

Keywords:
Device:
MH_Dialog (not verified)
Hi Stanley,

Hi Stanley,

What is the interface used for booter function in smartsnippet? The code can prevent the MCU enter the sleep mode if debugger is in use. Have you tried to use UART to download the code and check the singal on the SWITCH pin ?

STS_Dialog
Offline
Last seen:3 years 3 months ago
加入:2017-06-06 09:26
Hi Stanley_yeh,

Hi Stanley_yeh,

Please check the datasheet of DA14585 in documents tab in datasheet section(page 21), the switch pin (QFN40,no 21 pin) is used as input/output (connection for the external DC-DC converter inductor), it’s not related to extended sleep mode. The switch is always on because the debugger is attached and the CPU is still powered ( the clock stops work).

Thanks,

STS_Dialog

BB_Dialog
Offline
Last seen:5 months 2 weeks ago
Staff
加入:2013-12-05 14:44
Hi,

Hi,

the switch pin will oscillate (switching) when the chip is awake, and it will not oscillate (switching) when the chip is in sleep mode (deep-sleep or extended -sleep).
One side of the DCDC inductor is connected to the SWITCH pin.
The other side of the DCDC inductor is connected to VDCDC, and this side will have a DC voltage of 1.4V when the chip is active.
When in sleep mode the SWITCH pin voltage will be steady (DC, not switching) and the SWITCH pin state is explained below:

The VDCDC voltage (1.4V) will drop when the chip is in sleep mode and eventually will drop to about 0.9V.

This VDCDC voltage is transferred to the SWITCH pin via the DCDC inductor.
It's expected that during sleep mode the voltage at the SWITCH pin is somewhere around 1V.

The longer the sleep period, the lower the measured SWITCH/VDCDC voltage will become, eventually lower than 1V.
Until the chip awakes: the DCDC becomes active, the SWITCH pin will be oscillating/switching and the VDCDC voltage will be restored to 1.4V.

Best regards, BB_Dialog.

Beyondpan
Offline
Last seen:1 year 2 months ago
加入:2017-05-02 08:09
Hi,

Hi,
I met the same situation as mentioned above .

After I had left alone my device for a priod , the VDCDC voltage dropped to around 1V and the device entered the sleep mode.
However, It can't exit from the sleep mode and the VDCDC voltege stayed around 1V until the system was rebooted .

How can you explain the issue ?

MT_dialog
Offline
Last seen:2 weeks 4 days ago
Staff
加入:2015-06-08 11:34
Hi Beyondpan,

Hi Beyondpan,

Please dont post in the middle of the thread since it will make your post for us more difficult to track, you can always create a new thread in order to ask your question.

So, regarding your question, since the VDCDC stays solid in 1V that means that the device never wakes up, so there are two ways that the device can wake up, either via an allready programmed BLE event (an advertising or a connection or a BLE timer event) or asyncronously via an external interrupt. So if you have programmed the device with a fw that keeps on advertising or you are connected to a device then the VDCDC will have to be near the 1.4V when the device is awake, if you have programmer the device with a fw that goes to sleep and never wakes up then the VDCDC will be stuck on 1V until the device accepts an external interrupt in order to wake up.

Thanks MT_dialog

stanley_yeh
Offline
Last seen:1 year 8 months ago
加入:2016-12-23 06:52
I used J-Link(SWDIO interface

I used J-Link(SWDIO interface) to download my code.
I don't know how the booter function of smartsnippet to reset DA14585,
but I used my own batch script to download code and use the j-link command, "w2 50000012 A4", to write 0xA4 to the SYS_CTRL_REG register (0x50000012) for resetting DA14585.
I refer the datasheet, the 7th bit of SYS_CTRL_REG is DEBUGGER_ENABLE, so I think the debugger is enabled because I write 0xA4 to the register.
I will try to write 0x24 into the register.

谢谢你们,我一个m grateful for your help.