Coder Social home page Coder Social logo

tuyenth / nucleo-aws-iot-demo Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kreasl/nucleo-aws-iot-demo

0.0 2.0 0.0 7.67 MB

Java 3.75% JavaScript 1.78% CSS 0.94% HTML 1.01% C 85.98% C++ 1.59% Makefile 0.13% Shell 0.01% Arduino 0.01% Assembly 4.76% Objective-C 0.02%

nucleo-aws-iot-demo's Introduction

Nucleo Board Demo Platform

The platform demonstrates a Nucleo board with AWS IoT integration use case. The major platform components are:

  1. STM32 Nucleo-64 board with WiFi and sensors expansions. The board is a "thing" for the AWS IoT service. It updates its shadow with the sensors data every second.
  2. AWS-powered back-end receives the data, stores it in a DB and provides an API for the data retrieval.
  3. Web dashboard uses the API to fetch and visualize the data
  4. Android app is another front-end. It fetches and displays the sensors data as well.

Here is the overall platform scheme:

Nucleo Board Demo Platform Scheme

Nucleo Board

The board is registered as a "thing" in AWS IoT. It connects via MQTT broker and sends sensors data every second by updating its shadow.

Additionally the board sends a special marker message on user button press to another MQTT topic. These markers are then visualized on the charts.

Please see the board software source code for implementation, configuration details and build instructions.

Back-end

The back-end is entirely powered by Amazon Web Services. The following services are used:

  1. AWS IoT is used to communicate with the Nucleo board as well as process data coming from the device. The data is automatically processed by AWS IoT Rules Engine.
  2. AWS Lambda is the computing component of the platform. Lambdas are used to process the data by the IoT rules engine and to implement business logic for the API. There is also a "bot" implemented on Lambdas. The bot emulates the Nucleo board and can be used when the board is not available and for debugging. In addition to processing the Nucleo board data a Lambda is used to fetch weather data for a number of cities from OpenWeatherMap API.
  3. Amazon DynamoDB is a key-value storage where the data is persisted by the IoT rules engine and Lambdas.
  4. The API is powered by Amazon API Gateway.
  5. Amazon CloudWatch is used as a scheduler.
  6. Amazon Cognito is used to provide read-only public access to IoT data streams via MQTT over Websockets for the web dashboard and Android app.
  7. The web dashboard is hosted on Amazon S3.

Please see the AWS setup guide for details.

Web Dashboard

The dashboard is a demo front-end implemented as a web application. It is a React application which renders the Nucleo board sensors data as D3.js charts.

On the application start, initial data set is fetched from a public API endpoint. By default the last 4 hours of data is rendered. The chart is updated in real time using the data coming from AWS IoT via MQTT over Websocket protocol.

The charts have two visualization modes: line and area. There is also an online/offline indicator for the Nucleo board.

Please see the web dashboard source code for the implementations details, configuration and build instructions.

Android App

The Android app is another front-end. Its functionality resembles that of the web dashboard.

Please see the app source code for the implementations details, configuration and build instructions.

nucleo-aws-iot-demo's People

Contributors

mvataleu avatar evolchek avatar q11bul avatar kremonia avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.