twilly / cm108

CM108/119 GPIO CLI Tool
GNU General Public License v2.0
4 stars 5 forks source link

Possible to add different variable input for GPIO State? JS8Call #4

Open DGxInfinitY opened 4 months ago

DGxInfinitY commented 4 months ago

I am trying to adapt the use of this tool to allow the use of CM108 based interfaces with software like JS8Call. Currently the software supports everything needed to make the cm108 trigger ptt using gpio 3 except the ability to output 1/0 for on and off. Instead it uses a variable ("%1") to specify a string "on" or "off" rather than an integer "1" or "zero". For example this is the command that JS8Call executes. cm108 -H /dev/hidraw1 -P 5 -L %1 This means when JS8Call is in Tx it runs cm108 -H /dev/hidraw1 -P 5 -L On And when it stops Tx it runs cm108 -H /dev/hidraw1 -P 5 -L Off Obviously this doesn't work with your program but I was wondering if it's possible to append the off or on to 1 or 0 in your program?