Close

Simulation

A project log for RF Mesh Network

High-throughput zero topology configuration mesh network for temporary/emergency communications over long distances.

trademarkTrademark 05/11/2016 at 01:570 Comments

Before beginning this adventure in networking, I decided to write up a realistic software simulation of a mesh network. I fired up a new C# project and successfully created an application that will generate a randomized mesh topology with a random number of nodes (within a user-defined range) and will simulate visibility between those nodes. I drew out the mesh configurations it was creating, and after adding in some more variables to ensure the network was spread out enough to be realistic, I called it done. That much of it works well for a decent number of nodes. It does sometimes get angry and not execute if I ask for a network of 254 nodes, but that's beside the point.

Once the network is created, each node is actually capable of sending packets to other nodes (these are several instances of a "node" object). Each node can currently map its immediate neighbors quite reliably. Each node keeps a sort of database of the nodes it can find. I am still trying to learn about topological sorting, which seems to be a rather advanced mathematical process, but I hope to get it working eventually.

Even though each instance of the node object could just send a packet to any other node on the mesh, this simulator also simulates distance between each node. For instance, node 5 might be able to see nodes 1 and 3, but it can't see 4. Therefore, when node 5 sends a packet, 1 and 3 will see it (and subsequently determine whether to accept it or ignore it) and node 4 won't see it. Once the full mapping is in place, one of the nodes that is within 5's range should know how to forward the packet on the next hop to node 4. I have successfully mapped the network up to two hops deep and sent packets over 2 hops.

The full recursive mapping of the mesh is not yet working. I'll keep you posted. It will be a fun sandbox for playing around with these protocols and simulating ideas in software.

Discussions