Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Silabs] Fixing the switch ladder and removing warning flags #35366

Merged
merged 9 commits into from
Sep 11, 2024
20 changes: 14 additions & 6 deletions examples/platform/silabs/BaseApplication.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -802,6 +802,10 @@ void BaseApplication::ScheduleFactoryReset()
{
Provision::Manager::GetInstance().SetProvisionRequired(true);
}
#if SL_WIFI
// Removing the matter services on factory reset
chip::Dnssd::ServiceAdvertiser::Instance().RemoveServices();
lpbeliveau-silabs marked this conversation as resolved.
Show resolved Hide resolved
#endif
PlatformMgr().HandleServerShuttingDown(); // HandleServerShuttingDown calls OnShutdown() which is only implemented for the
// basic information cluster it seems. And triggers and Event flush, which is not
// relevant when there are no fabrics left
Expand Down Expand Up @@ -851,19 +855,23 @@ void BaseApplication::OnPlatformEvent(const ChipDeviceEvent * event, intptr_t)
case DeviceEventType::kThreadConnectivityChange:
case DeviceEventType::kInternetConnectivityChange: {
#ifdef DIC_ENABLE
VerifyOrReturn(event->InternetConnectivityChange.IPv4 == kConnectivity_Established);
if (DIC_OK != dic_init(dic::control::subscribeCB))
if (event->InternetConnectivityChange.IPv4 == kConnectivity_Established)
{
ChipLogError(AppServer, "dic_init failed");
if (DIC_OK != dic_init(dic::control::subscribeCB))
{
ChipLogError(AppServer, "dic_init failed");
}
}
#endif // DIC_ENABLE
#ifdef DISPLAY_ENABLED
SilabsLCD::Screen_e screen;
AppTask::GetLCD().GetScreen(screen);
// Update the LCD screen with SSID and connected state
VerifyOrReturn(screen == SilabsLCD::Screen_e::StatusScreen);
BaseApplication::UpdateLCDStatusScreen(false);
AppTask::GetLCD().SetScreen(screen);
if (screen == SilabsLCD::Screen_e::StatusScreen)
{
BaseApplication::UpdateLCDStatusScreen(false);
AppTask::GetLCD().SetScreen(screen);
}
#endif // DISPLAY_ENABLED
if ((event->ThreadConnectivityChange.Result == kConnectivity_Established) ||
(event->InternetConnectivityChange.IPv6 == kConnectivity_Established))
Expand Down
7 changes: 0 additions & 7 deletions third_party/silabs/SiWx917_sdk.gni
Original file line number Diff line number Diff line change
Expand Up @@ -336,16 +336,9 @@ template("siwx917_sdk") {
libs += [ "${sdk_support_root}/platform/emdrv/nvm3/lib/libnvm3_CM4_gcc.a" ]

cflags += [
"-Wno-maybe-uninitialized",
"-Wno-shadow",
"-Wno-empty-body",
"-Wno-cpp",
"-Wno-missing-braces",
"-Wno-sign-compare",
"-Wno-error",
"-Wno-unknown-warning-option",
"-Wno-unused-variable",
"-Wno-unused-function",
]

foreach(include_dir, _include_dirs) {
Expand Down
Loading