Device firmware 2.2.0, Python API 2.2.0 error on meshtastic.serial_interface.SerialInterface()

I haven been using my serial protocol monitor nicely until loaded firmware 2.2.0 on target device after which I got exception error trying opening serial interface:
Unexpected err=Exception('This version of meshtastic-python requires device firmware version 1.2 or later.). My snippet code is like this:

> def setInterface(self):    
>         try:
>             self.interface =  meshtastic.serial_interface.SerialInterface()
>             pub.subscribe(self.onReceive, "meshtastic.receive") 
>             print("Set interface..")
>             return True
>         except Exception as err:
>             print(f"Unexpected {err=}, {type(err)=}")
>             return False
I don't understand what to do to overcome this error since the python api is level 2.2.0 and the device firmware is 2.2.0 as well.

Did you update your Python repo? There’s a 2.2 release that should fix the version check error.

*Edit: I see that you did, sorry it was in the code snippet. Hmm. Strange, I’ve been using 2.2 without issue. Oh you’re using the API for a custom serial monitor. That could be an issue. Might warrant an issue on Github.

I just opened a issue at api 2.2.0 talking with fmwr 2.2.0 produces error opening interface · Issue #456 · meshtastic/python · GitHub

Problem solved, Mashtastic 2.2.0 works well but unfortunately it was updateded the one belonging to a different python version I have in use. Sorry for the inconvenience.

1 Like