User manual
Ausgabe 19.05.2017 Copyright by Joy-IT 31
5.10 Project 10: Reading analog values
This project is about the analog interfaces of the Mega2560.
An analogRead() command can the value of the interface.
Because of the Analog-Digital-Converter of the Mega2560, the read-out values are between 0 and 1023.
To be able to read the values, it is important to take care of the right baudrate.
The baudrate of the computer has to meet the requirements of the device.
If you open the serial monitor in your Arduino program, you can congure the baudrate in the boom
right corner.
Here we are going to convert the adjustes value of a potenometer to an analog value and display it on
the screen.
Hardware Amount
Mega2560 board 1
USB cable 1
Potenometer 1
Breadboard 1
Breadboard cable 3