IO port config - pin as an analog input pin


I am using Renesas RA6M4 with FSP lib (fsp-3.8.0) and having ADC up and running properly in ADC_MODE_SINGLE_SCAN with ADC_TRIGGER_SOFTWARE.

My question is - why is an ADC conversion working fine when having according IO pin in reset/default configuration (PSEL[4:0] 00000b -> (value after reset Hi-Z).

Although IO pin config with

IOPORT_CFG_ANALOG_ENABLE         = 0x00008000, ///< Enables pin to operate as an analog pin

for the pin has never been called - ADC is working properly.
I am confused why ASEL bit does not need to be set to operate properly as an analog input pin.

Do I have to set ASEL bit to 1 to comply with specifications.

Hope you can help me with this issue.

Best regards

Parents Reply
  • Hi Christian,

    It is my understanding that setting ASEL bit to 1 will result to the following settings:

    If someone changes this settings manually through PmnPFS register, as I understand you do, the result will be the same and the analog pin will operate in the same way.

    The ASEL bit does not affect the functionality of ADC, only the pin configuration.

    I hope it helps.



No Data