15 #ifndef _SPEAKER_CONTROL_HPP 16 #define _SPEAKER_CONTROL_HPP 24 #include "mgos_mqtt.h" 29 struct mg_str* message,
41 void updatePotAdcVal(
void);
48 int32_t currentVolume_;
50 int32_t lastKnownPotAdcVal_;
HandlerError handleReport(char *stateReport)
handle preparing report for the speaker handler used when the handler needs to respond to the ...
Definition: speaker_ctrl_handler.cpp:172
header file for event handler utils
void checkPotVoltage(void)
called by the main polling function to check and update the pot voltage if necessary read the adc vol...
Definition: speaker_ctrl_handler.cpp:277
Definition: speaker_ctrl_handler.hpp:26
static void pwrInputIntHandler(int pin, void *arg)
handler function for when the user turn on/off the physical pot on the speaker This function will eit...
Definition: speaker_ctrl_handler.cpp:40
HandlerError handleRequest(struct mg_connection *mgCon, struct mg_str *message, char *commandName, char *response)
function to handle request passed by aws mqtt Depending on the reques type, the handler will either m...
Definition: speaker_ctrl_handler.cpp:89
contain class declaration for the ParentHandler class
HandlerError
enum defining errors that the system(including master handler and other child handler) may have ...
Definition: event_handler_util.hpp:37
the parent handler class that is the blueprint for other child handlers to implement, it also defines a couple functions that child handler can use
Definition: parent_handler.hpp:31
SpeakerCtrlHandler(void)
Construct a new Speaker Ctrl Handler:: Speaker Ctrl Handler object create a new spekaer handler...
Definition: speaker_ctrl_handler.cpp:61