GithubHelp home page GithubHelp logo

iot-edge-hacks's Introduction

iot-edge-hacks

EnOcean Gateway additional source code for Microsoft Azure

Azure IoT Edge Tiny Hacks

Goal

The connection from the IoT device to Microsoft Azure IoT Hub was troublesome, it needs to support secure protocols such as MQTT. Even if there are Device SDK and IoT Edge as libraries for connecting IoT Hub, but samples that can be used immediately by multiple arbitrary devices are not prepared.

"iot-edge-hacks" provided here aims to send the sensor value obtained by the gateway device in secure to IoT Hub anyway. It can be used as a prototype that transfers the data of the IoT device to the IoT Hub for confirmation, and can be directly used for sending sensor data.

Architecture and Hitnts

We modified the simulated device-to-cloud sample of Azure IoT Edge V1 and send real data to IoT Hub. It uses plane text files because it uses numerically-entered files for delivery, and JSON file setting of file name. It is provided as a difference (patch) file of Simulated device-to-cloud sample.

Precondition

In the operation target environment, it is an important precondition that Azure IoT Edge V1 can already be built and working properly. It works on Ubuntu 18.04 and Raspbian 9.

How to Use

  • Building and checking operation of Simulated device-to-cloud sample

    Build a simulated device-to-cloud sample according to the procedure of README and confirm that simulation temperature values...etc. are transmitted by Device Explorer.

  • File replacement and build

    Rebuild after overwrite the following files.

    • iot-edge/modules/simulated_device/src/simulated_device.c
    • iot-edge/samples/simulated_device_cloud_upload/src/main.c
    • iot-edge/samples/simulated_device_cloud_upload/src/dpride.h
    • iot-edge/samples/simulated_device_cloud_upload/src/typedefs.h
    • iot-edge/samples/simulated_device_cloud_upload/src/EoControl.c
    • iot-edge/samples/simulated_device_cloud_upload/src/module_service_config_enabled.c
    • iot-edge/samples/simulated_device_cloud_upload/src/module_service_config_disabled.c
    • iot-edge/samples/simulated_device_cloud_upload/src/sim.json
  • File settings

    Like "Simulated device-to-cloud sample", after setting "IoTHubName", "IoTHubSuffix", "deviceId", "deviceKey", describe "filename" of the corresponding device.

  • Startup

    Start with json file specified by the same procedure as Simulated device-to-cloud sample.

  • Test

    While monitoring with Device Explorer etc., verify the operation by modifying the numerical value in the file with the editor.

License

Applied MIT license inheriting Azure IoT Edge V1.

iot-edge-hacks's People

Contributors

ahidaka avatar

Stargazers

 avatar  avatar

Watchers

 avatar  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.