This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to sleep and wake-up according to VDD.

Hello,

I want to make sensor sleep and wake-up according to VDD.

   - When VDD is below 2.8V, Sensor sleep.

   - When VDD is above 2.8V, Sensor wake-up.

Since my board measures battery voltage periodically, I could make sensor sleep.

But I don't have any idea how to wake-up sensor.

I found out that ANADETECT signal can be used.

But it looks like VDD is used as PREFSEL.

I want to use VDD as PSEL. And PREFSEL need to be fixed value, 2.8V.

How could I implement wake-up function?

  • nrf_saadc_channel_config_t channel_config = NRFX_SAADC_DEFAULT_CHANNEL_CONFIG_SE(NRF_SAADC_INPUT_VDD);
    uint32_t err_code = nrfx_saadc_channel_init(0, &channel_config);

    above code connects internal vdd to saadc channel 0. you can check the peripheral example called SAADC in sdk file. once you get the vdd value, you can build a logic around it. but to wake the processor you will need an external circuit to trigger an interrupt. battery level circuits could do the trick for you.

  • Hi

    Are you planning on putting the device into system OFF mode when you put it to sleep? If so I would suggest checking out the LPCOMP peripheral and LPCOMP example, that demonstrates how to use it to wake up when the voltage on an analog input exceeds a set value.

    Best regards,

    Simon

Related