AI @ Edge with Arduino and TensorFlow Lite

Shazin Sadakath
2 min readApr 8, 2024

--

Happy to hear a Yes

With the emergence of ChatGPT, AI based applications took off by storm. But it covers mainly on Generative AI which runs on a high capacity local computer or a remote server and sometimes requires the internet.

But there is an lesser known usage for AI in a more expansive area where millions if not billions of devices with limited resources need to make decisions.

This is where AI @ Edge comes to the picture. Traditionally edge devices or internet of things (IoT) usually use a low bandwidth protocol like MQTT to push all their “Data” to a remote server with more resources to do computation to make sense of the data and to make decisions based upon them.

This comes with three major problems;

  1. The edge device is very chatty and uses bandwidth to push data to cloud which may cost a lot. EX:- An edge device running in a desert which connects to the remote server via satellite will have a much higher cost per byte of data transmitted.
  2. The data goes through the public internet which is susceptible for evedropping posing a security threat. EX:- Data on a person’s heart beat per minute may be going out through the internet which can be used against them.
  3. The data transmitted needs to stored for processing in the cloud which may also cost a lot and most of which may be unnecessary.

To address these three major problems AI @ Edge can be used to send “Information” to the cloud instead of “Data”. EX:- Sending out Information about an event taking place is less chatty, pose less of a security threat and costs less to store.

With the emergence of frameworks like TensorFlow Lite and increase in computational, storage capabilities in Edge devices like Arduino BLE Sense this is now possible.

In the following demo I am showing an Arduino BLE Sense dev board running a modified version of micro speech example provided by TensorFlow Lite library and does a simple “Yes” or “No” command detection via the input of received to the microphone within the device then transmit that “Information” to an Arduino UNO R4 WiFi via Bluetooth Low Energy (BLE) which reacts with an 😊 or 🙁 emoji in its LED Matrix.

The source code can be found at my github

Summary

This shows the capabilities of AI @ Edge and the direction edge devices are heading in terms of not just reading sensor data and transmitting to the cloud to devices that process those data and send out necessary information to recipient so that necessary actions can be taken.

--

--

Shazin Sadakath
Shazin Sadakath

No responses yet