mirror of
https://github.com/meshtastic/firmware.git
synced 2026-01-14 13:57:24 +00:00
Mute specific nodes (#9209)
* Regen protobufs * Ensure mute state is set when node is ignored * Added mechanism for toggling muted state * Implement the ability to mute specific nodes * Switch boolean value for bitmask * Correctly toggle bitfield position 2 on-change to mute state * Dont push submodule refs * Log correct info * Trunk fmt * Update protobuf ref to master branch of base * Update src/modules/ExternalNotificationModule.cpp Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Re-sync generated files --------- Co-authored-by: Jason P <applewiz@mac.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
This commit is contained in:
@@ -383,6 +383,16 @@ bool AdminModule::handleReceivedProtobuf(const meshtastic_MeshPacket &mp, meshta
|
||||
}
|
||||
break;
|
||||
}
|
||||
case meshtastic_AdminMessage_toggle_muted_node_tag: {
|
||||
LOG_INFO("Client received toggle_muted_node command");
|
||||
meshtastic_NodeInfoLite *node = nodeDB->getMeshNode(r->toggle_muted_node);
|
||||
if (node != NULL) {
|
||||
node->bitfield ^= (1 << NODEINFO_BITFIELD_IS_MUTED_SHIFT);
|
||||
saveChanges(SEGMENT_NODEDATABASE, false);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case meshtastic_AdminMessage_set_fixed_position_tag: {
|
||||
LOG_INFO("Client received set_fixed_position command");
|
||||
meshtastic_NodeInfoLite *node = nodeDB->getMeshNode(nodeDB->getNodeNum());
|
||||
|
||||
Reference in New Issue
Block a user