-
Notifications
You must be signed in to change notification settings - Fork 163
Closed
Description
Hi there,
for an ESP32-based project, we needed a way to distribute sensors on the two separate hardware wires (Wire. and Wire1.). The modified version of the lib is attached (VL53L0X-2xI2C.zip).
@kevin-pololu Changes are straight forward. Would be great if this could be integrated into the master branch at some point.
How to use:
#include <Wire.h>
#include "VL53L0X-2xI2C.h"
VL53L0X sensor;
VL53L0X sensor2;
Wire.begin(GPIOSDA,GPIOSCL); // initialize I2C w/ I2C pins from config
present = sensor.init(true, &Wire);
Wire1.begin(GPIOSDA2,GPIOSCL2); // initialize I2C w/ I2C pins from config
present2 = sensor2.init(true, &Wire1);
Cheers,
Torben
Metadata
Metadata
Assignees
Labels
No labels