Code Monkey home page Code Monkey logo

studioiniserialbroker's Introduction

Studio Ini Serial Broker

Broker serial communication between IMU BNO055 and PLC.

                          
                                                       XXXXX
                                                       XXXX XX   XX XXXXX
                                                    XXXXX X X     XXX  X
                                                    X     XXX          XXXXX
                                 +----------->   XXXX                      X
                                 |              XX      studio-ini.php     X
                                 |              XX X XX                XXXX
                                 |                   X     XX+XXX      XX
                                 |            +--->  XXXXXX  |  X    XXX
                                 |            |              |   XXX
                                 |            |              |
                                 |            |              v
                             +---+---+    +---+---+    +-----+-----+
                             |NodeMCU|    |NodeMCU|    |PROCESSING |
                             +---+---+    +---+---+    |  SCRIPT   |
                                 ^            ^        +-----+-----+
                                 |            |              |
                                 |            |              v
                          +------+----+ +-----+-----+      +-+-+
                          |BNO055 HAND| |BNO055 BLOW|      |PLC|
                          +-----------+ +-----------+      +---+

Directory Structure

  • Arduino - Sketches
  • DotNet/StudioIniSerialBroker - Serial broker desktop app (not used) - Processing sketch used instead
  • KinectConsole - Command line Kinect interface (not used)
  • cloud - PHP read/write broker and service user rights configuration script
  • docs - job spec

Software

  • Arduino 1.8.1 with "NodeMCU 1.0 (ESP-12E Module)" board - added as per this instructable.
  • Processing (maintained by Ken, not currently versioned)

Sensor

Wifi radio

  • NodeMCU - Arduino compatible ESP8266 wifi radio

Arduino code

Two BNO055 and NodeMCU setups are used, one running sketch
Arduino/imu_arduino_blow,
the other
Arduino/imu_arduino_hand.

Note server ip address and wifi network and password details must be edited in the above sketches as required.

PHP code

Read (Processing script relaying to PLC) and write (NodeMCU sketches) are serviced by
cloud/studio-ini.php.
For testing (29 and 30.08.2017) php code ran on Ubuntu 16.04 running Apache, the server itself running as a virtual machine on Amazon Web Services.

Wiring

                                NodeMCU                                                  BNO055

                           +--------------+                                            +--------+
                           |        D1 (5)|  +-------+  SCL        3V      +--------+  | VIN    |
                           |              |                                            |        |
                           |        D2 (4)|  +-------+  SDA        GND     +--------+  | GND    |
                           |              |                                            |        |
+-------------+  +------+  | GND    GND   |  +-------+  GND        D2 (4)  +--------+  | SDA    |
|3.7V Battery |            |              |                                            |        |
+-------------+  +------+  | VIN    3V    |  +-------+  VIN        D1 (5)  +--------+  | SCL    |
                           +--------------+                                            +--------+

Server configuration

read/write web user accesss is set by running
cloud/access_log.sh
when web server is set up.

studioiniserialbroker's People

Contributors

dsikar avatar

Stargazers

 avatar  avatar

Watchers

 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.