Pebble from IoTeX is a proof-of-concept multi-sensor board, intended to provide a detailed view of an asset's position and surrounding environment... that officially begs the question: did the market really need yet another tracker device?
Well, read below, because Pebble is not just a "simple" tracker!
Data RichnessThe first thing that becomes clear is that Pebble is a very data-rich device: it not only embeds a GPS for position tracking, but a 6-axis motion sensor (3D acceleration + 3D orientation), a temperature, humidity, pressure (aka altitude), and indoor air quality sensor, plus a nice ambient light sensor complete the set of sensors integrated in this device.
Trusted Data StreamData-richness is not the only deal here: Pebble also integrates a TEE chip (Trusted Execution Environment), that can securely store encryption keys, and provide cryptographic functions, e.g. to sign the data before sending them out, and so providing a uniquely identifiablestream of "trusteddata" that cannot be tempered with.
This feature, together with a set of smart contracts that orchestrate the logic, not only paves the way to decentralised, trusted supply chain management, but any scenarios where payments or financial transactions can be made based on verifiable data becomes now possible.
Cellular connectivityThe board is designed to be completely autonomous: while it has no WiFi connection, Pebble features a full LTE modem that provides worldwide IoT cellular connectivity: just plug the battery in, push an IoT-SIM card into the slot, and you are ready to drop your Pebble in a remote location, and conveniently receive the collected data conveniently from your home.
The experimentThe idea behind this experiment comes from existing shipment-trackers that allow people to autonomously track the position of their shipments: so why not get all the other information about our precious package, such as motion, temperature and ambient light?
Here is what we could extrapolate from the data:
- GPS position to get the status of the delivery
- Motion measurements to monitor if the package was subject to impacts or falls
- Temperature and Humidity to monitor if the package has been exposed to inappropriate climate conditions
- Ambient Light data will reveal if the package has been opened along the way
Just dropping one of these little boards into a package would allow to analyse all those information about our package along its journey to the final destination, and if something bad happened to the content, we could decide what, where, how happened and decide if the carrier or the recipient is responsible!
Assembling the boardPebble itself is provided as a single board, enclosed into two protective plexiglass shields: very elegant, and very compact considering all the technology it packs inside! Nevertheless, for this project we will remove the plexiglass enclosures, that leaves us with the screws, the spacers, and the bulk board itself, for which we will build our own 3D printed case, also to host a battery, and to protect the board itself:
We will also need to take note of the IMEI number of our board, included in the Pebble box, along with the little LTE antenna, the bulk power connector and an IoT-enabled SIM card that is supported in our country. The official docs provide some some more info about the accessories.
Endpoint ConfigurationThe default configuration of the Pebble firmware will send MQTT messages to an MQTT broker endpoint that is provided by IoTeX for application development purposes (https://trypebble.io:8080). This is a public endpoint, that will show any device connected and its data: it's not usable for production, but it's good for our first test!
Eventually, the board configuration should be changed and the firmware recompiled with the actual MQTT endpoint to be used (e.g. AWS IoT, or any other IoT cloud service that supports MQTT). In any case, IoTeX also provides it's own free implementation of a "Pebble-Backend" service that can be easily deployed with a single command on a Linux machine to get a personal MQTT broker, data storage and Thingsboard dashboard.
3D-Printing the case (and adding the right battery)The case I designed is a just very basic square box, securely holding Pebble with 4 spacers screwed on the bottom, and including a slot for a battery holder in the 18650 format. Since Pebble expects to be powered by a protected battery pack, we should either use a protected lithium battery, to prevent damages, or we could include a battery charger board w/protection circuit into the design, to be used as the charging circuit instead: to keep things simple, we will just include a KEEPPOWER 18650 Li-ion battery and use Pebble to recharge: besides providing a nice capacity of 3500mAh, this battery also has integrated over-charging/over-discharging protection.
The case can be 3D-printed easily, it's a 75 x 82 x 27 [mm] box, plus a top cover with a few openings aligned with the sensors on the board, to allow for a reasonable measurement of temperature, humidity and ambient light.
⟶ Download the 3D files from GrabCad
⟶ Download the 3D files from Thingsverse
Once the battery is connected, just press the Power button to switch Pebble on: the RGB led will start fast-blinking in blue until the LTE modem is connected, then the blue led will stabilise, and a red led will flash every 30s indicating a data packet being sent! We can now screw the cover on top of the case:
our delivery-tracker is ready!
Visualize the dataLet's now connect to https://trypebble.io:8080, enter the default username and password for Thingsboard:
username:tenant@thingsboard.org
password:tenant
and find our device in the devices list (it will be labeled with the IMEI Number of the LTE modem): more detailed instructions about how to configure Thingsboard can be found in the official docs:
Once we verified our Pebble is listed in Thingsboard, let's go ahead and open the Dashboards page, import a new dashboard by clicking the "+
" button at the top-right and select Import Dashboard,
then import the default IoTeX Dashboard:
download pebble_template.json (right click ⟶ save link as...)
select it in the list of dashboards (should be the one at the top of the list), rename it to something that you can easily identify in the list of all the dashboards:
lastly, we need to assign our Pebble to this dashboard by clicking the Edit
button at the bottom right, then the Entity Alias
icon at the top, and edit the default alias and select your actual device from the list.
Saving and getting back to the dashboard screen, all the data from Pebble should be nicely displayed, and you will also be able to edit the timeframe for the displayed data:
We are ready to track our shipment! Just drop the Pebble into the package, put it at the very top of the box, facing the outside for it to reveal ambient light - i.e. reveal if the package has been opened! Close the box, and leave it to the carrier! Also, if it's required by your courier company, do not forget to attach the label required for shipping devices that include Li-ion batteries (ask your shipment company)!
Comments