Skip to content

Commit

Permalink
Update ip commissioning docs. (#15591)
Browse files Browse the repository at this point in the history
* Update ip commissioning docs.

Some of the early flags have now been removed, and the format
of the commands has changed. Update to reflect new commands and
compile requirements.

* Update docs/guides/ip_commissioning.md
  • Loading branch information
cecille authored and pull[bot] committed Oct 24, 2023
1 parent 70e2fee commit 2784418
Showing 1 changed file with 29 additions and 40 deletions.
69 changes: 29 additions & 40 deletions docs/guides/ip_commissioning.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,64 +5,34 @@
### ESP32 (M5 stack) - all-clusters-app

The M5 doesn’t have an ethernet port, but we can simulate IP connection by
giving the device wifi credentials. Currently, devices with wifi credentials
assume they have been provisioned, thus it is necessary to put the device back
into commissioning mode explicitly.
giving the device wifi credentials. The device will start up advertising as a
commissionable device.

Compile the device image as follows

```
Demo->Device Type = <as required>
Demo->Rendezvous Mode = “BLE / On-Network” or “On-Network”
Component config-> Chip Device Layer -> WiFi Station Options - set up ssid and password
Component config-> Chip Device Layer -> Commissioning Options -> Use full IP-based commissioning = 1
```

Demo->Rendezvous Mode = “BLE / On-Network” or “On-Network”

- this just controls the QR code flags and is only required if you wish to
connect using the QR code

Component config-> Chip Device Layer -> WiFi Station Options - set up ssid and
password

- gives the device wifi access to simulate an on-network setup

Component config-> Chip Device Layer -> Commissioning Options -> Use full
IP-based commissioning = 1

- instructs the device to wait for the commissioning complete command before
doing rendezvous cleanup and recording

Once the device is running, go to Setup -> Force wifi commissioning to put the
device into commissioning mode.

### linux builds with an ethernet connection
### linux builds

```bash
gn gen out/debug
ninja -C out/debug
```

As with the M5, This will set up the QR code with the proper flags and will
instruct the device to wait for the commissioning complete command to cleanup
and record.

These devices should start in commissioning mode naturally and requires no
manual intervention
These devices start in commissioning mode if they do not have stored Matter
credentials. Linux devices store credentials in the /tmp directory, so to
re-commission the device from scratch, remove the chip\_\* files from /tmp.

## Controller

### chip-device-ctrl

The controller builds with IP commissioning support by default, but you can turn
it on or off using

```
scripts/build_python.sh --clusters_for_ip_commissioning <true/false>
```
There are two ways to connect via IP:

There are two ways to connect via IP: **Discover then connect ip**
**Discover then connect ip**

```
discover -all
Expand All @@ -89,5 +59,24 @@ the commissioning process
connect -qr “[qr code]”
```

This will discover, connect over IP with the code from the QR and resolve. It
does, however, require that the QR code flags are set properly.
This will discover, connect over IP with the code from the QR and resolve.

### chip-tool

You can connect using chip-tool either using the setup codes or by discovering
the device on the network using one of the mDNS sub types. To get a list of the
available options run

```
chip-tool pairing
```

For example, to discover, connect and commission using the long discriminator

```
chip-tool pairing onnetwork-long <nodeid> <setuppincode> <long-discriminator>
```

where the node id is set to a value of your choice (used to id devices for
future communication), and the setup pin code and long discriminator are set by
the device and are normally logged at startup.

0 comments on commit 2784418

Please sign in to comment.