Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
thebentern committed Jan 25, 2024
1 parent 4adc564 commit 0af92d1
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
1 change: 0 additions & 1 deletion examples/SendReceiveClient/SendReceiveClient.ino
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ void telemetry_callback(uint32_t from, meshtastic_Telemetry* telemetry) {
}
}


void setup() {
// Try for up to five seconds to find a serial port; if not, the show must go on
Serial.begin(9600);
Expand Down
2 changes: 0 additions & 2 deletions src/mt_internals.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
#define MT_SOFTWARESERIAL_SUPPORTED
#endif

#include "Meshtastic.h"

extern bool mt_debugging;
void mt_debug_print(const char * s);
#define d(s) mt_debug_print(s)
Expand Down
3 changes: 2 additions & 1 deletion src/mt_protocol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -199,8 +199,9 @@ bool handle_mesh_packet(meshtastic_MeshPacket *meshPacket) {
text_message_callback(meshPacket->from, (const char*)meshPacket->decoded.payload.bytes);
} else if (meshPacket->decoded.portnum == meshtastic_PortNum_TELEMETRY_APP) {
meshtastic_Telemetry *telemetry = {0};
if (telemetry_callback != NULL && pb_decode_from_bytes(meshPacket->decoded.payload.bytes, meshPacket->decoded.payload.size, &meshtastic_Telemetry_msg, &telemetry))
if (telemetry_callback != NULL && pb_decode_from_bytes(meshPacket->decoded.payload.bytes, meshPacket->decoded.payload.size, &meshtastic_Telemetry_msg, &telemetry)) {
telemetry_callback(meshPacket->from, telemetry);
}
} else {
// TODO handle other portnums
return false;
Expand Down

0 comments on commit 0af92d1

Please sign in to comment.