SunFounder 3in1 Kit
Code
Note:
• You can open the file 4.1.turn_the_knob.ino under the path of 3in1-kit\learning_project\4.1.
turn_the_knob.
• Or copy this code into Arduino IDE.
After uploading the codes to the board, you can open the serial monitor to see the reading value of the pin. When
rotating the axis of the potentiometer, the serial monitor will print the value 0~1023.
120 Chapter 4. Basic Projects