Tomas Amberg has built a Web-enabled, Arduino-based IoT Gauge with a REST API, and connect it to the IFTTT mash-up platform, via the Yaler.net relay service. In simple language, it is somewhat like the weasley clock of harry potter, which can show the current location of the owner. Since the designing and coding of IoT gauge is generic, it is also used to display subjects like weather events. Further, its connection with the Maker Channel of IFTTT which supports custom Web hooks, to integrate DIY IoT projects is the best part of this project.
This project focusses on the working of Arduino and servo (generic) as hardware and IFTTT maker channel as software. Moreover, for the uno, you need to download Arduino uno code and Yaler Arduino library.
You can begin with downloading of IoT gauge design files. After downloading, laser cut the design from a 4 mm plywood and add location, name, whatever you want to the design. Once done with laser cutting, its turn to assemble the IoT gauge. For the uno, add Ethernet shield to Arduino and then screw the base plate of Arduino for its orientation. Now align big face plate to the servo and then the small face plate with the base plate. To attach the servo to pin 9, 5V and GND of the Arduino, attach jumpier wires. Make sure to add the clock hand too which will be calibrated later
Now upload the IoT Gauge Web service Arduino code. Well, Controlling the IoT Gauge is not tedious as it is a Web service which listens for incoming requests and set the servo position accordingly. In order to give IFTTT Cloud service access to the IoT Gauge, Arduino REST API has to be accessible and addressable from the Web. The author has used a relay service, otherwise experts can add an exception to their firewall or router.
For the Yun, Install the Arduino Uno. This is done by Installing Yaler Arduino library and Arduino Uno code. You must be sure to use a unique MAC address. Now, replace RELAY_DOMAIN with your relay domain and upload the code to your Arduino Uno
For Installing the Arduino Yun for the Uno, install YalerTunnel and enable Web access. Then download Arduino Yun code and upload the code to Arduino Yun
Yun code is different from the Uno code as Yun provides a built-in REST API. To make this API accessible from the Web, we use the YalerTunnel Linux which on other hand also supports SSL encryption. It is not supported by Uno. To be very precise, building on what’s already available, you can easily simplify your code.
Next step is to download and Install Curl command line tool on your computer. Curl is a standard HTTP client .Now, enable the Arduino Yun API and skip the Uno. To test the IoT Gauge with Curl, make sure the Arduino is powered and connected to the Internet. It is necessary to test your API with Curl. Curl is great, if you want to be assured that a client or 3rd party Webhook call to you, like the one sent from IFTTT can access your Web service API.
Connect the Arduino to the IFTTT Maker channel and then create an IFTTT Do Button for the IoT Gauge. IFTTT also provides Do apps for iOS and Android as the main function of this app is to enable you to manually trigger actions. This provides an opportunity for testing your other IFTTT recipes. But unfortunately, you have to create your own Do app recipe as unlike normal IFTTT recipes, the Do app recipes cannot be shared or made public. Once you create a new IFTTT Do button, you are done with the project.
Filed Under: Featured Contributions, Reviews
Questions related to this article?
👉Ask and discuss on Electro-Tech-Online.com and EDAboard.com forums.
Tell Us What You Think!!
You must be logged in to post a comment.