Index: firmware/App/Controllers/Switches.c =================================================================== diff -u -rb53c3ab97a715ef9dc823a7148d0c0a52c413865 -r6c1d6a3eaf065c2b2d537d9fef793d73ea328359 --- firmware/App/Controllers/Switches.c (.../Switches.c) (revision b53c3ab97a715ef9dc823a7148d0c0a52c413865) +++ firmware/App/Controllers/Switches.c (.../Switches.c) (revision 6c1d6a3eaf065c2b2d537d9fef793d73ea328359) @@ -7,8 +7,8 @@ * * @file Switches.c * -* @author (last) Sean Nash -* @date (last) 12-Nov-2021 +* @author (last) Dara Navaei +* @date (last) 22-Feb-2022 * * @author (original) Dara Navaei * @date (original) 25-Jul-2021 @@ -30,6 +30,7 @@ #define SWITCHES_DATA_PUB_INTERVAL ( MS_PER_SECOND / TASK_GENERAL_INTERVAL ) ///< Interval (ms/task time) at which the switches data is published on the CAN bus. #define SWITCHES_DEBOUNCE_TIME_MS ( MS_PER_SECOND / 4 ) ///< Switches FPGA status check interval. +#define DATA_PUBLISH_COUNTER_START_COUNT 4 ///< Data publish counter start count. /// Switch status structure typedef struct @@ -61,7 +62,7 @@ { U08 i; - switchesDataPublicationCounter = 0; + switchesDataPublicationCounter = DATA_PUBLISH_COUNTER_START_COUNT; // Initialize all the switches for ( i = 0; i < NUM_OF_DOORS_AND_SWITCHES; i++ )