Skip to content

Commit 9575c13

Browse files
committed
examples: add the register factoryreset command in examples
1 parent 11c2f66 commit 9575c13

File tree

19 files changed

+21
-3
lines changed

19 files changed

+21
-3
lines changed

examples/all_device_types_app/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ On boot-up esp-idf console starts. In order to create a device user have to use
2424

2525
- Use `create --device_type` to list all supported device types.
2626
- Use `create --device_type=on_off_light` to create light device.
27-
- To delete existing device perform `matter device factoryreset`.
27+
- To delete existing device perform `matter esp factoryreset`.
2828
- To add new device, say fan or any other device type use `create --device_type=fan`.
2929

3030
Setup OTBR for a device

examples/all_device_types_app/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,7 @@ extern "C" void app_main()
216216
#if CONFIG_ENABLE_CHIP_SHELL
217217
esp_matter::console::diagnostics_register_commands();
218218
esp_matter::console::wifi_register_commands();
219+
esp_matter::console::factoryreset_register_commands();
219220
esp_matter::console::init();
220221
#ifdef CONFIG_OPENTHREAD_CLI
221222
esp_matter::console::otcli_register_commands();

examples/bridge_apps/blemesh_bridge/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ extern "C" void app_main()
145145

146146
#if CONFIG_ENABLE_CHIP_SHELL
147147
esp_matter::console::diagnostics_register_commands();
148+
esp_matter::console::factoryreset_register_commands();
148149
esp_matter::console::init();
149150
#endif
150151
}

examples/bridge_apps/bridge_cli/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ extern "C" void app_main()
9797
esp_matter::console::diagnostics_register_commands();
9898
esp_matter::console::wifi_register_commands();
9999
esp_matter::console::bridge_register_commands();
100+
esp_matter::console::factoryreset_register_commands();
100101
esp_matter::console::init();
101102
#endif
102103
}

examples/bridge_apps/esp-now_bridge_light/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,7 @@ extern "C" void app_main()
193193
#if CONFIG_ENABLE_CHIP_SHELL
194194
esp_matter::console::diagnostics_register_commands();
195195
esp_matter::console::wifi_register_commands();
196+
esp_matter::console::factoryreset_register_commands();
196197
esp_matter::console::init();
197198
#endif
198199
}

examples/bridge_apps/zigbee_bridge/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ extern "C" void app_main()
145145
#if CONFIG_ENABLE_CHIP_SHELL
146146
esp_matter::console::diagnostics_register_commands();
147147
esp_matter::console::wifi_register_commands();
148+
esp_matter::console::factoryreset_register_commands();
148149
esp_matter::console::init();
149150
#endif
150151
launch_app_zboss();

examples/controller/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ extern "C" void app_main()
7171
#if CONFIG_ENABLE_CHIP_SHELL
7272
esp_matter::console::diagnostics_register_commands();
7373
esp_matter::console::wifi_register_commands();
74+
esp_matter::console::factoryreset_register_commands();
7475
esp_matter::console::init();
7576
#if CONFIG_ESP_MATTER_CONTROLLER_ENABLE
7677
esp_matter::console::controller_register_commands();

examples/demo/badge/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,7 @@ extern "C" void app_main()
361361

362362
esp_matter::console::diagnostics_register_commands();
363363
esp_matter::console::wifi_register_commands();
364+
esp_matter::console::factoryreset_register_commands();
364365
esp_matter::console::init();
365366
#endif
366367
}

examples/door_lock/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@ extern "C" void app_main()
212212
#if CONFIG_ENABLE_CHIP_SHELL
213213
esp_matter::console::diagnostics_register_commands();
214214
esp_matter::console::wifi_register_commands();
215+
esp_matter::console::factoryreset_register_commands();
215216
#if CONFIG_OPENTHREAD_CLI
216217
esp_matter::console::otcli_register_commands();
217218
#endif

examples/generic_switch/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ extern "C" void app_main()
245245
#if CONFIG_ENABLE_CHIP_SHELL
246246
esp_matter::console::diagnostics_register_commands();
247247
esp_matter::console::wifi_register_commands();
248+
esp_matter::console::factoryreset_register_commands();
248249
esp_matter::console::init();
249250
#endif
250251

