Skip to content

Commit f4df649

Browse files
committed
Pull request project-chip#1813: [MATTER-3569]: Build Fix for the matter 917 soc and ncp
Merge in WMN_TOOLS/matter from bugfix/soc_ncp_fix_1_3 to silabs_slc_1.3 Squashed commit of the following: commit 73a5bb81a436a993f4c2fa109fc5169ea4f2a08a Author: chbansal <chirag.bansal@silabs.com> Date: Mon May 6 19:58:04 2024 +0530 addressing review comments commit cfc854e464a4a8ea718b6f7f0ed9db31d68359f5 Author: chbansal <chirag.bansal@silabs.com> Date: Mon May 6 19:07:33 2024 +0530 Fixing the matter shell and the thermostat app for 917 SoC commit 6eb346267399db64f123bcc596025c3527ad2ff7 Author: chbansal <chirag.bansal@silabs.com> Date: Mon May 6 16:07:05 2024 +0530 fixing the dishwasher app for 917 sock ... and 6 more commits
1 parent dec986d commit f4df649

File tree

14 files changed

+51
-17
lines changed

14 files changed

+51
-17
lines changed

examples/platform/silabs/FreeRTOSConfig.h

+1
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ extern "C" {
106106
#include <CHIPProjectConfig.h>
107107

108108
#include <stdint.h>
109+
#include <stdio.h> // SLC-FIX
109110

110111
#ifdef SLI_SI91X_MCU_INTERFACE
111112
#include "si91x_device.h"

examples/platform/silabs/MatterConfig.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ CHIP_ERROR SilabsMatterConfig::InitWiFi(void)
374374
// ================================================================================
375375
extern "C" void vApplicationIdleHook(void)
376376
{
377-
#if SLI_SI91X_MCU_INTERFACE && CHIP_CONFIG_ENABLE_ICD_SERVER
377+
#if SI917_M4_SLEEP_ENABLED && CHIP_CONFIG_ENABLE_ICD_SERVER
378378
sl_wfx_host_si91x_sleep_wakeup();
379379
#endif
380380
}

examples/platform/silabs/SiWx917/SiWx917/sl_wifi_if.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,7 @@ sl_status_t join_callback_handler(sl_wifi_event_t event, char * result, uint32_t
274274

275275
#if SL_ICD_ENABLED
276276

277-
#if SLI_SI91X_MCU_INTERFACE
277+
#if SI917_M4_SLEEP_ENABLED // SLC-FIX
278278
/******************************************************************
279279
* @fn sl_wfx_host_si91x_sleep_wakeup()
280280
* @brief
@@ -309,7 +309,7 @@ void sl_wfx_host_si91x_sleep_wakeup()
309309
}
310310
}
311311
}
312-
#endif // SLI_SI91X_MCU_INTERFACE
312+
#endif // SI917_M4_SLEEP_ENABLED
313313

314314
/******************************************************************
315315
* @fn wfx_rsi_power_save()

examples/platform/silabs/SiWx917/SiWx917/sl_wlan_config.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@
1919
#define RSI_CONFIG_H
2020

2121
#include "ble_config.h"
22+
#if SLI_SI91X_MCU_INTERFACE // SLC-FIX
2223
#include "rsi_wisemcu_hardware_setup.h"
23-
#include "rsi_wlan_defines.h"
24+
#endif // SLI_SI91X_MCU_INTERFACE
2425
#include "sl_wifi_device.h"
2526

2627
//! Enable feature

silabs_examples/silabs-sensors/include/AppConfig.h

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
// ---- Lighting Example App Config ----
2525

2626
#define APP_TASK_NAME "Sens"
27+
#define BLE_DEV_NAME "SiLabs-Sensor"
2728

2829
#ifdef DISPLAY_ENABLED
2930
#define SENSOR_NAME "Sensor-App"

slc/component/matter-core-sdk/dnssd_wifi.slcc

+1
Original file line numberDiff line numberDiff line change
@@ -77,5 +77,6 @@ source:
7777
- path: src/lib/dnssd/Resolver_ImplMinimalMdns.cpp
7878
- path: src/lib/dnssd/ServiceNaming.cpp
7979
- path: src/lib/dnssd/TxtFields.cpp
80+
- path: src/lib/dnssd/ResolverProxy.cpp
8081
ui_hints:
8182
visibility: never

slc/component/matter-core-sdk/siwx917_common.slcc

-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ include:
3131
- path: PigweedLogger.h
3232
- path: FreeRTOSConfig.h
3333
- path: Rpc.h
34-
- path: heap_4_silabs.h
3534
- path: TemperatureSensor.h
3635
- path: silabs_creds.h
3736
- path: SilabsTestEventTriggerDelegate.h
@@ -53,7 +52,6 @@ source:
5352
- path: examples/platform/silabs/LEDWidget.cpp
5453
- path: examples/platform/silabs/SiWx917/SiWx917/sl_wifi_if.cpp
5554
- path: examples/platform/silabs/SiWx917/SiWx917/wfx_rsi_host.cpp
56-
- path: examples/platform/silabs/heap_4_silabs.c
5755
- path: examples/platform/silabs/syscalls_stubs.cpp
5856
- path: src/platform/silabs/SiWx917/wifi/dhcp_client.cpp
5957
- path: src/platform/silabs/SiWx917/wifi/ethernetif.cpp

slc/component/matter-platform/matter_platform_siwx917.slcc

+6-3
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ config_file:
1212
path: examples/platform/silabs/FreeRTOSConfig.h
1313

1414
requires:
15+
- name: sl_system
1516
- name: matter_provision
1617
- name: matter_siwx917
1718
- name: matter_siwx917_common
@@ -20,10 +21,12 @@ requires:
2021
- name: si91x_debug
2122
- name: sl_system_init
2223
- name: nvm3_default
24+
- name: memory_manager
25+
- name: memory_manager_pool_light
26+
- name: freertos_heap_3
2327

2428
provides:
2529
- name: matter_platform_siwx917
26-
- name: freertos_heap
2730
- name: device
2831
- name: wiseconnect_toolchain_gcc_override
2932
- name: matter_si91x_common_flash_nvm3_enabled
@@ -36,7 +39,6 @@ include:
3639
- path: silabs_utils.h
3740
- path: LEDWidget.h
3841
- path: MatterConfig.h
39-
- path: heap_4_silabs.h
4042
- path: OTAConfig.h
4143
- path: matter_shell.h
4244
- path: MemMonitoring.h
@@ -45,7 +47,6 @@ include:
4547
source:
4648
- path: examples/platform/silabs/BaseApplication.cpp
4749
- path: examples/platform/silabs/silabs_utils.cpp
48-
- path: examples/platform/silabs/heap_4_silabs.c
4950
- path: examples/platform/silabs/MatterConfig.cpp
5051
- path: examples/platform/silabs/SoftwareFaultReports.cpp
5152
define:
@@ -81,3 +82,5 @@ toolchain_settings:
8182
value: -Wno-unused-variable
8283
- option: gcc_compiler_option
8384
value: -Wno-unused-function
85+
- option: gcc_compiler_option
86+
value: -Wno-unused-parameter

slc/component/matter-wifi/rs911x/siwx917_ncp_extension.slcc

+3
Original file line numberDiff line numberDiff line change
@@ -52,3 +52,6 @@ define:
5252
- name: SL_WIFI_COMPONENT_INCLUDED
5353
- name: __WEAK
5454
value: "__attribute__((weak))"
55+
toolchain_settings:
56+
- option: gcc_compiler_option
57+
value: -Wno-unused-parameter

slc/sample-app/dishwasher-app/siwx917/dishwasher-app-917-soc.slcp

+6
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ component:
8383
from: matter
8484
- id: matter_power_source
8585
from: matter
86+
- id: matter_ota_support
87+
from: matter
88+
- id: matter_fw_upgrade_917
89+
from: matter
8690

8791
- id: sl_si91x_common_flash_nvm3
8892
from: wiseconnect3_sdk
@@ -110,6 +114,8 @@ component:
110114
from: wiseconnect3_sdk
111115
- id: ble
112116
from: wiseconnect3_sdk
117+
- id: sl_si91x_soc_soft_reset
118+
from: wiseconnect3_sdk
113119
- id: network_manager
114120
from: wiseconnect3_sdk
115121
- id: sl_si91x_button_917

slc/sample-app/thermostat/siwx917/thermostat-917-soc.slcp

+2
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,8 @@ component:
7070
from: matter
7171
- id: matter_ota_requestor
7272
from: matter
73+
- id: matter_ota_support
74+
from: matter
7375
- id: matter_software_diagnostics
7476
from: matter
7577
- id: matter_thermostat

src/platform/silabs/BLEManagerImpl.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class BLEManagerImpl final : public BLEManager, private BleLayer, private BlePla
8080

8181
#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING
8282
#if (SLI_SI91X_ENABLE_BLE || RSI_BLE_ENABLE)
83-
static void HandleC3ReadRequest(void);
83+
static void HandleC3ReadRequest(rsi_ble_read_req_t * rsi_ble_read_req);
8484
#else
8585
#if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING
8686
static void HandleC3ReadRequest(volatile sl_bt_msg_t * evt);

src/platform/silabs/SiWx917/wifi/wfx_notify.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -203,12 +203,12 @@ void wfx_ip_changed_notify(int got_ip)
203203
********************************************************************************************/
204204
void wfx_retry_interval_handler(bool is_wifi_disconnection_event, uint16_t retryJoin)
205205
{
206-
#if SL_ICD_ENABLED
206+
#if SI917_M4_SLEEP_ENABLED
207207
if (m4_alarm_initialization_done == false)
208208
{
209209
initialize_m4_alarm();
210210
}
211-
#endif // SL_ICD_ENABLED
211+
#endif // SI917_M4_SLEEP_ENABLED
212212
if (!is_wifi_disconnection_event)
213213
{
214214
/* After the reboot or a commissioning time device failed to connect with AP.
@@ -217,7 +217,7 @@ void wfx_retry_interval_handler(bool is_wifi_disconnection_event, uint16_t retry
217217
if (retryJoin < MAX_JOIN_RETRIES_COUNT)
218218
{
219219
SILABS_LOG("wfx_retry_interval_handler : Next attempt after %d Seconds", CONVERT_MS_TO_SEC(WLAN_RETRY_TIMER_MS));
220-
#if SL_ICD_ENABLED
220+
#if SI917_M4_SLEEP_ENABLED
221221
// TODO: cleanup the retry logic MATTER-1921
222222
if (!chip::Server::GetInstance().GetCommissioningWindowManager().IsCommissioningWindowOpen())
223223
{
@@ -232,7 +232,7 @@ void wfx_retry_interval_handler(bool is_wifi_disconnection_event, uint16_t retry
232232
}
233233
#else
234234
vTaskDelay(pdMS_TO_TICKS(WLAN_RETRY_TIMER_MS));
235-
#endif // SL_ICD_ENABLED
235+
#endif // SI917_M4_SLEEP_ENABLED
236236
}
237237
else
238238
{
@@ -251,14 +251,14 @@ void wfx_retry_interval_handler(bool is_wifi_disconnection_event, uint16_t retry
251251
retryInterval = WLAN_MAX_RETRY_TIMER_MS;
252252
}
253253
SILABS_LOG("wfx_retry_interval_handler : Next attempt after %d Seconds", CONVERT_MS_TO_SEC(retryInterval));
254-
#if SL_ICD_ENABLED
254+
#if SI917_M4_SLEEP_ENABLED
255255
set_alarm_interrupt_timer(retryInterval / 1000);
256256
wfx_rsi_power_save(RSI_SLEEP_MODE_8, STANDBY_POWER_SAVE_WITH_RAM_RETENTION);
257257
// TODO: remove this once TICKLESS_IDLE is applied. MATTER-3134
258258
sl_wfx_host_si91x_sleep_wakeup();
259259
#else
260260
vTaskDelay(pdMS_TO_TICKS(retryInterval));
261-
#endif // SL_ICD_ENABLED
261+
#endif // SI917_M4_SLEEP_ENABLED
262262
retryInterval += retryInterval;
263263
}
264264
}

src/platform/silabs/rs911x/ble_config.h

-1
This file was deleted.
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
/*******************************************************************************
2+
* @file ble_config.h
3+
* @brief
4+
*******************************************************************************
5+
* # License
6+
* <b>Copyright 2020 Silicon Laboratories Inc. www.silabs.com</b>
7+
*******************************************************************************
8+
*
9+
* The licensor of this software is Silicon Laboratories Inc. Your use of this
10+
* software is governed by the terms of Silicon Labs Master Software License
11+
* Agreement (MSLA) available at
12+
* www.silabs.com/about-us/legal/master-software-license-agreement. This
13+
* software is distributed to you in Source Code format and is governed by the
14+
* sections of the MSLA applicable to Source Code.
15+
*
16+
******************************************************************************/
17+
18+
// SLC-FIX
19+
#include <rsi_ble_config.h>

0 commit comments

Comments
 (0)