Giter Club home page Giter Club logo

ble-sensor-to-mqtt-broker's Introduction

ble-mqtt-connector

Connect BLE sensors to local Mosquitto MQTT Broker. Current implementation read BLE beacons in disconnected mode that means sensors do not need to connect to BLE controller all the time. The following BLE sensor essentim SPOT is integrated. In principle the source code can recieve ble sensor data from any other ble sensors as well. https://essentim.com/en/essentim-sensors

image

Prequisites:

  • Local MQTT Broker running as docker container or systemd service
    • sudo apt-get install mosquitto
    • sudo systemctl status mosquitto

Deploy container via CLI:

  • The --cpus= option specify how much of the available CPU resources a container can use. Example the following command limit the container at most 10% of the CPU every second.

  • The --memory= option specify maximum amount of memory the container can use. If you set this option, the minimum allowed value is 6m (6 megabytes).

sudo docker run -d \
 --net=host \
 --name bluetooth --privileged \
 --cpus=".1" --memory="20m" \
 --restart=always \
 --log-driver json-file amjadbadar05/mx-ble-mqtt:0.0.4-armhf --ipv4="127.0.0.1"
 

Deploy container via docker-compose:

 docker-compose up
  • OUTPUT As you can see bluetooth application is connected successfully to local mosquitto broker image

  • Verify conatiner is running image

  • Verify container logs

  • sudo docker container logs bluetooth image

start an interactive bash shell inside your running container in order to change the configuration

sudo docker exec -it bluetooth "bash"

image

Payload

image

ble-sensor-to-mqtt-broker's People

Contributors

abadar05 avatar

Stargazers

 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.