Skip to content

Commit bf55924

Browse files
authored
Merge branch 'master' into release/v3.3.x
2 parents 05fbda2 + 01e4d5d commit bf55924

File tree

9 files changed

+484
-67
lines changed

9 files changed

+484
-67
lines changed

cores/esp32/esp32-hal-uart.c

Lines changed: 11 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,11 @@
3232
#include "driver/gpio.h"
3333
#include "hal/gpio_hal.h"
3434
#include "esp_rom_gpio.h"
35+
#include "esp_private/gpio.h"
3536

3637
#include "driver/rtc_io.h"
3738
#include "driver/lp_io.h"
38-
#include "soc/uart_periph.h"
39+
#include "soc/uart_pins.h"
3940
#include "esp_private/uart_share_hw_ctrl.h"
4041

4142
static int s_uart_debug_nr = 0; // UART number for debug output
@@ -1399,39 +1400,9 @@ unsigned long uartDetectBaudrate(uart_t *uart) {
13991400
}
14001401

14011402
/*
1402-
These functions are for testing purpose only and can be used in Arduino Sketches
1403-
Those are used in the UART examples
1404-
*/
1405-
1406-
/*
1407-
This is intended to make an internal loopback connection using IOMUX
1408-
The function uart_internal_loopback() shall be used right after Arduino Serial.begin(...)
1409-
This code "replaces" the physical wiring for connecting TX <--> RX in a loopback
1410-
*/
1411-
1412-
// gets the right TX or RX SIGNAL, based on the UART number from gpio_sig_map.h
1413-
#ifdef CONFIG_IDF_TARGET_ESP32P4
1414-
#define UART_TX_SIGNAL(uartNumber) \
1415-
(uartNumber == UART_NUM_0 \
1416-
? UART0_TXD_PAD_OUT_IDX \
1417-
: (uartNumber == UART_NUM_1 \
1418-
? UART1_TXD_PAD_OUT_IDX \
1419-
: (uartNumber == UART_NUM_2 ? UART2_TXD_PAD_OUT_IDX : (uartNumber == UART_NUM_3 ? UART3_TXD_PAD_OUT_IDX : UART4_TXD_PAD_OUT_IDX))))
1420-
#define UART_RX_SIGNAL(uartNumber) \
1421-
(uartNumber == UART_NUM_0 \
1422-
? UART0_RXD_PAD_IN_IDX \
1423-
: (uartNumber == UART_NUM_1 \
1424-
? UART1_RXD_PAD_IN_IDX \
1425-
: (uartNumber == UART_NUM_2 ? UART2_RXD_PAD_IN_IDX : (uartNumber == UART_NUM_3 ? UART3_RXD_PAD_IN_IDX : UART4_RXD_PAD_IN_IDX))))
1426-
#else
1427-
#if SOC_UART_HP_NUM > 2
1428-
#define UART_TX_SIGNAL(uartNumber) (uartNumber == UART_NUM_0 ? U0TXD_OUT_IDX : (uartNumber == UART_NUM_1 ? U1TXD_OUT_IDX : U2TXD_OUT_IDX))
1429-
#define UART_RX_SIGNAL(uartNumber) (uartNumber == UART_NUM_0 ? U0RXD_IN_IDX : (uartNumber == UART_NUM_1 ? U1RXD_IN_IDX : U2RXD_IN_IDX))
1430-
#else
1431-
#define UART_TX_SIGNAL(uartNumber) (uartNumber == UART_NUM_0 ? U0TXD_OUT_IDX : U1TXD_OUT_IDX)
1432-
#define UART_RX_SIGNAL(uartNumber) (uartNumber == UART_NUM_0 ? U0RXD_IN_IDX : U1RXD_IN_IDX)
1433-
#endif
1434-
#endif // ifdef CONFIG_IDF_TARGET_ESP32P4
1403+
* These functions are for testing purposes only and can be used in Arduino Sketches.
1404+
* They are utilized in the UART examples and CI.
1405+
*/
14351406

