A MicroPython driver for ADS1115 and ADS1015 analog-to-digital converters, optimized for time-sensitive and IRQ-safe operations.
ADS1x15 is a MicroPython driver for ADS1115 and ADS1015 analog-to-digital converters, enabling precise voltage measurements from analog sensors in embedded systems. It solves the problem of interfacing these ADCs with MicroPython boards by providing optimized, IRQ-safe methods for data acquisition. The driver supports various sampling modes and includes utilities for converting raw ADC values to voltages.
Embedded developers and hobbyists using MicroPython on platforms like ESP8266 or ESP32 who need reliable ADC readings for sensor data acquisition, IoT projects, or real-time monitoring applications.
Developers choose this driver for its time-optimized and interrupt-safe design, which ensures stable performance in real-time environments. It offers comprehensive support for multiple ADS1x15 variants and flexible sampling modes, making it a robust alternative to writing low-level I2C communication code from scratch.
Micropython driver for ADS1115 and ADS1015
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Methods are optimized to avoid RAM allocation in interrupt service routines, ensuring stable readings in real-time applications, as highlighted for IRQ-proof operations.
Supports ADS1115, ADS1114, ADS1113, and ADS1015 with unified classes, handling differences in channels and resolution for flexible hardware integration.
Offers single-shot, continuous timer-triggered, and alert-triggered sampling with configurable rates and thresholds, enabling adaptable data acquisition strategies.
Includes a raw_to_v() method to convert ADC raw values to voltages based on gain settings, simplifying sensor data interpretation without manual calculations.
The README acknowledges timing jitter (e.g., up to 1 ms on ESP8266) and imprecise ADC timers, which can affect high-precision or synchronized sampling applications.
Documentation is minimal, lacking in-depth explanations or troubleshooting guides, requiring users to rely on datasheets and sample code for advanced features.
Designed specifically for MicroPython on platforms like ESP8266/ESP32, it isn't compatible with other environments like CircuitPython without significant modification.
Implementing interrupt-driven modes involves careful configuration of timers and IRQ handlers, as shown in sample code, which can be error-prone for less experienced developers.