A few days ago I posted a way to access ZWay information via HTTP protocol in Shell Script. But later I found that it doesn't give me the full control I wanted so I continued C++ approach. This post assumes that you installed ZWay on your Raspberry Pi. The instruction of how to install can be found from ZWave.me webpage.
- [do whatever we want]
Failed to exclusively lock device: Resource temporarily unavailable
zway_start failed: Can not open port (-20)
Probably it is because there is another process already running and using the ZWay device. By default, z-way-server starts at booting time. You can manually stop it as the screenshot shows. To permanently disable the service you can type in "sudo update-rc.d z-way-server disable".
This program doesn't to anything but starting the zway server and shut it down. I will show how to access data and send command later.