diff --git a/src/led.cpp b/src/led.cpp index 59965dce..76195523 100644 --- a/src/led.cpp +++ b/src/led.cpp @@ -122,7 +122,18 @@ void ledLoop(void *parameter) { LEDState = ((millis() % 200) < 20) ? LED_ON : LED_OFF; // TX data pending } else if (LMIC.opmode & (OP_TXDATA | OP_TXRXPEND)) { - LEDColor = COLOR_BLUE; + // select color to blink by message port + switch (LMIC.pendTxPort) { + case STATUSPORT: + LEDColor = COLOR_RED; + break; + case CONFIGPORT: + LEDColor = COLOR_CYAN; + break; + default: + LEDColor = COLOR_BLUE; + break; + } // small blink 10ms on each 1/2sec (not when joining) LEDState = ((millis() % 500) < 10) ? LED_ON : LED_OFF; // This should not happen so indicate a problem diff --git a/src/paxcounter.conf b/src/paxcounter.conf index 28264cb8..8c5749d5 100644 --- a/src/paxcounter.conf +++ b/src/paxcounter.conf @@ -53,7 +53,7 @@ #define COUNTERPORT 1 // Port on which device sends counts #define RCMDPORT 2 // Port on which device listenes for remote commands #define STATUSPORT 2 // Port on which device sends remote command results -#define CONFIGPORT 3 // Port on which device sends gps query results +#define CONFIGPORT 3 // Port on which device sends config query results #define GPSPORT 4 // Port on which device sends gps query results #define BUTTONPORT 5 // Port on which device sends button pressed signal #define LPP1PORT 1 // Port for Cayenne LPP 1.0 dynamic sensor encoding