VL53L0X Time-of-Flight Ranging Sensor

@ScruffR @RWB @peekay123
I stumbled around hopelessly, couldn’t let it go, and it paid off. With some caveats. As soon as I got it the adafruit library more or less working, Windows 10 decided the photon was a mouse. After an hour of agitated fiddling I managed to solve that. However, my photon won’t use Serial anymore, just Serial1, but through USB not the TX-RX pins. I’m so confused now. Anyway, here’s a link to the code and see what you can make of it. It’s messy beyond belief, embarassingly so, but I have no engineering background so don’t laugh. What got this running was mostly the code provided by jerryn on the adafruit forum a week ago - he rewrote the vl53l0x_i2c_comms.cpp and Adafruit_VL53l0x.cpp files. Give it a whirl. The scaling seems off. Someone else please fix that and get the interrupt going.

2 Likes