Many customers reported that their ADC function works on FRDM-KL27Z board but meet issue on their own board. We need to pay attention to the difference between the ADC reference voltages of different packages (on board MKL27Z64VLH4 is 64LQFP package).
This tip introduce the ADC Reference Options on KL17/KL27 32/36pin package
Part number involved:
PTE30/VREF_OUT- connected as the primary reference option on 36-pin and below packages
VDDA/VSSA - connected as the VALT reference option
ADCx_SC2[REFSEL] selects the voltage reference source used for conversions.
About the primary reference option:
- When on-chip 1.2V VREF is enabled, PTE30 pin must be used as VREF_OUT and has to be configured as an analog input, such as ADC0_SE23 (PORTE_PCR30[MUX] = 000).
Notice: this pin needs to connect a capacitor to ground.
- PTE30 can also be used as an external reference voltage input as long as PTE30 is configured as analog input and VREF module is disabled.
It means you can connect external reference voltage to PTE30 pin and use it as ADC reference voltage. (For example 3.3V)