Ethernet (DoIP) Activation Line support

This commit is contained in:
Paul Hollinsky
2021-04-06 22:50:25 -04:00
parent 4e245db94e
commit a6c8acd8e9
28 changed files with 613 additions and 15 deletions
@@ -14,6 +14,8 @@ public:
static constexpr DeviceType::Enum DEVICE_TYPE = DeviceType::RADGigastar;
static constexpr const char* SERIAL_START = "GS";
size_t getEthernetActivationLineCount() const override { return 1; }
protected:
RADGigastar(neodevice_t neodevice) : Device(neodevice) {
getWritableNeoDevice().type = DEVICE_TYPE;
@@ -78,6 +80,13 @@ protected:
};
txNetworks.insert(txNetworks.end(), supportedTxNetworks.begin(), supportedTxNetworks.end());
}
void handleDeviceStatus(const std::shared_ptr<Message>& message) override {
if(!message || message->data.size() < sizeof(radgigastar_status_t))
return;
const radgigastar_status_t* status = reinterpret_cast<const radgigastar_status_t*>(message->data.data());
ethActivationStatus = status->ethernetActivationLineEnabled;
}
};
}