@@ -22,6 +22,81 @@ Or relevant sources pages, to get started head to:
22
22
23
23
## Quickstart
24
24
25
+ The fastest (less than 20min) way to build z-wave-protocol-controller from scratch
26
+ is to delegate all tasks to docker.
27
+
28
+ This one-liner will do download latest release, setup environment, build, test, package...:
29
+
30
+ ``` sh
31
+ docker build https://github.com/SiliconLabsSoftware/z-wave-protocol-controller.git#ver_1.7.0
32
+ ```
33
+
34
+ Power users might prefer to work directly on a native GNU/Linux environment.
35
+
36
+ The project is CMake based,
37
+ to prepare the environment, have a look at [ ./helper.mk] ( helper.mk ) 's details
38
+ for needed steps to setup developer system before using CMake normally.
39
+
40
+ At the moment stable version of Debian is supported,
41
+ so it should work also in relatives projects (Ubuntu, RaspiOS, WSL2 etc)
42
+ and should be easy to adapt to other distributions.
43
+
44
+ ``` sh
45
+ ./helper.mk help
46
+ ./helper.mk setup # To setup developer system (once)
47
+ ./helper.mk VERBOSE=1 # Default build tasks verbosely (depends on setup)"
48
+ ./helper.mk run # Run entry-point application
49
+ ```
50
+
51
+ It should print zpc's help.
52
+
53
+ To use it, a Silicon Labs' Z-Wave NCP should be plugged in USB port
54
+ to verify you can check firmware version:
55
+
56
+ ``` sh
57
+ serial=$( ls /dev/serial/by-id/usb-Silicon_Labs* | head -n1)
58
+ ./helper.mk all run run_args=" --zpc.serial=${serial} --zpc.ncp_version"
59
+ # <i> [zpc_ncp_update] chip_serial_api_version: 7.23.1
60
+ ```
61
+
62
+ Then let's interact with ZPC's inbuilt shell without installing it.
63
+
64
+ ``` sh
65
+ serial=$( ls /dev/serial/by-id/usb-Silicon_Labs* | head -n1)
66
+ run_args=" --zpc.serial=${serial} "
67
+ mapdir=" applications/zpc/components/dotdot_mapper/rules"
68
+ run_args=" $run_args --mapdir=${mapdir} "
69
+ datastore_file=" tmp.db"
70
+ run_args=" $run_args --zpc.datastore_file=${datastore_file} "
71
+ cache_path=" tmp"
72
+ run_args=" $run_args --zpc.ota.cache_path=${cache_path} "
73
+
74
+ sudo apt install -y mosquitto # Is a strong runtime dependency
75
+ mkdir -p ${cache_path}
76
+ ./helper.mk run run_args=" $run_args "
77
+
78
+ ZPC> help
79
+ ==================================================
80
+ Unify Command line interface Help:
81
+ ==================================================
82
+ (...)
83
+ exit :Exit the application
84
+ (...)
85
+ zwave_home_id Print Z-Wave Home ID
86
+ (...)
87
+ zwave_add_node :Add a Z-Wave node to the network
88
+ (...)
89
+ zwave_set_default Reset Z-Wave network
90
+ (...)
91
+ ZPC> zwave_home_id
92
+ Z-Wave Home ID:
93
+ 1BADC0DE
94
+ ZPC> zwave_add_node
95
+ (...)
96
+ ```
97
+
98
+ Refer to [ ./doc] ( doc ) for more (using MQTT, WebApp etc).
99
+
25
100
26
101
## Contributing
27
102
0 commit comments