From fbc8e9fb7f0e6c3bc0286cceb63166834441277f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20BOU=C3=89?= Date: Thu, 8 Aug 2024 17:33:04 +0200 Subject: [PATCH] Update Matter Linux Dishwasher Example README (#34873) * Matter Linux Dishwasher Example * Update README.md Control the operational mode * Update README.md * [PATCH] Restyled by prettier-markdown * [PATCH] Restyled by prettier-markdown --- examples/dishwasher-app/linux/README.md | 40 +++++++++++++++++-------- 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/examples/dishwasher-app/linux/README.md b/examples/dishwasher-app/linux/README.md index 2d3b461386395d..6b849617099b9c 100644 --- a/examples/dishwasher-app/linux/README.md +++ b/examples/dishwasher-app/linux/README.md @@ -1,8 +1,8 @@ -# Matter Linux Lighting Example +# Matter Linux Dishwasher Example An example showing the use of Matter on the Linux. The document will describe -how to build and run Matter Linux Lighting Example on Raspberry Pi. This doc is -tested on **Ubuntu for Raspberry Pi Server 20.04 LTS (aarch64)** and **Ubuntu +how to build and run Matter Linux Dishwasher Example on Raspberry Pi. This doc +is tested on **Ubuntu for Raspberry Pi Server 20.04 LTS (aarch64)** and **Ubuntu for Raspberry Pi Desktop 20.10 (aarch64)** To cross-compile this example on x64 host and run on **NXP i.MX 8M Mini** @@ -12,7 +12,7 @@ details.
-- [Matter Linux Lighting Example](#matter-linux-lighting-example) +- [Matter Linux Dishwasher Example](#matter-linux-dishwasher-example) - [Building](#building) - [Commandline Arguments](#commandline-arguments) - [Running the Complete Example on Raspberry Pi 4](#running-the-complete-example-on-raspberry-pi-4) @@ -29,7 +29,7 @@ details. - Build the example application: - $ cd ~/connectedhomeip/examples/lighting-app/linux + $ cd ~/connectedhomeip/examples/dishwasher-app/linux $ git submodule update --init $ source third_party/connectedhomeip/scripts/activate.sh $ gn gen out/debug @@ -37,12 +37,12 @@ details. - To delete generated executable, libraries and object files use: - $ cd ~/connectedhomeip/examples/lighting-app/linux + $ cd ~/connectedhomeip/examples/dishwasher-app/linux $ rm -rf out/ - Build the example with pigweed RPC - $ cd ~/connectedhomeip/examples/lighting-app/linux + $ cd ~/connectedhomeip/examples/dishwasher-app/linux $ git submodule update --init $ source third_party/connectedhomeip/scripts/activate.sh $ gn gen out/debug --args='import("//with_pw_rpc.gni")' @@ -107,16 +107,30 @@ details. RX bytes:8609495 acl:14 sco:0 events:217484 errors:0 TX bytes:92185 acl:20 sco:0 commands:5259 errors:0 - - Run Linux Lighting Example App + - Run Linux Dishwasher Example App - $ cd ~/connectedhomeip/examples/lighting-app/linux - $ sudo out/debug/chip-lighting-app --ble-device [bluetooth device number] + $ cd ~/connectedhomeip/examples/dishwasher-app/linux + $ sudo out/debug/chip-dishwasher-app --ble-device [bluetooth device number] # In this example, the device we want to use is hci1 - $ sudo out/debug/chip-lighting-app --ble-device 1 + $ sudo out/debug/chip-dishwasher-app --ble-device 1 - Test the device using ChipDeviceController on your laptop / workstation etc. +## Control + +Control the operational mode: + +``` + $ chip-tool operationalstate start + $ chip-tool operationalstate stop + $ chip-tool operationalstate pause + + $ chip-tool operationalstate start 1 1 + $ chip-tool operationalstate stop 1 1 + $ chip-tool operationalstate pause 1 1 +``` + ## Running RPC Console - As part of building the example with RPCs enabled the chip_rpc python @@ -129,9 +143,9 @@ details. `chip-console -s localhost:33000 -o //pw_log.out` - Then you can Get and Set the light using the RPCs: - `rpcs.chip.rpc.Lighting.Get()` + `rpcs.chip.rpc.Dishwasher.Get()` - `rpcs.chip.rpc.Lighting.Set(on=True, level=128, color=protos.chip.rpc.LightingColor(hue=5, saturation=5))` + `rpcs.chip.rpc.Dishwasher.Set(on=True, level=128, color=protos.chip.rpc.DishwasherColor(hue=5, saturation=5))` ## Device Tracing