Skip to content

Pretty up sensor identification output for debugging. #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/vl53l1_class.h
Original file line number Diff line number Diff line change
Expand Up @@ -341,12 +341,12 @@ class VL53L1 : public RangeSensor {
#ifdef DEBUG_MODE
uint8_t byteData;
uint16_t wordData;
status = VL53L1_RdByte(Dev, 0x010F, &byteData);
status = VL53L1_RdByte(Dev, VL53L1_IDENTIFICATION__MODEL_ID, &byteData);
Serial.println("VL53L1 Model_ID: " + String(byteData));
status = VL53L1_RdByte(Dev, 0x0110, &byteData);
status = VL53L1_RdByte(Dev, VL53L1_IDENTIFICATION__MODULE_TYPE, &byteData);
Serial.println("VL53L1 Module_Type: " + String(byteData));
status = VL53L1_RdWord(Dev, 0x010F, &wordData);
Serial.println("VL53L1: " + String(wordData));
status = VL53L1_RdWord(Dev, VL53L1_IDENTIFICATION__MODULE_ID, &wordData);
Serial.println("VL53L1 Module_ID: " + String(wordData));
#endif

if (status == VL53L1_ERROR_NONE) {
Expand Down