I would loop back pin 12 to another spare pin on your RPi using a 1k resistor and monitor that pin instead. It isn't possible to set up events for an output channel.
Is the PTT an output from direwolf?
Rather than a software fix, would it not be easier in this case to connect your PTT to a second input pin as well and use that?
Rather than a software fix, would it not be easier in this case to connect your PTT to a second input pin and use that?
Missing "Python.h"
Shouldn't __sync_synchronize() be used after writes and before IO reads ?
CPython effectively operates as a single thread (i.e. it uses the GIL) so this is unlikely to be a problem. Do you know of any issues that the lack of __sync_synchronize() causes?
Support Radxa Zero