![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Prints data bits, range status, and distance (mm)
Fork of VL53L1X_Pololu by
Diff: VL53L1X.h
- Revision:
- 1:67ced5a2c689
- Parent:
- 0:76ea242a637f
diff -r 76ea242a637f -r 67ced5a2c689 VL53L1X.h --- a/VL53L1X.h Mon Jul 30 18:45:53 2018 +0000 +++ b/VL53L1X.h Tue Jul 31 23:47:38 2018 +0000 @@ -1300,9 +1300,9 @@ // check if sensor has new reading available // assumes interrupt is active low (GPIO_HV_MUX__CTRL bit 4 is 1) bool dataReady() { - int isThereData = readReg(GPIO__TIO_HV_STATUS); - printf("%x\r\n", isThereData); - return (isThereData & 0x01) == 0; + int isThereData = readReg(GPIO__TIO_HV_STATUS); + //printf("Data: %x\r\n", isThereData); /* Returns 3 */ + return (isThereData & 0x01) == 0; } static const char * rangeStatusToString(RangeStatus status);