Using the python API during the 1.2 transition

Hi ya’ll,

If you are using the python tool or API, it is important consider our big change to the 1.2 firmware. Non-backwards compatible changes to wire protocol (or API) are rare in this project, we probably won’t make a similar large change for at least a year. But you might have been sent to this thread because your python tool is either too old or new for your device firmware.

Using meshtastic-python with firmware 1.1.x

Currently we recommend using device firmware 1.1.x. The new 1.2 releases are in alpha testing. However, the python API has similar version restrictions. If you want an API or command-line tool that ‘just works’ you will want to to use to use a 1.1.x of the python tool:

pip3 install --upgrade "meshtastic<1.2.0"

Note: Because of how the pypi versions work, if you just install “meshtastic” by default you will get the 1.2 version of the tool, which will send you to this thread to explain what you need to do. So this will be possibly something we’ll have to deal with for a few weeks (until 1.2 can be declared ‘beta’).

Using meshtastic-python with firmware 1.2.x

If you are helping by alpha-testing the 1.2 tree (thanks!) you’ll need to use a 1.2.x version of the python tool. This tool (and API library) should be almost identical in usage to the ‘old’ version. But if you encounter problems or have questions or updating an existing app that uses this API, please start a thread in the “Python API” subforum here and we’ll help.

pip3 install --upgrade "meshtastic>=1.2.0"

btw: I’m making this thread now mostly because I want a place to link to (so python developers can ask questions). I’m going to have the API link to this thread in an exception if the device firmware is too old/new…

4 Likes