O'Reilly logo

Mastering Internet of Things by Peter Waher

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Controlling your device

In the same way, you can navigate to your activator device and press the Discover button. You should see your Output resource. As with the resources on the sensor, you can read the resource and subscribe to it by pressing the GET and Observe buttons respectively. But you can also control it. You do that by writing the value you want to send to the device in the Outgoing tab in the central portion of the browser window. Try writing 1 here, and then press the POST button. Then write 0 and press POST. You should see how the output toggles. You can also see the status code of the action in the status area, as well as the round-trip time (RTT) just below the buttons. If you're observing the resource at the same time, you'll ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required