skip version request for modem 0x0D

This commit is contained in:
MichaelDvP
2020-10-16 09:49:10 +02:00
parent e0144a1bce
commit ad77828c0f

View File

@@ -473,7 +473,9 @@ void EMSESP::process_UBADevices(std::shared_ptr<const Telegram> telegram) {
uint8_t device_id = ((data_byte + 1) * 8) + bit;
// if we haven't already detected this device, request it's version details, unless its us (EMS-ESP)
// when the version info is received, it will automagically add the device
if ((device_id != EMSbus::ems_bus_id()) && !(EMSESP::device_exists(device_id))) {
// always skip modem device 0x0D, it does not reply to version request
// see https://github.com/proddy/EMS-ESP/issues/460#issuecomment-709553012
if ((device_id != EMSbus::ems_bus_id()) && !(EMSESP::device_exists(device_id)) && (device_id != 0x0D)) {
LOG_DEBUG(F("New EMS device detected with ID 0x%02X. Requesting version information."), device_id);
send_read_request(EMSdevice::EMS_TYPE_VERSION, device_id);
}