2398743_en-US

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

2398743_en-US

2398743_en-US

S32K312 MCU wakeup using ADC trigger RTD3.0.0 S32DS3.5

Hi,

I am using S32k312 controller mini EVBKIT, for checking the functionality of MCU sleep and wakeup. I am trying to make MCU-Wake up through ADC interrupt by giving low threshold and high threshold voltage value in ADC. Do this functionality work to make MCU wakeup.


LavanyaPilli_1-1784889112438.png


Re: S32K312 MCU wakeup using ADC trigger RTD3.0.0 S32DS3.5

Hello @LavanyaPilli

Since ADC module is not available in Standby, you cannot use it to wakeup (unless the ADC pin is used as interrupt wakeup). However, LPCMP is available in Standby, and can be used instead:

Julin_AragnM_2-1784927254532.png

LPCMP reads the analog input pin voltage against a programmable DAC reference and generates a wakeup once the threshold is crossed. You can refer to the following examples:

Best regards,
Julián

Re: S32K312 MCU wakeup using ADC trigger RTD3.0.0 S32DS3.5

Hi,

Thank you for the clarification.
I will evaluate using the LPCMP for the Standby wakeup as you suggested. However, for our application requirements, we still need to implement the ADC interrupt wakeup functionality.
Could you please assist me in verifying MEX file, if the ADC can be configured specifically as an external interrupt wakeup.
Re: S32K312 MCU wakeup using ADC trigger RTD3.0.0 S32DS3.5

Hello @LavanyaPilli,

Sure. If you are using PTA1 (ADC0_S9) as external interrupt wakeup, you can refer to the S32K312_IOMUX.xlsx file to find the assigned WKPU channel:

Julin_AragnM_0-1785173159422.png

PTA1 is WKPU[5], however, you must also add +4 as offset because of the 4 internal wake up sources. This makes PTA1 WKPU_CH_9.

Julin_AragnM_1-1785173923562.png

You must initialize the WKPU unit, and configure the respective channel:

/* WKPU configuration */
Wkpu_Ip_Init(WKPU_INST, &Wkpu_Ip_Config_PB);
Wkpu_Ip_EnableInterrupt(WKPU_INST, Wkpu_Ip_ChannelConfig_PB[0].hwChannel);

You can use the following low power examples as reference:

Best regards,
Julián

Re: S32K312 MCU wakeup using ADC trigger RTD3.0.0 S32DS3.5

Hello @Julián_AragónM ,

Thank you for the reference; it is very helpful. We are currently utilizing the CAN-based wakeup configuration. We will evaluate the ADC-based wakeup setup at a later stage.

Tags (1)
No ratings
Version history
Last update:
2 weeks ago
Updated by: