What it does

This project is like the laser tag version of a game you didn't want neither though could be possible but here it is. We were asked by grafana folks to use some IoT devices to log information about the environment that surrounds us, what better surrounding that ourselves playing a game. The game is the typical slap-hands game that we've all played in school. It consists on slapping your opponents hands and the opponent has to avoid it. Then if one fails a try the roles swap and so on.

To materialize this idea we build two pair of gloves based on an ESP32 and capacitive sensors that takes care about the game's logic and takes metrics about it, hence here, Grafana.

How we built it

The gloves send data through an MQTT server to a python script that processes this data in order to 1. Drive the game logic and 2. pass it on into an influxDB database. Then the inlfluxDB can be accessed through a grafana instance to have metrics about our game.

The project consists on a pair of gloves, one for each player, that detects when the other player puts his hand on the glove and sends the statistics to a server running, which sends it to an instance of grafana that runs at a so much lower latency (it uses to work at 5 seconds, and we use it at 100ms). Also, we have adapted the dashboard to look like a game.

Challenges we ran into

The main problem that we encounter are the timings and latencies of the project. Since our game is a "Real-time" system we needed a small latencies, and we had 2 important bottle necks that make the experience not as good as we would like. In one hand we have the update rate of the MQTT server, wich allows us to publish at the rate that we like, but it will not update the values on the subscribers until a certain timing is meet. On the other hand, we had grafana, witch was really useful for showing all the data and statistics that we wanted to show, but it was very hard to change the update rate to a faster one.

Accomplishments that we're proud of

We are proud of wow we worked together mixing our personal expertnesses and we made such an amazing project. We liked how we could build a 36h project (33h actually if we take out the 3 hours of sleep that we gifted ourselves) about a topic that was interesting for the 3 of us and with the finality that we all love, playing.

Built With

Share this project:

Updates