mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
Add BRIDGE_DELAY as a buffer to prevent immediate processing conflicts in the mesh network
This commit is contained in:
parent
1c93c162a1
commit
a55fa8d8ec
3 changed files with 15 additions and 5 deletions
|
|
@ -54,8 +54,8 @@ void RS232Bridge::onPacketTransmitted(mesh::Packet *packet) {
|
|||
// Build packet header
|
||||
buffer[0] = (BRIDGE_PACKET_MAGIC >> 8) & 0xFF; // Magic high byte
|
||||
buffer[1] = BRIDGE_PACKET_MAGIC & 0xFF; // Magic low byte
|
||||
buffer[2] = (len >> 8) & 0xFF; // Length high byte
|
||||
buffer[3] = len & 0xFF; // Length low byte
|
||||
buffer[2] = (len >> 8) & 0xFF; // Length high byte
|
||||
buffer[3] = len & 0xFF; // Length low byte
|
||||
|
||||
// Calculate checksum over the payload
|
||||
uint16_t checksum = fletcher16(buffer + 4, len);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue