This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

how to interrupt the chip from temperature sensor using gpio pin

Hi,

I am working on nRF52832 with MAX30205 temperature sensor , i am comparing the temperature with threshold value  like this if (m_sample <threshold)  then send the data . i want to minimize my power consumption . i want to put my device in sleep mode completely and it should wake up only if it reaches the certain threshold value . can anyone explain me below option and how can i do this

1 .  Either the temperature sensor itself can be programmed with a threshold-value and it can wake the chip up by asserting a GPIO pin on the chip. This method can wake the chip up either from system OFF mode or system ON mode.

Thanks in advance 

Parents
  • From System OFF mode:

    The device can be put into System OFF mode using the POWER register interface. When in System OFF mode, the device can be woken up through one of the following signals:

    1. The DETECT signal, optionally generated by the GPIO peripheral
    2. The ANADETECT signal, optionally generated by the LPCOMP module
    3. The SENSE signal, optionally generated by the NFC module to “wake-on-field”
    4. A reset

    From GPIO Pin configuration

    Pins can be individually configured, through the SENSE field in the PIN_CNF[n] register, to detect either a high level or a low level on their input.

    When the correct level is detected on any such configured pin, the sense mechanism will set the DETECT signal high.

    See PIN_CNF[x] register.

    You need to configure a pin as an input with the DIR register, connected to the input buffer with the INPUT register, with whatever PULL configuration you want, DRIVE is "don't care" when the pin is an input, SENSE whatever logic level change you want. 
    Then put the SoC into SystemOFF. 

    See  GPIO HAL, and nrf_pwr_mgmt_shutdown

  • hi haakonsh

    how can i merge with threshold condition .. when it reaches certain level it should send the data until it should be in sleep mode

Reply Children
Related