From 4a2978736e4cd1ebf1c50ee0368f5af2c3490474 Mon Sep 17 00:00:00 2001 From: Scott Powell Date: Mon, 14 Jul 2025 10:12:27 +1000 Subject: [PATCH] * Sensor: "get acl" command --- examples/simple_sensor/SensorMesh.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/examples/simple_sensor/SensorMesh.cpp b/examples/simple_sensor/SensorMesh.cpp index d169f9b5..d385a552 100644 --- a/examples/simple_sensor/SensorMesh.cpp +++ b/examples/simple_sensor/SensorMesh.cpp @@ -59,7 +59,7 @@ #define LAZY_CONTACTS_WRITE_DELAY 5000 -#define ALERT_ACK_EXPIRY_MILLIS 6000 // wait 6 secs for ACKs to alert messages +#define ALERT_ACK_EXPIRY_MILLIS 8000 // wait 8 secs for ACKs to alert messages static File openAppend(FILESYSTEM* _fs, const char* fname) { #if defined(NRF52_PLATFORM) || defined(STM32_PLATFORM) @@ -497,13 +497,14 @@ void SensorMesh::handleCommand(uint32_t sender_timestamp, char* command, char* r strcpy(reply, "Err - bad pubkey"); } } - } else if (sender_timestamp == 0 && strcmp(command, "getperm") == 0) { - Serial.println("Permissions:"); + } else if (sender_timestamp == 0 && strcmp(command, "get acl") == 0) { + Serial.println("ACL:"); for (int i = 0; i < num_contacts; i++) { auto c = &contacts[i]; + Serial.printf("%04X ", c->permissions); mesh::Utils::printHex(Serial, c->id.pub_key, PUB_KEY_SIZE); - Serial.printf(" %04X\n", c->permissions); + Serial.printf("\n"); } reply[0] = 0; } else {