This directory contains simple MicroPython example code covering basic functionality.
- DigitalReadSerial - Read digital input and print to serial
- AnalogReadSerial - Read analog input and print to serial
- ReadAnalogVoltage - Read analog input and convert to voltage
These cover basic digital and analog input, printing to serial, and voltage conversion.
- MicroPython board
- Basic components like buttons, potentiometer, LEDs, resistors
- Connect components according to the comments in each example
- Modify pin assignments and other constants as needed
- Upload code to board
- View serial output in serial monitor
- The examples print the raw digital/analog values and the calculated voltage.
Great starting point for learning MicroPython Similar code works across many boards like ESP32, ESP8266, etc. Adjust pin numbers, calculation constants, etc. as needed
Contributions welcome! Please open an issue or PR for any bugs or improvements.