mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-31 23:21:06 +00:00
In autoconf, don't probe Wire unless i2c device is set (#9081)
Found another bit of code that crashes my desktop, by probing the wrong i2c bus.
This commit is contained in:
@@ -243,7 +243,7 @@ void portduinoSetup()
|
|||||||
// RAK6421-13300-S1:aabbcc123456:5ba85807d92138b7519cfb60460573af:3061e8d8
|
// RAK6421-13300-S1:aabbcc123456:5ba85807d92138b7519cfb60460573af:3061e8d8
|
||||||
// <model string>:mac address :<16 random unique bytes in hexidecimal> : crc32
|
// <model string>:mac address :<16 random unique bytes in hexidecimal> : crc32
|
||||||
// crc32 is calculated on the eeprom string up to but not including the final colon
|
// crc32 is calculated on the eeprom string up to but not including the final colon
|
||||||
if (strlen(autoconf_product) < 6) {
|
if (strlen(autoconf_product) < 6 && portduino_config.i2cdev != "") {
|
||||||
try {
|
try {
|
||||||
char *mac_start = nullptr;
|
char *mac_start = nullptr;
|
||||||
char *devID_start = nullptr;
|
char *devID_start = nullptr;
|
||||||
@@ -774,4 +774,4 @@ void readGPIOFromYaml(YAML::Node sourceNode, pinMapping &destPin, int pinDefault
|
|||||||
destPin.line = destPin.pin;
|
destPin.line = destPin.pin;
|
||||||
destPin.gpiochip = portduino_config.lora_default_gpiochip;
|
destPin.gpiochip = portduino_config.lora_default_gpiochip;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user