zclip-cli

0.1.16 • Public • Published

zclip-cli

A cli interface for sending ZCL over IP messages.

This depends on zclip.js and works with zclip-rd. See zclip.js for a list of supported clusters.

Installation

npm install zclip-cli -g

Device Discovery

zcl lookup --rdIp <RDIP> --rdPort <RDPort> --cluster <cluster> --clusterSide <side> --page <int> --count <int>

Multicast Examples

zcl lookup                                       #Find all devices 
zcl lookup --cluster onOff                       #Find onOff clusters 
zcl lookup --cluster onOff --clusterSide server  #Find onOff server clusters 

Resource Directory (RD) Examples

zcl lookup --rdIp ::1 --rdPort 5689
zcl lookup --rdIp ::1 --rdPort 5689 --cluster onOff
zcl lookup --rdIp ::1 --rdPort 5689 --cluster onOff --clusterSide server 

Command Requests

zcl cmd <cluster> <command> --ip <ip> [arguments]
zcl cmd <cluster> <command> --uid <uid> --rdIp <RDIP> --rdPort <RDPort> [arguments]

Examples

zcl cmd onOff on --ip ::1
zcl cmd levelControl move --ip ::1 --moveMode 1 --rate 255
zcl cmd onOff on --uid P7BU0eh27b2f5f0IC0GLL7uHum_DtmRVe73umRQCAeY --rdIp ::1 --rdPort 5689
zcl cmd levelControl move --uid P7BU0eh27b2f5f0IC0GLL7uHum_DtmRVe73umRQCAeY --rdIp ::1  --rdPort 5689 --moveMode 1 --rate 255

Attribute Read Requests

zcl read <cluster> --ip <ip>
zcl read <cluster> --uid <uid> --rdIp <RDIP> --rdPort <RDPort>

Examples

zcl read onOff --ip ::1
zcl read onOff --uid P7BU0eh27b2f5f0IC0GLL7uHum_DtmRVe73umRQCAeY --rdIp ::1 --rdPort 5689

Bind Requests

zcl bind add <cluster> <sourceIp> <destinationIp> [options]

Add Examples

zcl bind add onOff 2001::1 2001::2
zcl bind add onOff 2001::1 --destinationUid 3fb054d1e876edbd9fe5fd080b418b2fbb87ba6fc3b664557bbdee99140201e6

Clear Examples

./bin/zcl bind clear onOff ::1

Getting Help

The cli will try to help if you omit part of a command.

$ zcl
Usage:
  zcl <command> [<args>] [options]
 
Available commands:
  cmd
  discover
  read
$ zcl cmd
Usage:
  zcl cmd <cluster> <command> --ip <ip> [args]
 
Available clusters:
  alarms
  applianceControl
  applianceEventsAndAlert
  applianceIdentification
  applianceStatistics
  ...
  onOff
$ zcl cmd onOff
 
Usage:
  zcl cmd <cluster> <command> --ip <ip> [args]
 
Available commands:
  off
  on
  toggle

...and so on.

Run the tests

npm test

Support

community.silabs.com or silabs.com/support

Readme

Keywords

none

Package Sidebar

Install

npm i zclip-cli

Weekly Downloads

0

Version

0.1.16

License

ISC

Unpacked Size

51.9 kB

Total Files

32

Last publish

Collaborators

  • silabs