mirror of
https://github.com/meshtastic/firmware.git
synced 2025-04-25 17:42:48 +00:00
Merge branch 'master' into RCWL-9620
This commit is contained in:
commit
675d8fe089
@ -279,6 +279,7 @@ void ScanI2CTwoWire::scanPort(I2CPort port)
|
|||||||
} else { // Unknown device
|
} else { // Unknown device
|
||||||
LOG_INFO("No INA3221 found at address 0x%x\n", (uint8_t)addr.address);
|
LOG_INFO("No INA3221 found at address 0x%x\n", (uint8_t)addr.address);
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
case MCP9808_ADDR:
|
case MCP9808_ADDR:
|
||||||
registerValue = getRegisterValue(ScanI2CTwoWire::RegisterLocation(addr, 0x07), 2);
|
registerValue = getRegisterValue(ScanI2CTwoWire::RegisterLocation(addr, 0x07), 2);
|
||||||
if (registerValue == 0x0400) {
|
if (registerValue == 0x0400) {
|
||||||
|
@ -150,12 +150,12 @@ class NodeDB
|
|||||||
void setLocalPosition(meshtastic_Position position, bool timeOnly = false)
|
void setLocalPosition(meshtastic_Position position, bool timeOnly = false)
|
||||||
{
|
{
|
||||||
if (timeOnly) {
|
if (timeOnly) {
|
||||||
LOG_DEBUG("Setting local position time only: time=%i timestamp=%i\n", position.time, position.timestamp);
|
LOG_DEBUG("Setting local position time only: time=%u timestamp=%u\n", position.time, position.timestamp);
|
||||||
localPosition.time = position.time;
|
localPosition.time = position.time;
|
||||||
localPosition.timestamp = position.timestamp > 0 ? position.timestamp : position.time;
|
localPosition.timestamp = position.timestamp > 0 ? position.timestamp : position.time;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
LOG_DEBUG("Setting local position: latitude=%i, longitude=%i, time=%i, timeestamp=%i\n", position.latitude_i,
|
LOG_DEBUG("Setting local position: latitude=%i, longitude=%i, time=%u, timestamp=%u\n", position.latitude_i,
|
||||||
position.longitude_i, position.time, position.timestamp);
|
position.longitude_i, position.time, position.timestamp);
|
||||||
localPosition = position;
|
localPosition = position;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user