Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Slider0007 committed Nov 2, 2024
1 parent 2d9c850 commit 5a3fb2e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion code/components/gpio_ctrl/gpioControl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ esp_err_t GpioHandler::loadParameter()
void GpioHandler::clearData()
{
if (gpioMap != NULL) {
for(std::map<gpio_num_t, GpioPin*>::iterator it = gpioMap->begin(); it != gpioMap->end(); ++it) {
for(std::map<gpio_num_t, GpioPin*>::iterator it = gpioMap->begin(); it != gpioMap->end(); it++) {
if (it->second->getSmartLed() != NULL) {
delete it->second->getSmartLed();
it->second->setSmartLed(NULL);
Expand Down Expand Up @@ -631,6 +631,7 @@ void GpioHandler::handleMQTTconnect()
if (gpioMap != NULL) {
for(std::map<gpio_num_t, GpioPin*>::iterator it = gpioMap->begin(); it != gpioMap->end(); ++it) {
it->second->mqttPublishPinState();
vTaskDelay(pdMS_TO_TICKS(500));
}
}
}
Expand Down

0 comments on commit 5a3fb2e

Please sign in to comment.