Open pflarue opened 3 hours ago
It would also be nice to enable the CAPTURE/CAPTUREDEVICES and PLAYBACK/PLAYBACKDEVICES commands to also allow at least partial reconfiguration of ardopcf without restarting it. This might be easier to implement such that changing CAPTURE or PLAYBACK while CODEC is TRUE might trigger cycling CODEC to FALSE and back to TRUE for the changes to take effect.
Consider also adding host commands that can change the port used for PTT/CAT. This could be useful to allow further reconfiguration of ardopcf without restarting it. Changing a port setting might be required if a device was unplugged and reconnected (perhaps in a different USB socket) resulting in a different port designation.
Currently, the "CODEC" command is disabled. Fix/enable this command so that it can be used to disable audio processing, thereby reducing CPU usage, and then re-enable it at a later time.
My use case for this is for portable operation where ardopcf (and Pat or another host program) is running on a small battery powered headless computer such as a Raspberry Pi. I'd like to leave ardopcf running, while allowing me to use a web browser based host interface (like Pat http) or the ardopcf WebGui to enable audio processing for use, and then disable audio processing to preserve battery life when not in use. Currently, it is necessary to SSH into the Raspberry Pi to start/stop ardopcf, which is less convenient when using a phone or tablet as the user interface.
It is currently possible to stop ardopcf via the "CLOSE" host command, but since that stops ardopcf completely, it is not possible for a host to restart it.