S.PORT to Lua telemetry passthrough
The Fifo is created with ```telemetryRegister``` and elements (ID + Value) are taken from the Fifo with ```telemetryPop``` Not tested at all. Just for review / discussion
This commit is contained in:
@@ -269,6 +269,13 @@ void processSportPacket(uint8_t * packet)
|
||||
processSportPacket(id, 6, instance, bool(data & 0x2000000));
|
||||
processSportPacket(id, 7, instance, bool(data & 0x4000000));
|
||||
}
|
||||
else if (id >= DIY_FIRST_ID && id <= DIY_LAST_ID) {
|
||||
#if defined(LUA)
|
||||
if (luaTelemetryFifo) {
|
||||
luaTelemetryFifo->push((LuaTelemetryValue){(uint8_t)id, data});
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
processSportPacket(id, 0, instance, data);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user