diff --git a/protobufs b/protobufs index 8d17bb245..f746cd8ad 160000 --- a/protobufs +++ b/protobufs @@ -1 +1 @@ -Subproject commit 8d17bb245298ec14f0a244945fa1970543a8e9a4 +Subproject commit f746cd8add18d4573ba2e06f3ea31408afb3e877 diff --git a/src/mesh/NodeDB.cpp b/src/mesh/NodeDB.cpp index b1dd3d06d..cd3f25198 100644 --- a/src/mesh/NodeDB.cpp +++ b/src/mesh/NodeDB.cpp @@ -289,7 +289,6 @@ void NodeDB::installDefaultDeviceState() snprintf(owner.short_name, sizeof(owner.short_name), "%02x%02x", ourMacAddr[4], ourMacAddr[5]); snprintf(owner.id, sizeof(owner.id), "!%08x", getNodeNum()); // Default node ID now based on nodenum - memcpy(owner.macaddr, ourMacAddr, sizeof(owner.macaddr)); } void NodeDB::init() @@ -375,7 +374,7 @@ void NodeDB::pickNewNodeNum() r = NUM_RESERVED; // don't pick a reserved node number meshtastic_NodeInfo *found; - while ((found = getNode(r)) && memcmp(found->user.macaddr, owner.macaddr, sizeof(owner.macaddr))) { + while ((found = getNode(r))) { NodeNum n = random(NUM_RESERVED, NODENUM_BROADCAST); // try a new random choice LOG_DEBUG("NOTE! Our desired nodenum 0x%x is in use, so trying for 0x%x\n", r, n); r = n; diff --git a/src/mesh/generated/meshtastic/mesh.pb.h b/src/mesh/generated/meshtastic/mesh.pb.h index 62388e94e..25e977d3d 100644 --- a/src/mesh/generated/meshtastic/mesh.pb.h +++ b/src/mesh/generated/meshtastic/mesh.pb.h @@ -372,7 +372,8 @@ typedef struct _meshtastic_User { /* A VERY short name, ideally two characters. Suitable for a tiny OLED screen */ char short_name[5]; - /* This is the addr of the radio. + /* Deprecated in Meshtastic 2.1.x + This is the addr of the radio. Not populated by the phone, but added by the esp32 when broadcasting */ pb_byte_t macaddr[6]; /* TBEAM, HELTEC, etc... diff --git a/src/modules/RangeTestModule.cpp b/src/modules/RangeTestModule.cpp index 020535758..c1b1e4800 100644 --- a/src/modules/RangeTestModule.cpp +++ b/src/modules/RangeTestModule.cpp @@ -152,7 +152,6 @@ ProcessMessage RangeTestModuleRadio::handleReceived(const meshtastic_MeshPacket LOG_DEBUG("---- Node Information of Received Packet (mp.from):\n"); LOG_DEBUG("n->user.long_name %s\n", n->user.long_name); LOG_DEBUG("n->user.short_name %s\n", n->user.short_name); - LOG_DEBUG("n->user.macaddr %X\n", n->user.macaddr); LOG_DEBUG("n->has_position %d\n", n->has_position); LOG_DEBUG("n->position.latitude_i %d\n", n->position.latitude_i); LOG_DEBUG("n->position.longitude_i %d\n", n->position.longitude_i); @@ -192,7 +191,6 @@ bool RangeTestModuleRadio::appendFile(const meshtastic_MeshPacket &mp) LOG_DEBUG("---- Node Information of Received Packet (mp.from):\n"); LOG_DEBUG("n->user.long_name %s\n", n->user.long_name); LOG_DEBUG("n->user.short_name %s\n", n->user.short_name); - LOG_DEBUG("n->user.macaddr %X\n", n->user.macaddr); LOG_DEBUG("n->has_position %d\n", n->has_position); LOG_DEBUG("n->position.latitude_i %d\n", n->position.latitude_i); LOG_DEBUG("n->position.longitude_i %d\n", n->position.longitude_i);