Notice: Undefined index: HTTP_ORIGIN in /var/www/html/wp-content/plugins/wp-cors/wp-cors.php on line 29 PyMesh Relaunch - Pycom

We launched it in 2018 and you loved it and now we want to give you even more, so we’ve brought it back bigger and better – PyMesh!

Our Mesh solution works on all of our LoRa supporting development boards, the LoPy4 and FiPy as well as on our OEM modules, L01 and L04.  Our original 2018 launch was fantastic, but we’re always looking to improve – meaning we we’re back to hitting the drawing board, to see how we could make something great, even greater.  

So, we compiled a little list of what’s new and improved, with the help of our tip top R & D and Mesh Engineer, Catalin Ioana.

 

It’s been a year, so here’s a brief summary of what the Mesh network actually does.

 

Mesh networks essentially get rid of gateways, which decentralises the network’s infrastructure. This then means that the network becomes flexible, so it can do many wonderful things – such as generate, change and fix itself. The success of the Mesh network is down to its parts, as any node within the network will automatically connect to the best radio-link available.

 

How does it work?

 

You start by deploying LoRa nodes, which require at least one radio connection to connect to the Mesh network. Then, you chose which LoRa node will become the Border Router (this is one funky little device), which will then take all Mesh-traffic to the Internet.

All devices from the PyMesh network can communicate with any of the other nodes, and all of them go through the Border Router in order to get through to the Internet.  The possibilities are endless, as there can be numerous Border Routers. It just depends upon available Bluetooth, Wifi and Cellular connections… but wait! It doesn’t just stop there.. We’ve made it super snazzy, as the best Border Router is chosen via the distance-vector internal PyMesh Routing algorithm! *cue squeaking noises*

The PyMesh network also means that the router will automatically choose the best path. This choice incorporates a pre-set preference level, from low, medium or high, depending upon the system. This means that if, for example, the WiFi path is cheaper than a cellular one, the preference will be registered and route automatically to the appropriate Border Router.  Finally, the Border Router can deactivate itself, and if this occurs at a point in which external packets are being sent, they will automatically be re-routed onto an alternative path. Ta da!

Where the nodes are geographically placed can vary, and we have made it so that the Mesh network now auto-configures, based upon radio-signal strength (it will automatically connect to the strongest signal).  

This diagram shows the basic overall structure of the network. It shows the network’s ability to auto-connect. As an example, if the user moved a node, such as the one labelled ‘Child’, it would automatically connect to the nearest one, such as the Border Router. The auto-configuration will also route the packet without the user having to do anything!

 

So, what’s changed?

 

Firstly, we’ve taken the burden of gateways into the network itself, which is similar to trends seen in Machine Learning and AI. The result? This means that there is no single point of failure, if the gateway/access point is absorbed into the whole system, then the overall network becomes stronger.

We also improved the rejoining feature, so that a node at reset can quickly rejoin the network with the same IP address. In other words, it will retain the Mesh params in Non-Volatile Memory (NVM).

 

Any more features in the pipeline?

 

Well, our plan is to release a series of MicroPython scripts as examples for all the Mesh features. These features will include the internal parameters being exposed in MicroPython and so will consist of a range of things, such as multiple IPv6 addresses, leader properties, list of routers, list of neighbours with RSSI and IP addresses. 

 

Useful links:

 

Our original blog post

Forum post with updated firmware

Pymesh documentation

More documentation

You can download the source code here

 

Pymesh videos:

 

Pycom PyMesh LoRa Mesh Network Workshop from The Things Conference 2019

See our YouTube Video – Pymesh with 11 Nodes

Showing the Pymesh with LoPy4

Showing Off PyGo Mesh Messaging – Pymesh!