GithubHelp home page GithubHelp logo

rwbl / make-lighthouse58 Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 4.21 MB

Internet of Things learning case based upon the LEGO ® Lighthouse Point 31051

License: GNU General Public License v3.0

raspberry-pi tinkerforge b4j node-red

make-lighthouse58's Introduction

make_lighthouse58

Summary

This make project Lighthouse58 is an Internet of Things learning case based upon the LEGO® Lighthouse Point 31051 which build has been enhanced. Integrated are several objects with devices, e.g. Top Light, OLED display Weather Underground data, Motion Detector, Outdoor Light, Indoor Lights, Light Dimmers, Ambient Light, LED Status Indicators. The Control Unit hardware is a Raspberry Pi with TinkerForge Bricks & Bricklets.

Lighthouse58 is controlled via

  • Node-RED Browser Dashboard.
  • Windows Client (developed with B4J).
  • Browser Dashboard (multi client control) running as a Server (developed with B4J) on the Control Unit.

lighthouse58-p lighthouse58-cu lighthouse58-c

Objectives

  • To develop an IoT learning case
  • To control objects containing devices
  • An object is for example a house or a group of houses.
  • A device for example a light, switch, servo motor, sensor (e.q. temperature, illuminance, contact, motion) or virtual (e.q. weather request).
  • Each device has a set of actions to control, e.g.light = on | off | state | blink(n).
  • To experiment with hardware, sensors, software
  • To build objects with devices
  • To design a messaging concept
  • To apply learning’s from previous IoT experiments
  • To explore, learn & share
  • To have fun

Note: Details to be found in the Lighthouse58 Concept (lighthouse58.pdf).

Functionality

Lighthouse

  • Top Light Flashing based on the properties of the selected Lighthouse.
  • Information Display showing a clock & weather information (temperature, airpressure, beaufort, wind direction) measured at the nearest lighthouse lat/lon position.
  • Lighthouses configuration (Windows client), e.g. name, position, flash interval, flash on off RGB colors, refrence url.
  • Lighthouse show reference information in default browser (Windows client).

Pier

  • Motion Detector with Dashboard indicator start & stop time.
  • Outdoor light switch, dimmer and red, green or blue color setting.

Lightkeeper Cottage

  • Room light switch, dimmer and red, green or blue color setting.

Boathouse

  • Room light switch, dimmer and red, green or blue color setting.

Control Unit

  • Ambient Light measuring illuminance (in Lux). Depending darkness level, the Pier Outdoor Light is switched on (depending configuration setting).
  • Shutdown the Control Unit.
  • Shutdown the Control Unit via Dashboard or Micro Switch.
  • Status indicators (Trend, Alarm) for CPU °C, Dis Space Used, Memory Used
  • The Control Unit uses a Raspberry Pi 2B to control TinkerForge Bricks & Bricklets.

Weather

  • Weather Underground data every hour for the Lighthouse position and display in a browser Dashboard.

MQTT Console

  • MQTT Console for the Windows Client listing the TinkerForge MQTT messages.

Hardware

  • Raspberry Pi with TinkerForge Master Bricks and Bricklets connected.
  • Communication between devices: TinkerForge Brick MQTT Proxy.

Software

  • Browser Dashboard: developed with Node-RED - an open source visual programming tool by IBM.
  • The Node-RED addon Dashboard is used to control the Lighthouse58 via Browser.

lighthouse58-d lighthouse58-w

Windows Client Dashboard: developed with B4J.

(requires installation of B4J and additional libraries - see B4J source).

  • Uses the TinkerForge Brick MQTT Proxy and does not require Node-RED.

lighthouse58-b4j-dashboard

lighthouse58-b4j-dashboard-lighthouses

Browser Dashboard: developed with B4J.

(Server B4J code (requires installation of B4J and additional libraries - see B4J source).

  • Runs as a Server on the Control Unit, uses the TinkerForge Brick MQTT Proxy and does not require Node-RED, but requires Java.
  • Responsive design using the w3.css framework.
  • Multiple clients can control the dashboard. The state of the controls is updated in the browser for each connected client.
  • Request Weather Information from Weather Underground and display in Dialog.
  • Trigger Control Unit system check (displayed as status message in a label on each connected client) and shutdown.
  • Dialogs for showing the selected Lighthouse information and About box.
  • Server application runs on the Control Unit (Raspberry Pi). Access via Browser with URL http://ip-adress-raspberry-pi:51042.
  • Messaging based on MQTT using TinkerForge messages. No linkage with Node-RED, means the B4J solution runs without Node-RED.
  • Settings defined as a map stored in external settings file - the same file is used by the Windows Client.
  • Library TFMQTT is used to control the TinkerForge Bricklets. Libraries used: jcore,jserver,jrltfmqtt,jmqtt,json,jhttp,jstringutils,jkssh2.

lighthouse58-b4j-dashboard-server

Java

The B4J application has been created for personal use only. If planned for commercial use, ensure to comply to the Oracle JDK License Agreement.

Soure Code

The source code and required libraries can be found in lighthouse58 zip archives. The code is well documented.

make-lighthouse58's People

Contributors

rwbl avatar

Watchers

 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.