change function name

This commit is contained in:
reaw55 2024-04-22 22:57:14 +07:00
parent 980687b154
commit 27156e945f
2 changed files with 4 additions and 2 deletions

View file

@ -93,7 +93,7 @@ void handleMqttMessage(char *topic, char *payload)
{ {
// Unused for now // Unused for now
} }
void subscribeToIoTCallbacks() void mqttSubscribeCallback()
{ {
espmega.updateTimeFromNTP(); espmega.updateTimeFromNTP();
} }
@ -165,7 +165,7 @@ void setup()
Serial.print("boot_state.txt=\"MQTT Initializing . . .\""); Serial.print("boot_state.txt=\"MQTT Initializing . . .\"");
sendStopBytes(); sendStopBytes();
espmega.iot->loadMqttConfig(); espmega.iot->loadMqttConfig();
espmega.iot->registerSubscribeCallback(&subscribeToIoTCallbacks); espmega.iot->registerSubscribeCallback(&mqttSubscribeCallback);
espmega.iot->connectToMqtt(); espmega.iot->connectToMqtt();
Serial.print("boot_state.txt=\"Display Initializing . . .\""); Serial.print("boot_state.txt=\"Display Initializing . . .\"");
espmega.enableWebServer(80); espmega.enableWebServer(80);

View file

@ -49,6 +49,8 @@ void loop();
void on_pin_change(uint8_t pin, uint8_t value); void on_pin_change(uint8_t pin, uint8_t value);
void mqttSubscribeCallback();
uint16_t get_pm25_out(); uint16_t get_pm25_out();
uint16_t get_pm25_in(); uint16_t get_pm25_in();
float get_temp_out(); float get_temp_out();