# Arduino IoT Cloud

# Development

My First Experience with Arduino IoT Cloud

Published on January 25, 2021

My First Experience with Arduino IoT Cloud

 

The story started on the online learning site, Udemy, where I came across the course “Building Internet of Things Projects with Arduino IoT Cloud”. A simple Google search confirmed that the open-source hardware and software platform, Arduino, had officially released the Arduino IoT Cloud. It came as a surprise as prior to this, I had only been aware of their set of boards and software, Arduino Integrated Development Environment (IDE). I decided to investigate further!

First of all, you need to register the device; in my case, it was an MKR GSM 1400 board.

The second step involves creating the first ‘thing’. My model was quite simple: a LED which can be controlled over the board.

According to the IoT Cloud philosophy, my Thing LED_GREEN only has one Property – a logical (ON/OFF) variable ledState. As Property permission was R & W (Read and Write), it means the state of the variable can be controlled from the cloud.

The next step was to update the auto-generated code. Here, I needed to define the pin used to control the LED, which was pin #2 in my case.

Next, I set up the pin mode as OUTPUT and expanded the onLedStateChange() function.

This created the Dashboard DemoLED which was bound to the Thing, LED_GREEN and property ledState. Below is a view of the Dashboard:

Then, it was time to return to the physical world and complete my very first Internet Thing!

I connected the MKR GSM1400 to the computer via USB cable and to the breadboard, which contains a LED and a resistor. During this stage, I also connected the GSM antenna and LiPo accumulator.

Despite inserting the SIM into the MKR board, the Sysmocom replacement FPC cable was used together with the SIMtrace2 Hardware Kit. The APDU traces were analyzed by Wireshark software.

As soon as GSM registration was successful, it was time to download the code from the Web Editor and then disconnect the USB cable to enjoy the Thing-to-Cloud interface.

The LiPo accumulator supplied the power while the board was disconnected from USB.

The last step: open the Dashboard and switch the LED on.

It actually works! The Thing is successfully controlled from the cloud and the project contains no more than ten lines of hand-written code.

© 2022 Pod Group. All right reserved.