You could use an ADS1115 module like this https://www.adafruit.com/product/1085 which can be placed on a breadboard.
Or a board like this: https://shop.pimoroni.com/products/hat- ... 2879056979
The distance sensor GP2Y0A21 is operated from 5V. When ADS1115 is operated from 3.3V, then use input protection for the analog line (series resistor 1k, a schottky diode to Vcc 3.3V). Or power the ADS1115 from 5V, but then add an I2C level shifter.
To avoid such problems, you could switch to a Time of flight sensor like https://www.adafruit.com/product/3317 which has digital interface.
Or a board like this: https://shop.pimoroni.com/products/hat- ... 2879056979
The distance sensor GP2Y0A21 is operated from 5V. When ADS1115 is operated from 3.3V, then use input protection for the analog line (series resistor 1k, a schottky diode to Vcc 3.3V). Or power the ADS1115 from 5V, but then add an I2C level shifter.
To avoid such problems, you could switch to a Time of flight sensor like https://www.adafruit.com/product/3317 which has digital interface.
Statistics: Posted by ghp — Sat Dec 28, 2024 12:08 pm