This video shows an example of using analog inputs in Arduino, taking into account that for the voltage received through an analog port, Arduino returns values from 0 to 1023. A value conversion is performed so that the result is 0V to 5V.
Arduino Course:
• Curso Arduino