src/vl53l1x.cpp
uint16_t Vl53l1x::readSingle(bool blocking)
{
  writeReg(SYSTEM__INTERRUPT_CLEAR, 0x01); // sys_interrupt_clear_range
  writeReg(SYSTEM__MODE_START, 0x10); // mode_range__single_shot

  if (blocking)
  {
    return read_range(true);
  }
  else
  {
    return 0;
  }
}
// Starts a single-shot range measurement. If blocking is true (the default),
// this function waits for the measurement to finish and returns the reading.
// Otherwise, it returns 0 immediately.
Starts a single-shot range measurement. If blocking is true (the default),
this function waits for the measurement to finish and returns the reading.
Otherwise, it returns 0 immediately.
Starts a single - shot range measurement . If blocking is true ( the default ) this function waits for the measurement to finish and returns the reading . Otherwise it returns 0 immediately .
uint16_t Vl53l1x::readSingle(bool blocking)
{
  writeReg(SYSTEM__INTERRUPT_CLEAR, 0x01); 
  writeReg(SYSTEM__MODE_START, 0x10); 
  if (blocking)
  {
    return read_range(true);
  }
  else
  {
    return 0;
  }
}
uint16_t Vl53l1x :: readSingle ( bool blocking ) { writeReg ( SYSTEM__INTERRUPT_CLEAR , 0x01 ) ; writeReg ( SYSTEM__MODE_START , 0x10 ) ; if ( blocking ) { return read_range ( true ) ; } else { return 0 ; } }
Starts a single-shot range measurement.
Starts a single - shot range measurement .
// sys_interrupt_clear_range // mode_range__single_shot