14361407
/*
14371408
This function internally binds defined UARTs TX signal with defined RX pin of any UART (same or different).
@@ -1443,7 +1414,12 @@ void uart_internal_loopback(uint8_t uartNum, int8_t rxPin) {
14431414
log_e("UART%d is not supported for loopback or RX pin %d is invalid.", uartNum, rxPin);
14441415
return;
14451416
}
1446-
esp_rom_gpio_connect_out_signal(rxPin, UART_TX_SIGNAL(uartNum), false, false);
1417+
// forces rxPin to use GPIO Matrix and setup the pin to receive UART TX Signal - IDF 5.4.1 Change with uart_release_pin()
1418+
gpio_func_sel((gpio_num_t)rxPin, PIN_FUNC_GPIO);
1419+
gpio_pullup_en((gpio_num_t)rxPin);
1420+
gpio_input_enable((gpio_num_t)rxPin);
1421+
esp_rom_gpio_connect_in_signal(rxPin, uart_periph_signal[uartNum].pins[SOC_UART_RX_PIN_IDX].signal, false);
1422+
esp_rom_gpio_connect_out_signal(rxPin, uart_periph_signal[uartNum].pins[SOC_UART_TX_PIN_IDX].signal, false, false);
14471423
}
14481424

14491425
/*

libraries/DNSServer/src/DNSServer.cpp

Lines changed: 82 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,16 +111,22 @@ void DNSServer::_handleUDP(AsyncUDPPacket &pkt) {
111111
// will reply with IP only to "*" or if domain matches without www. subdomain
112112
if (dnsHeader.OPCode == DNS_OPCODE_QUERY && requestIncludesOnlyOneQuestion(dnsHeader)
113113
&& (_domainName.isEmpty() || getDomainNameWithoutWwwPrefix(static_cast<const unsigned char *>(dnsQuestion.QName), dnsQuestion.QNameLength) == _domainName)) {
114-
replyWithIP(pkt, dnsHeader, dnsQuestion);
114+
115+
// Qtype = A (1) or ANY (255): send an A record otherwise an empty response
116+
if (ntohs(dnsQuestion.QType) == 1 || ntohs(dnsQuestion.QType) == 255) {
117+
replyWithIP(pkt, dnsHeader, dnsQuestion);
118+
} else {
119+
replyWithNoAnsw(pkt, dnsHeader, dnsQuestion);
120+
}
115121
return;
116122
}
117-
118123
// otherwise reply with custom code
119124
replyWithCustomCode(pkt, dnsHeader);
120125
}
121126

122127
bool DNSServer::requestIncludesOnlyOneQuestion(DNSHeader &dnsHeader) {
123-
return ntohs(dnsHeader.QDCount) == 1 && dnsHeader.ANCount == 0 && dnsHeader.NSCount == 0 && dnsHeader.ARCount == 0;
128+
dnsHeader.ARCount = 0; // We assume that if ARCount !=0 there is a EDNS OPT packet, just ignore
129+
return ntohs(dnsHeader.QDCount) == 1 && dnsHeader.ANCount == 0 && dnsHeader.NSCount == 0;
124130
}
125131

126132
String DNSServer::getDomainNameWithoutWwwPrefix(const unsigned char *start, size_t len) {
@@ -139,7 +145,6 @@ String DNSServer::getDomainNameWithoutWwwPrefix(const unsigned char *start, size
139145

140146
void DNSServer::replyWithIP(AsyncUDPPacket &req, DNSHeader &dnsHeader, DNSQuestion &dnsQuestion) {
141147
AsyncUDPMessage rpl;
142-
143148
// Change the type of message to a response and set the number of answers equal to
144149
// the number of questions in the header
145150
dnsHeader.QR = DNS_QR_RESPONSE;
@@ -187,3 +192,76 @@ void DNSServer::replyWithCustomCode(AsyncUDPPacket &req, DNSHeader &dnsHeader) {
187192
rpl.write(reinterpret_cast<const uint8_t *>(&dnsHeader), sizeof(DNSHeader));
188193
_udp.sendTo(rpl, req.remoteIP(), req.remotePort());
189194
}
195+
196+
void DNSServer::replyWithNoAnsw(AsyncUDPPacket &req, DNSHeader &dnsHeader, DNSQuestion &dnsQuestion) {
197+
198+
dnsHeader.QR = DNS_QR_RESPONSE;
199+
dnsHeader.ANCount = 0;
200+
dnsHeader.NSCount = htons(1);
201+
202+
AsyncUDPMessage rpl;
203+
rpl.write(reinterpret_cast<const uint8_t *>(&dnsHeader), sizeof(DNSHeader));
204+
205+
// Write the question
206+
rpl.write(dnsQuestion.QName, dnsQuestion.QNameLength);
207+
rpl.write((uint8_t *)&dnsQuestion.QType, 2);
208+
rpl.write((uint8_t *)&dnsQuestion.QClass, 2);
209+
210+
// An empty answer contains an authority section with a SOA,
211+
// We take the name of the query as the root of the zone for which the SOA is generated
212+
// and use a value of DNS_MINIMAL_TTL seconds in order to minimize negative caching
213+
// Write the authority section:
214+
// The SOA RR's ownername is set equal to the query name, and we use made up names for
215+
// the MNAME and RNAME - it doesn't really matter from a protocol perspective - as for
216+
// a no such QTYPE answer only the timing fields are used.
217+
// a protocol perspective - it
218+
// Use DNS name compression : instead of repeating the name in this RNAME occurrence,
219+
// set the two MSB of the byte corresponding normally to the length to 1. The following
220+
// 14 bits must be used to specify the offset of the domain name in the message
221+
// (<255 here so the first byte has the 6 LSB at 0)
222+
rpl.write((uint8_t)0xC0);
223+
rpl.write((uint8_t)DNS_OFFSET_DOMAIN_NAME);
224+
225+
// DNS type A : host address, DNS class IN for INternet, returning an IPv4 address
226+
uint16_t answerType = htons(DNS_TYPE_SOA), answerClass = htons(DNS_CLASS_IN);
227+
uint32_t Serial = htonl(DNS_SOA_SERIAL); // Date type serial based on the date this piece of code was written
228+
uint32_t Refresh = htonl(DNS_SOA_REFRESH); // These timers don't matter, we don't serve zone transfers
229+
uint32_t Retry = htonl(DNS_SOA_RETRY);
230+
uint32_t Expire = htonl(DNS_SOA_EXPIRE);
231+
uint32_t MinTTL = htonl(DNS_MINIMAL_TTL); // See RFC2308 section 5
232+
char MLabel[] = DNS_SOA_MNAME_LABEL;
233+
char RLabel[] = DNS_SOA_RNAME_LABEL;
234+
char PostFixLabel[] = DNS_SOA_POSTFIX_LABEL;
235+
236+
// 4 accounts for len fields and for both rname
237+
// and lname and their postfix labels and there are 5 32 bit fields
238+
239+
uint16_t RdataLength = htons((uint16_t)(strlen(MLabel) + strlen(RLabel) + 2 * strlen(PostFixLabel) + 4 + 5 * sizeof(Serial)));
240+
241+
rpl.write((unsigned char *)&answerType, 2);
242+
rpl.write((unsigned char *)&answerClass, 2);
243+
rpl.write((unsigned char *)&MinTTL, 4); // DNS Time To Live
244+
245+
rpl.write((unsigned char *)&RdataLength, 2);
246+
247+
rpl.write((uint8_t)strlen(MLabel));
248+
rpl.write((unsigned char *)&MLabel, strlen(MLabel));
249+
250+
rpl.write((unsigned char *)&PostFixLabel, strlen(PostFixLabel));
251+
rpl.write((uint8_t)0);
252+
// rpl.write((uint8_t)0xC0);
253+
// rpl.write((uint8_t)DNS_OFFSET_DOMAIN_NAME);
254+
255+
rpl.write((uint8_t)strlen(RLabel));
256+
rpl.write((unsigned char *)&RLabel, strlen(RLabel));
257+
rpl.write((unsigned char *)&PostFixLabel, strlen(PostFixLabel));
258+
rpl.write((uint8_t)0);
259+
260+
rpl.write((unsigned char *)&Serial, 4);
261+
rpl.write((unsigned char *)&Refresh, 4);
262+
rpl.write((unsigned char *)&Retry, 4);
263+
rpl.write((unsigned char *)&Expire, 4);
264+
rpl.write((unsigned char *)&MinTTL, 4);
265+
266+
_udp.sendTo(rpl, req.remoteIP(), req.remotePort());
267+
}

libraries/DNSServer/src/DNSServer.h

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,26 @@
99
#define DNS_OFFSET_DOMAIN_NAME DNS_HEADER_SIZE // Offset in bytes to reach the domain name labels in the DNS message
1010
#define DNS_DEFAULT_PORT 53
1111

12+
#define DNS_SOA_MNAME_LABEL "ns"
13+
#define DNS_SOA_RNAME_LABEL "esp32"
14+
// The POSTFIX_LABEL will be concatenated to the RName and MName Label label
15+
// do not use a multilabel name here. "local" is a good choice as it is reserved for
16+
// local use by IANA
17+
// The postfix label is defined as an array of characters that follows the
18+
// definition of RFC1035 3.1
19+
// for instance, a postfix of example.com would be defined as:
20+
// #define DNS_SOA_POSTFIX_LABEL {'\7', 'e', 'x', 'a', 'm', 'p', 'l', 'e', '\3', 'c', 'o', 'm', '\0'}
21+
#define DNS_SOA_POSTFIX_LABEL \
22+
{ '\5', 'l', 'o', 'c', 'a', 'l', '\0' }
23+
// From the following values only the MINIMAL_TTL has relevance
24+
// in the context of client-server protocol interactions.
25+
// The other values are arbitrary chosen as they are only relevant for
26+
// in a zone-transfer scenario.
27+
#define DNS_SOA_SERIAL 2025052900 // Arbitrary serial (format: YYYYMMDDnn)
28+
#define DNS_SOA_REFRESH 100000 // Arbitrary (seconds)
29+
#define DNS_SOA_RETRY 10000 // Arbitrary (seconds)
30+
#define DNS_SOA_EXPIRE 1000000 // Arbitrary (seconds)
31+
#define DNS_MINIMAL_TTL 5 // Time to live for negative answers RFC2308
1232
enum class DNSReplyCode : uint16_t {
1333
NoError = 0,
1434
FormError = 1,
@@ -179,5 +199,7 @@ class DNSServer {
179199
inline bool requestIncludesOnlyOneQuestion(DNSHeader &dnsHeader);
180200
void replyWithIP(AsyncUDPPacket &req, DNSHeader &dnsHeader, DNSQuestion &dnsQuestion);
181201
inline void replyWithCustomCode(AsyncUDPPacket &req, DNSHeader &dnsHeader);
202+
inline void replyWithNoAnsw(AsyncUDPPacket &req, DNSHeader &dnsHeader, DNSQuestion &dnsQuestion);
203+
182204
void _handleUDP(AsyncUDPPacket &pkt);
183205
};
Lines changed: 168 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,168 @@
1+
// Copyright 2025 Espressif Systems (Shanghai) PTE LTD
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
// Matter Manager
16+
#include <Matter.h>
17+
#include <WiFi.h>
18+
19+
// WiFi is manually set and started
20+
const char *ssid = "your-ssid"; // Change this to your WiFi SSID
21+
const char *password = "your-password"; // Change this to your WiFi password
22+
23+
// List of Matter Endpoints for this Node
24+
// On/Off Light Endpoint
25+
MatterOnOffLight OnOffLight;
26+
27+
// This function is called when a Matter event occurs
28+
void onMatterEvent(matterEvent_t eventType, const chip::DeviceLayer::ChipDeviceEvent *eventInfo) {
29+
// Print the event type to Serial
30+
Serial.print("===> Got a Matter Event: ");
31+
switch (eventType) {
32+
case MATTER_WIFI_CONNECTIVITY_CHANGE: Serial.println("WiFi Connectivity Change"); break;
33+
case MATTER_THREAD_CONNECTIVITY_CHANGE: Serial.println("Thread Connectivity Change"); break;
34+
case MATTER_INTERNET_CONNECTIVITY_CHANGE:
35+
{
36+
bool newIPAddress = false;
37+
Serial.print("Internet Connectivity Change :: ");
38+
if (eventInfo->InternetConnectivityChange.IPv4 != chip::DeviceLayer::ConnectivityChange::kConnectivity_NoChange) {
39+
Serial.print("IPv4 Connectivity: ");
40+
switch (eventInfo->InternetConnectivityChange.IPv4) {
41+
case chip::DeviceLayer::ConnectivityChange::kConnectivity_Established:
42+
{
43+
newIPAddress = true;
44+
break;
45+
}
46+
case chip::DeviceLayer::ConnectivityChange::kConnectivity_Lost: Serial.println("Lost"); break;
47+
default: Serial.println("Unknown"); break;
48+
}
49+
}
50+
if (eventInfo->InternetConnectivityChange.IPv6 != chip::DeviceLayer::ConnectivityChange::kConnectivity_NoChange) {
51+
Serial.print("IPv6 Connectivity: ");
52+
switch (eventInfo->InternetConnectivityChange.IPv6) {
53+
case chip::DeviceLayer::ConnectivityChange::kConnectivity_Established:
54+
{
55+
newIPAddress = true;
56+
break;
57+
}
58+
case chip::DeviceLayer::ConnectivityChange::kConnectivity_Lost: Serial.println("Lost"); break;
59+
default: Serial.println("Unknown"); break;
60+
}
61+
}
62+
// Print the IP address if it was established
63+
if (newIPAddress) {
64+
Serial.print("Established - IP Address: ");
65+
char ipAddressStr[chip::Transport::PeerAddress::kMaxToStringSize];
66+
eventInfo->InternetConnectivityChange.ipAddress.ToString(ipAddressStr);
67+
Serial.println(ipAddressStr);
68+
}
69+
break;
70+
}
71+
case MATTER_SERVICE_CONNECTIVITY_CHANGE: Serial.println("Service Connectivity Change"); break;
72+
case MATTER_SERVICE_PROVISIONING_CHANGE: Serial.println("Service Provisioning Change"); break;
73+
case MATTER_TIME_SYNC_CHANGE: Serial.println("Time Sync Change"); break;
74+
case MATTER_CHIPOBLE_CONNECTION_ESTABLISHED: Serial.println("CHIPoBLE Connection Established"); break;
75+
case MATTER_CHIPOBLE_CONNECTION_CLOSED: Serial.println("CHIPoBLE Connection Closed"); break;
76+
case MATTER_CLOSE_ALL_BLE_CONNECTIONS: Serial.println("Close All BLE Connections"); break;
77+
case MATTER_WIFI_DEVICE_AVAILABLE: Serial.println("WiFi Device Available"); break;
78+
case MATTER_OPERATIONAL_NETWORK_STARTED: Serial.println("Operational Network Started"); break;
79+
case MATTER_THREAD_STATE_CHANGE: Serial.println("Thread State Change"); break;
80+
case MATTER_THREAD_INTERFACE_STATE_CHANGE: Serial.println("Thread Interface State Change"); break;
81+
case MATTER_CHIPOBLE_ADVERTISING_CHANGE: Serial.println("CHIPoBLE Advertising Change"); break;
82+
case MATTER_INTERFACE_IP_ADDRESS_CHANGED:
83+
switch (eventInfo->InterfaceIpAddressChanged.Type) {
84+
case chip::DeviceLayer::InterfaceIpChangeType::kIpV4_Assigned: Serial.println("IPv4 Address Assigned"); break;
85+
case chip::DeviceLayer::InterfaceIpChangeType::kIpV4_Lost: Serial.println("IPv4 Address Lost"); break;
86+
case chip::DeviceLayer::InterfaceIpChangeType::kIpV6_Assigned: Serial.println("IPv6 Address Assigned"); break;
87+
case chip::DeviceLayer::InterfaceIpChangeType::kIpV6_Lost: Serial.println("IPv6 Address Lost"); break;
88+
}
89+
break;
90+
case MATTER_COMMISSIONING_COMPLETE: Serial.println("Commissioning Complete"); break;
91+
case MATTER_FAIL_SAFE_TIMER_EXPIRED: Serial.println("Fail Safe Timer Expired"); break;
92+
case MATTER_OPERATIONAL_NETWORK_ENABLED: Serial.println("Operational Network Enabled"); break;
93+
case MATTER_DNSSD_INITIALIZED: Serial.println("DNS-SD Initialized"); break;
94+
case MATTER_DNSSD_RESTART_NEEDED: Serial.println("DNS-SD Restart Needed"); break;
95+
case MATTER_BINDINGS_CHANGED_VIA_CLUSTER: Serial.println("Bindings Changed Via Cluster"); break;
96+
case MATTER_OTA_STATE_CHANGED: Serial.println("OTA State Changed"); break;
97+
case MATTER_SERVER_READY: Serial.println("Server Ready"); break;
98+
case MATTER_BLE_DEINITIALIZED: Serial.println("BLE Deinitialized"); break;
99+
case MATTER_COMMISSIONING_SESSION_STARTED: Serial.println("Commissioning Session Started"); break;
100+
case MATTER_COMMISSIONING_SESSION_STOPPED: Serial.println("Commissioning Session Stopped"); break;
101+
case MATTER_COMMISSIONING_WINDOW_OPEN: Serial.println("Commissioning Window Opened"); break;
102+
case MATTER_COMMISSIONING_WINDOW_CLOSED: Serial.println("Commissioning Window Closed"); break;
103+
case MATTER_FABRIC_WILL_BE_REMOVED: Serial.println("Fabric Will Be Removed"); break;
104+
case MATTER_FABRIC_REMOVED: Serial.println("Fabric Removed"); break;
105+
case MATTER_FABRIC_COMMITTED: Serial.println("Fabric Committed"); break;
106+
case MATTER_FABRIC_UPDATED: Serial.println("Fabric Updated"); break;
107+
case MATTER_ESP32_SPECIFIC_EVENT: Serial.println("Sending ESP32 Platform Specific Events"); break;
108+
case MATTER_ESP32_PUBLIC_SPECIFIC_EVENT: Serial.println("Next Event Has Populated EventInfo"); break;
109+
default:
110+
// If the event type is not recognized, print "Unknown" and the event ID
111+
Serial.println("Unknown, EventID = 0x" + String(eventType, HEX));
112+
break;
113+
}
114+
}
115+
116+
void setup() {
117+
Serial.begin(115200);
118+
while (!Serial) {
119+
delay(10); // Wait for Serial to initialize
120+
}
121+
122+
// We start by connecting to a WiFi network
123+
Serial.print("Connecting to ");
124+
Serial.println(ssid);
125+
// Manually connect to WiFi
126+
WiFi.enableIPv6(true); // Enable IPv6 if needed
127+
WiFi.begin(ssid, password);
128+
// Wait for connection
129+
while (WiFi.status() != WL_CONNECTED) {
130+
delay(500);
131+
Serial.print(".");
132+
}
133+
Serial.println("\r\nWiFi connected");
134+
Serial.println("IP address: ");
135+
Serial.println(WiFi.localIP());
136+
delay(500);
137+
138+
// Initialize at least one Matter EndPoint
139+
OnOffLight.begin();
140+
141+
// Set the Matter Event Callback
142+
Matter.onEvent(onMatterEvent);
143+
// Matter beginning - Last step, after all EndPoints are initialized
144+
Matter.begin();
145+
Serial.println("Starting Matter Commission Test...");
146+
}
147+
148+
void loop() {
149+
// Check Matter Commissioning state
150+
if (!Matter.isDeviceCommissioned()) {
151+
Serial.println("");
152+
Serial.println("Matter Node is not commissioned yet.");
153+
Serial.println("Initiate the device discovery in your Matter environment.");
154+
Serial.println("Commission it to your Matter hub with the manual pairing code or QR code");
155+
Serial.printf("Manual pairing code: %s\r\n", Matter.getManualPairingCode().c_str());
156+
Serial.printf("QR code URL: %s\r\n", Matter.getOnboardingQRCodeUrl().c_str());
157+
// waits for Matter Light Commissioning.
158+
while (!Matter.isDeviceCommissioned()) {
159+
delay(5000);
160+
Serial.println("Matter Fabric not commissioned yet. Waiting for commissioning.");
161+
}
162+
}
163+
Serial.println("Matter Node is commissioned and connected to Wi-Fi.");
164+
Serial.println("====> Decommissioning in 60 seconds. <====");
165+
delay(60000);
166+
Matter.decommission();
167+
Serial.println("Matter Node is decommissioned. Commissioning widget shall start over.");
168+
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"fqbn_append": "PartitionScheme=huge_app",
3+
"requires": [
4+
"CONFIG_SOC_WIFI_SUPPORTED=y",
5+
"CONFIG_ESP_MATTER_ENABLE_DATA_MODEL=y"
6+
]
7+
}

0 commit comments

Comments
 (0)