In this tutorial, we are going to connect ARIES v2.0 Board to Adafruit IoT cloud platform with the help of ESP8266 NodeMCU. The built-in LED in ARIES board is controlled from the data sent from the Adafruit cloud platform.

ESP8266 NodeMCU

NodeMCU is an open-source Lua-based firmware and development board specially targeted for IoT-based Applications. It includes firmware that runs on the ESP8266 Wi-Fi SoC from Espressif Systems, and hardware that is based on the ESP-12 module.

ESP8266 is a highly integrated chip designed for the needs of a new connected world. It offers a complete and self-contained Wi-Fi networking solution allowing it to either host the application or to offload all Wi-Fi networking functions from another application processor. Its high degree of on-chip integration allows for minimal external circuitry. It is designed to occupy a minimal PCB area.

Prerequisites

Components Required

  • ARIES v2.0 Board
  • Micro USB type B to USB type A cable
  • ESP8266 NodeMCU module
  • Jumper Wires

Circuit Diagram:

NodeMCU ESP8266 WiFi ModuleARIES v2 Board
VCC3.3V
GNDGND
RXTX1
TXRX1
Connection pins for NodeMCU with ARIES v2.0

Procedure

We have to configure the Adafruit IO cloud server before uploading the program to ARIES microcontroller.

Follow the below steps for configuring Adafruit IoT cloud platform

  • SIGN UP on Adafruit from Adafruit IO if you doesn’t have an account. If you have Adafruit account use SIGN IN option and login with your credentials.
  • Click on feeds menu
  • Once the feed menu is opened, Click on New feed
  • Create a new feed by giving any feed name. Here we have used demo as the feed name. You can give any feed name and Click on Create
  • Now you can see the feed has been created as follows.
  • Now click on Dashboards menu
  • Click on New Dashboard for creating a dashboard
  • Give any Dashboard name you like. Here we have given DemoDashboard” as dashboard name and click on Create
  • Now you can see the dashboard has been created as follows.
  • Click on the Dashboard name you created, to open the dashboard.
  • Once you enter inside the dashboard you created, you can see a black page as follows. Click on the gear icon on the top right
  • This will open up a menu as shown in the below figure. Click on Create New Block
  • You can see the available blocks to display the data. Here we will be using the Toggle block to display the random data coming from the ARIES micro-controller. You can also use line chart or text display or any other blocks based on your requirements.
  • In the next step, Tick Mark the checkbox to link your feed with the dashboard and click on NEXT STEP
  • Give a block title for your selected block. Give Button On value as “1” and Button of value as “0” and click on Create Block. Remaining fields are optional in this block.
  • Now the block has been created.
  • Click on the yellow key icon to Copy the Adafruit API key (Active Key) to replace the key in the Arduino code.
  • Click on feed -> Feed info. Copy the MQTT key to replace in the URL portion in the Arduino code

Now you need to change the Credentials in Arduino program

Open and set up the Arduino IDE as described in Getting Started with ARIES v2.0.

  • After connecting ARIES v2 board to your computer, Make sure you have selected ARIES v2 Board from Tools -> Board -> VEGA Processor: ARIES Boards -> ARIES v2
  • Select Programmer as VEGA XMODEM from Tools -> Programmer -> VEGA XMODEM
  • Also select appropriate port from Tools -> Port -> COM* (ARIES v2)

Now, Open Files -> Examples -> Under Examples for ARIES v2 -> UART-> NodeMCU_GetDemo

  • Change the credentials on the code as shown in the image

Once the hotspot name, hotspot password,KEY and URL has been replaced with your’s, the procedure is completed.

Finally, Upload the code to ARIES v2 Board.

Once the hotspot name, hotspot password,KEY and URL has been replaced with your’s, the procedure is completed.

Finally, Upload the code to ARIES v2 Board.

Output

Once all the AT commands are OK, then the data can be sent from the Adafruit cloud platform. You can open the dashboard you created in Adafruit to change the real time data in Adafruit server as shown in the below images. In the example program given, we are changing the toggle led button in Adafruit server to ON and OFF. When the Toggle led button is ON, the inernal LEDs in the ARIES board will turn on, and when the Toggle LED button is OFF the internal LEDs in the ARIES board will turn OFF.

Once all the AT commands are OK, the connection will be established. Now press the LED toggle button to ON/OFF and wait for sometime to observe the internal LED change in the ARIES board.

Output from ARIES v2.0 board when LED button in Adafruit cloud is turned to ON condition

Output from ARIES v2.0 board when LED button in Adafruit cloud is turned to OFF condition

By mydhily

Leave a Reply

Your email address will not be published. Required fields are marked *