From 513606731632ba9f2b979577434d412eeed8910b Mon Sep 17 00:00:00 2001 From: Nivi Sarkar <55898241+nivi-apple@users.noreply.github.com> Date: Tue, 25 Jan 2022 20:34:31 -0800 Subject: [PATCH] Add support for contact sensor (#13735) --- examples/all-clusters-app/esp32/main/main.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/examples/all-clusters-app/esp32/main/main.cpp b/examples/all-clusters-app/esp32/main/main.cpp index b203a25fee4fa4..ef742c53da078c 100644 --- a/examples/all-clusters-app/esp32/main/main.cpp +++ b/examples/all-clusters-app/esp32/main/main.cpp @@ -517,6 +517,12 @@ void SetupPretendDevices() AddCluster("Occupancy Sensor"); AddAttribute("Occupancy", "1"); app::Clusters::OccupancySensing::Attributes::Occupancy::Set(1, 1); + + AddDevice("Contact Sensor"); + AddEndpoint("External"); + AddCluster("Contact Sensor"); + AddAttribute("BooleanState", "true"); + app::Clusters::BooleanState::Attributes::StateValue::Set(1, true); } WiFiWidget pairingWindowLED;