Skip to content

Commit

Permalink
comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Justin-Mann committed Dec 2, 2024
1 parent 260d28d commit 4c46727
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/detect/ScanI2CTwoWire.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,10 @@ void ScanI2CTwoWire::scanPort(I2CPort port, uint8_t *address, uint8_t asize)

case RAK12035VB_ADDR: // (0x20) can be RAK12023VB Soil Sensor or TCA9535 I2C expander
// Check if it is a RAK12035, if not can assume it is a TCA9535 I2C expander
// additional info about registry values can be found here [https://github.com/RAKWireless/RAK12035_SoilMoisture/blob/main/RAK12035_SoilMoisture.h]
// the check..
// - registry address to interrogate is 0x02,
// - expected value is 0x20
// Additional info about registry values for the RAK12035 can be found here [https://github.com/RAKWireless/RAK12035_SoilMoisture/blob/main/RAK12035_SoilMoisture.h]
registerValue = getRegisterValue(ScanI2CTwoWire::RegisterLocation(addr, 0x02), 1); // get the default address for the device (stored in registry here [0x02]).. should come back as 0x20
LOG_INFO("Checking for RAK12035VB Soil Sensor with registry address 0x02...");
if (registerValue == 0x20) {
Expand Down

0 comments on commit 4c46727

Please sign in to comment.