Skip to content

Commit

Permalink
Merge pull request #150 from ezloteam/EZPI-442_fix_meshbot_crash_on_e…
Browse files Browse the repository at this point in the history
…nable

fixed meshbot-crashing issue on enable-true/false
  • Loading branch information
lomasSE89 authored Jul 22, 2024
2 parents a67bc7f + 363d613 commit 3a48f54
Show file tree
Hide file tree
Showing 7 changed files with 3,379 additions and 170 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ int ezlopi_scenes_status_change_broadcast(l_scenes_list_v2_t* scene_node, const
cJSON *cj_response = cJSON_CreateObject(__FUNCTION__);
if (cj_response)
{
// vTaskDelay(5000);
cJSON_AddStringToObject(__FUNCTION__, cj_response, ezlopi_id_str, ezlopi_ui_broadcast_str);
cJSON_AddStringToObject(__FUNCTION__, cj_response, ezlopi_msg_subclass_str, method_hub_scene_run_progress);
cJSON *cj_result = cJSON_AddObjectToObject(__FUNCTION__, cj_response, ezlopi_result_str);
Expand All @@ -45,7 +44,6 @@ int ezlopi_scenes_status_change_broadcast(l_scenes_list_v2_t* scene_node, const
cJSON_Delete(__FUNCTION__, cj_notf);
}
}

user_notification_node = user_notification_node->next;
}
}
Expand Down
3 changes: 2 additions & 1 deletion ezlopi-core/ezlopi-core-scenes/ezlopi_core_scenes_v2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1543,6 +1543,7 @@ static bool ___enable_disable_block_en_with_blockId(cJSON* cj_when_block, const
}
}
}

return block_en_changed;
}

Expand All @@ -1567,7 +1568,7 @@ int ezlopi_core_scene_block_enable_set_reset(const char* sceneId_str, const char
cJSON* cj_when_blocks = cJSON_GetObjectItem(__FUNCTION__, cj_scene, "when");
while (NULL != (cj_when_block = cJSON_GetArrayItem(cj_when_blocks, when_block_idx++)))
{
block_enabled_changed = ___enable_disable_block_en_with_blockId(cj_when_block, blockId_str, enable_status);
block_enabled_changed |= ___enable_disable_block_en_with_blockId(cj_when_block, blockId_str, enable_status);
}

if (block_enabled_changed)
Expand Down
5 changes: 5 additions & 0 deletions ezlopi-core/ezlopi-core-wifi/ezlopi_core_wifi.c
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,11 @@ static void __event_handler(void* arg, esp_event_base_t event_base, int32_t even
TRACE_D("wifi-stopped!");
break;
}
case WIFI_EVENT_STA_CONNECTED:
{
TRACE_D("wifi-connected!");
break;
}
default:
{
TRACE_W("un-known wifi-event received: %d", event_id);
Expand Down
Loading

0 comments on commit 3a48f54

Please sign in to comment.