Skip to content

Commit f397e91

Browse files
authored
feat(matter): adds basic documentation to the example
1 parent 78a11e5 commit f397e91

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

libraries/Matter/examples/MatterLambdaSingleCallbackManyEPs/MatterLambdaSingleCallbackManyEPs.ino

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,21 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15+
/*
16+
This example create 6 on-off light endpoint that share the same onChangeOnOff() callback code.
17+
It uses Lambda Function with an extra Lambda Capture information that links the Endpoint to its individual information.
18+
After the Matter example is commissioned, the expected Serial output shall be similar to this:
19+
20+
Matter App Control: 'Room 1' (OnOffLight[0], Endpoint 1, GPIO 2) changed to: OFF
21+
Matter App Control: 'Room 1' (OnOffLight[0], Endpoint 1, GPIO 2) changed to: ON
22+
Matter App Control: 'Room 5' (OnOffLight[4], Endpoint 5, GPIO 10) changed to: ON
23+
Matter App Control: 'Room 2' (OnOffLight[1], Endpoint 2, GPIO 4) changed to: ON
24+
Matter App Control: 'Room 4' (OnOffLight[3], Endpoint 4, GPIO 8) changed to: ON
25+
Matter App Control: 'Room 6' (OnOffLight[5], Endpoint 6, GPIO 12) changed to: ON
26+
Matter App Control: 'Room 3' (OnOffLight[2], Endpoint 3, GPIO 6) changed to: ON
27+
Matter App Control: 'Room 5' (OnOffLight[4], Endpoint 5, GPIO 10) changed to: OFF
28+
*/
29+
1530
// Matter Manager
1631
#include <Matter.h>
1732
#include <WiFi.h>

0 commit comments

Comments
 (0)