examples/light/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ extern "C" void app_main()
225225
#if CONFIG_ENABLE_CHIP_SHELL
226226
esp_matter::console::diagnostics_register_commands();
227227
esp_matter::console::wifi_register_commands();
228+
esp_matter::console::factoryreset_register_commands();
228229
#if CONFIG_OPENTHREAD_CLI
229230
esp_matter::console::otcli_register_commands();
230231
#endif

examples/light_switch/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ extern "C" void app_main()
159159
#if CONFIG_ENABLE_CHIP_SHELL
160160
esp_matter::console::diagnostics_register_commands();
161161
esp_matter::console::wifi_register_commands();
162+
esp_matter::console::factoryreset_register_commands();
162163
esp_matter::console::init();
163164
#endif
164165
}

examples/light_wifi_prov/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,7 @@ extern "C" void app_main()
317317
#if CONFIG_ENABLE_CHIP_SHELL
318318
esp_matter::console::diagnostics_register_commands();
319319
esp_matter::console::wifi_register_commands();
320+
esp_matter::console::factoryreset_register_commands();
320321
esp_matter::console::init();
321322
#endif
322323
}

examples/multiple_on_off_plugin_units/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,7 @@ extern "C" void app_main()
237237
#if CONFIG_ENABLE_CHIP_SHELL
238238
esp_matter::console::diagnostics_register_commands();
239239
esp_matter::console::wifi_register_commands();
240+
esp_matter::console::factoryreset_register_commands();
240241
#if CONFIG_OPENTHREAD_CLI
241242
esp_matter::console::otcli_register_commands();
242243
#endif

examples/ota_provider/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ extern "C" void app_main()
6868
#if CONFIG_ENABLE_CHIP_SHELL
6969
esp_matter::console::diagnostics_register_commands();
7070
esp_matter::console::wifi_register_commands();
71+
esp_matter::console::factoryreset_register_commands();
7172
esp_matter::console::init();
7273
#endif // CONFIG_ENABLE_CHIP_SHELL
7374
}

examples/refrigerator/main/app_main.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,10 @@ extern "C" void app_main()
113113
temperature_controlled_cabinet::config_t temperature_controlled_cabinet_config;
114114
endpoint_t *endpoint1 = temperature_controlled_cabinet::create(node, &temperature_controlled_cabinet_config, ENDPOINT_FLAG_NONE, NULL);
115115
ABORT_APP_ON_FAILURE(endpoint1 != nullptr, ESP_LOGE(TAG, "Failed to create temperature controlled cabinet endpoint"));
116-
116+
117117
esp_matter::cluster_t *cluster = esp_matter::cluster::get(endpoint1, chip::app::Clusters::TemperatureControl::Id);
118118

119-
// Atlest one of temperature_number and temperature_level feature is mandatory.
119+
// Atlest one of temperature_number and temperature_level feature is mandatory.
120120
cluster::temperature_control::feature::temperature_number::config_t temperature_number_config;
121121
cluster::temperature_control::feature::temperature_number::add(cluster, &temperature_number_config);
122122

@@ -148,6 +148,7 @@ extern "C" void app_main()
148148
#if CONFIG_ENABLE_CHIP_SHELL
149149
esp_matter::console::diagnostics_register_commands();
150150
esp_matter::console::wifi_register_commands();
151+
esp_matter::console::factoryreset_register_commands();
151152
esp_matter::console::init();
152153
#endif
153154
}

examples/room_air_conditioner/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,7 @@ extern "C" void app_main()
175175
#if CONFIG_ENABLE_CHIP_SHELL
176176
esp_matter::console::diagnostics_register_commands();
177177
esp_matter::console::wifi_register_commands();
178+
esp_matter::console::factoryreset_register_commands();
178179
esp_matter::console::init();
179180
#endif
180181
}

examples/thread_border_router/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ extern "C" void app_main()
114114
#if CONFIG_ENABLE_CHIP_SHELL
115115
esp_matter::console::diagnostics_register_commands();
116116
esp_matter::console::wifi_register_commands();
117+
esp_matter::console::factoryreset_register_commands();
117118
esp_matter::console::init();
118119
#endif // CONFIG_ENABLE_CHIP_SHELL
119120
}

examples/zap_light/main/app_main.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ extern "C" void app_main()
116116
#if CONFIG_ENABLE_CHIP_SHELL
117117
esp_matter::console::diagnostics_register_commands();
118118
esp_matter::console::wifi_register_commands();
119+
esp_matter::console::factoryreset_register_commands();
119120
esp_matter::console::init();
120121
#endif
121122
}

0 commit comments

Comments
 (0)