Distributed, mobile mesh networks are becoming increasingly important not only for the technical benefits that they can provide, like the lack of a requirement for a centralized server, but also for the huge social impact that they can have.

Protesters in Hong Kong

Citizens who may have their ability to communicate freely infringed by oppressive governments who control the Internet can use distributed mesh networks to communicate with each other in a safe, flexible, and secure way that is outside the hands of government control.

One recent example are the student protests in Hong Kong, where students are using the iOS application FireChat, a mesh network chat client, to communicate with each other on the ground in cases where mobile connectivity is limited.

Inspired by the huge potential for this type of system, our team decided to implement a basic mesh network and distributed chat system on the Boilermake Badges.

Our hack consists of three primary modifications to the badge firmware that was distributed to all Boilermaker attendees:

  1. A modification to the radio data-link layer which implements a broadcast/multicast messaging mode that allows a node to broadcast data to all nodes at once. We accomplished this by modifying the RF24 driver for the radio chipset to efficiently broadcast packets to all addresses.

  2. The mesh networking layer that allows nodes in the network (badges) to receive and forward messages to other nodes. This uses a simple "flooding" technique in which every node rebroadcasts packets it receives to all other nodes, with the exception that it does not rebroadcast packets that it has already received to prevent an infinite explosion of network traffic whereby nodes continue to rebroadcast the same traffic to each other. While there are other, more complex routing algorithms available for MANETs (Mobile Ad-hoc Networks) like AODV, our application is simple enough, our network small enough, and our bandwidth requirements low enough that a simple flooding technique works really well for very low cost!

  3. The chat application that runs on top of the networking layer to provide a user-accessible interface for sending messages. This is implemented via a serial interface to a connected PC. When a user connects their badge to a PC via micro USB and opens a serial terminal (the easiest way is through the Ardunio IDE), they are presented with a text-based chat client where they can assign themselves a name, send messages, and send direct messages to specific users. The serial terminal interface presents some limitations, and unfortunately we had to make some compromises due to time constraints here. But overall, we were able to get something that most would consider a chat client!

The result is that Boilermake attendees not only have a shared, geographic-specific communications channel on which they can communicate, but the ability for private communications between attendees across large distances: two nodes that could normally not communicate with eachother directly can make use of the mesh network to privately communicate. The best part is that the nodes don't even need to have knowledge of the intervening nodes or the state of the rest of the network! It just works!

We're pretty damn proud of what we've been able to build this weekend, and we hope you like it! Although we weren't able to finish the chat client layer in time to get the firmware code out to a large number of Boilermake attendees, we hope our project is useful and illustrates the many (sometimes amazing) benefits of distributed mesh networks!

Built With

Share this project:
×

Updates