Chip Tool is a Matter controller being developed as part of the Connected Home IP project.
The snap packaging makes it easy to run the Chip Tool on Linux distributions.
This snap has been tested on amd64/arm64 architectures for WiFi/Ethernet/DNS-SD/BLE/Thread commissioning and control.
sudo snap install chip-tool
Connect the avahi-observe
interface to allow DNS-SD based discovery:
sudo snap connect chip-tool:avahi-observe
Connect the bluez
interface for device discovery over Bluetooth Low Energy (BLE):
sudo snap connect chip-tool:bluez
Connect the process-control
interface for system-wide process management. This is needed to grant Chip Tool access to make sched_setattr system calls. This may improve the reliability of the operations (see canonical#8).
sudo snap connect chip-tool:process-control
Note
On Ubuntu Core, theavahi-observe
andbluez
interfaces are not provided by the system.These interfaces are provided by other snaps, such as the Avahi and BlueZ snaps. To install the snaps and connect to the interfaces, run:
sudo snap install avahi bluez sudo snap connect chip-tool:avahi-observe avahi:avahi-observe sudo snap connect chip-tool:bluez bluez:service
Discover using DNS-SD and pair:
sudo chip-tool pairing onnetwork 110 20202021
where:
110
is the node id being assigned to the app20202021
is the pin code set on the app
This depends on an OpenThread Border Router (OTBR) with an active network. For guidance on setting that up using the OTBR snap, refer to this tutorial.
Use the OpenThread CLI to obtain Thread network credential:
$ sudo ot-ctl dataset active -x
0e08...f7f8
Done
Discover and pair:
sudo chip-tool pairing ble-thread 110 hex:0e08...f7f8 20202021 3840
where:
110
is the node id being assigned to the app0e08...f7f8
is the Thread network credential operational dataset, truncated for readability.20202021
is the pin code set on the app3840
is the discriminator id
Toggle:
sudo chip-tool onoff toggle 110 1
where:
onoff
is the matter cluster nameon
/off
/toggle
is the command name.110
is the node id of the app assigned during the commissioning1
is the endpoint of the configured device
Build locally for the architecture same as the host:
snapcraft -v
Build remotely for all supported architectures:
snapcraft remote-build
Refer to tests.