Index: firmware/App/Controllers/AirTrap.c =================================================================== diff -u -ra5560a2917aa62bcafd8e6a81041ace723237109 -r07c1dbf3b8227766cb584352d9ea86e230270260 --- firmware/App/Controllers/AirTrap.c (.../AirTrap.c) (revision a5560a2917aa62bcafd8e6a81041ace723237109) +++ firmware/App/Controllers/AirTrap.c (.../AirTrap.c) (revision 07c1dbf3b8227766cb584352d9ea86e230270260) @@ -505,5 +505,37 @@ return result; } +/*********************************************************************//** + * @brief + * The testSetAirTrapControl function sets the air trap to start or end + * auto level control. + * @details \b Inputs: none + * @details \b Outputs: airTrapDataPublishInterval + * @param message Override message from Dialin which includes the interval + * (in ms) to override the air trap broadcast interval to. + * @return TRUE if override request is successful, FALSE if not + *************************************************************************/ +BOOL testSetAirTrapControl( MESSAGE_T *message ) +{ + BOOL result = FALSE; + BOOL startControl = FALSE; + + if ( ( TRUE == isTestingActivated() ) && ( sizeof(BOOL) == message->hdr.payloadLen ) ) + { + result = TRUE; + memcpy( &startControl, message->payload, sizeof(BOOL) ); + if ( TRUE == startControl ) + { + startAirTrapControl(); + } + else + { + endAirTrapControl(); + } + } + + return result; +} + /**@}*/