cancel
Showing results for 
Search instead for 
Did you mean: 

STM32G0 MCSDK: Using RCM for extra ADC channel – correct approach?

Mathan Raja
Associate III

Hi,

I am using STM32G0 with STM32 Motor Control SDK. ADC1 is used for motor current sensing (triggered by TIM1 for FOC control).

Since STM32G0 has only one ADC and does not support injected channels, I needed to read an additional NTC sensor (ADC channel 8) for motor stator temperature.

I implemented this using Regular Conversion Manager (RCM):

  • Registered ADC channel using RCM_RegisterRegConv()

  • Requested conversion periodically (~300 ms)

  • Read the value after conversion completion

The motor is running stable, and I am able to get temperature readings without visible disturbance.

My question:
Is this a correct and recommended approach for reading an additional analog signal in STM32G0 + MCSDK?

Are there any potential risks (timing issues, FOC accuracy impact) when using RCM alongside motor control?

Or is there a better recommended method for this use case (e.g., external ADC, different MCU, or MCSDK-specific approach)?

Thank you.

1 ACCEPTED SOLUTION

Accepted Solutions
GMA
ST Employee

Hello @Mathan Raja,

This is the correct method according to the comment feature description available in the regular_conversion_manager.c file.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA

View solution in original post

1 REPLY 1
GMA
ST Employee

Hello @Mathan Raja,

This is the correct method according to the comment feature description available in the regular_conversion_manager.c file.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA