Improve transports + options
Overdrivr opened this issue · comments
Rémi Bèges commented
For now, transports will allow to not send a frame if buffer is full.
void send(void * buf, uint32_t size)
{
// If user forgot to define transport by calling init_telemetry, abort
if(!transportPtr)
return;
if(transportPtr->writeable() && size > 0)
{
transportPtr->write(outgoingBuffer, size);
}
}
User should be given the choice to wait or discard
Rémi Bèges commented
After preliminary testing, not sure having a block option is such a good idea. It could induce hidden latency hard to debug.
Instead, provide a way to the user to choose TX buffer size, and teach about how to size this buffer properly.
Rémi Bèges commented
User only has to modify value in telemetry_utils.h. Closing