Skip to content
/ mlr Public

Tokay ESP32 Camera + ThingsBoard Rust Demo Firmware

License

Notifications You must be signed in to change notification settings

forGGe/mlr

Repository files navigation

Rust Demo Firmware For Tokay Lite Camera

ThingsBoard dashboard

Necessary Preparation

Build Environment

The firmware is based on ESP32-IDF Rust framework. In order to install all necessary tools, proceed with following:

cargo install espup
espup install
cargo install ldproxy

Uploadcare Account

The demo firmware uses Uploadcare cloud provider as a means of images storage. To have your images uploaded, do following:

  1. Sign up to Uploadcare
  2. Obtain the public API key.

ThingsBoard Initial Configuration

ThingsBoard IoT framework is used in the demo to display the image. No other telemetry is sent for simplicity, but it's easy to extend the firmware to send more data if needed.

To leverage ThingsBoard in this demo, you need to do following:

  1. Create a free account on ThingsBoard demo server.

  2. Follow the official Getting Started guide to provision the device an obtain Device Access Token.

  3. Add a single telemetry record for the newly created ThingsBoard device. This will serve as a placeholder image. You can do it either manually in ThingsBoard UI, or by issuing a command:

    mosquitto_pub -d -q 1 -h "demo.thingsboard.io" -t "v1/devices/me/telemetry" -u "$ACCESS_TOKEN" -m '{"url":"https://placehold.co/600x400.png"}'
  4. Take doc/image_display_widget.json file and upload it to the Widget Library in your ThingsBoard UI.

  5. Create IoT dashboard and add "Image Display Widget" to it. Add more widgets if you want.

  6. At this point your dashboard could look like this:

ThingsBoard dashboard

Configure The Firmware