For my private boat navigation software project, I was looking for an easy way to manipulate a map, in particular openseamap, from both client and server side. The idea being that the server side runs on a Raspberry Pi that contains the map data, collects data from GPS, motion sensors and so on and the client side runs in a web browser on a tablet or phone that connects to the Pi through wifi. Obviously the server side should be able to manipulate the map based on the boat’s position. On the other hand the user should be able to determine things like zoom level and other typical client side decisions on the client side.
In short, flexx:
- allows writing Python code for both client and server side code in a web application.
- takes care of communication between client and server side using an event system that uses websockets, which allows for push events from the server.
- has an already fairly extensive widget toolkit based on phosphor that can be easily extended further.
Being a big fan of Python, this was exactly what I was looking for! Having previously decided to use leaflet for displaying the map, I set out to create a small demo to control a map from both client and server side. The result has since been integrated with the example set that comes with flexx.