GithubHelp home page GithubHelp logo

jspisi88 / thingsboard-micropython Goto Github PK

View Code? Open in Web Editor NEW

This project forked from manuargue/thingsboard-micropython

0.0 0.0 0.0 14 KB

Unofficial ThingsBoard MQTT MicroPython client

License: Apache License 2.0

Shell 6.00% Python 94.00%

thingsboard-micropython's Introduction

ThingsBoard MQTT MicroPython client

This project is a MicroPython library that provides an client for the Device API of ThingsBoard open-source IoT Platform.

The library consists of a thin wrapper around the MicroPython MQTT module, umqtt.robust.

Installation

To install using pip:

import upip
upip.install('thingsboard-micropython')

Getting Started

Client initialization and telemetry publishing:

from uthingsboard.client import TBDeviceMqttClient

# See examples for more authentication options
client = TBDeviceMqttClient('demo.thingsboard.io', access_token='test01')

# Connecting to ThingsBoard
client.connect()

# Sending telemetry
telemetry = {'temperature': 41.9, 'enabled': False}
client.send_telemetry(telemetry)

# Checking for incoming subscriptions or RPC call requests (non-blocking)
client.check_msg()

# Disconnecting from ThingsBoard
client.disconnect()

Examples

More examples can be found in examples directory.

Support

  • SSL and QoS (0 or 1) as supported by the backend MQTT library, umqtt.robust.
  • All Device API's, except Provisioning.
  • Tested only on ESP32 board running MicroPython v1.16 generic.

Acknowledgment

This library is an adapted version of the official ThingsBoard client SDK for Python, to run in MicroPython.

License

This project is released under Apache 2.0 License.

thingsboard-micropython's People

Contributors

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