The executable program by ON7T for the JT slow modes only runs on Windows platforms and crashed when attempting to run it under WINE. Below is a PHP script that will run on Linux to handle the receive side of things. External applications needed:
arecord, sox, jt9 (part of wsjtx)
No sound device was specified when invoking arecord, this assumes one is using PulseAudio and selects the appropriate sound device from the PulseAudio volume control application.
<?php $f = "decoded.txt"; $wav = "jt9-2.wav"; $wav_tmp = "jt9-2_tmp.wav"; file_put_contents($f, ""); while (true){ do { usleep (200); } while ( !((int)date("s") == 0 && ((int)date("i")) % 2 == 0) ); $timestamp = str_pad(date("Hi"), 4, "0", STR_PAD_LEFT); //$slot = intdiv(date("i") % 4,2); // PHP 7 $slot = (int)((date("i") % 4)/2); printf("Time: %sz %d\n",$timestamp,$slot); exec ("arecord -c 1 -r 12000 -f S16_LE -d 105 ".$wav." 2>&1 >/dev/null"); exec ("sox ".$wav." ".$wav_tmp." speed 2.0 2>&1 >/dev/null"); exec ("jt9 -9 -d 3 -S 300 ".$wav_tmp." 2>&1 >/dev/null"); $decodes = file_get_contents($f); echo $decodes; file_put_contents($f, ""); unlink($wav); unlink($wav_tmp); } ?>