Page 1 of 1

Recording by CAT command

Posted: Sun Oct 21, 2018 11:04 am

nice that there's a new forum for this subject. I'm a lot after shack automation.

I'll start straight ahead with a feature request for SDRuno:

- A CAT command to start recording.
- A CAT command to stop recording.

Why I'm interested in those?

To automatically kick on recording when good propagation conditions are detected (by using external homebrew software). And to stop recording when the conditions drop. I mean wideband IQ-recodings, not just audio, so VLC or Audacity or alike are not acceptable solutions.

Right now this can be made by using command line control for HDSDR, but not by using SDRuno.

73, Jukka

Re: Recording by CAT command

Posted: Thu Jan 10, 2019 10:18 am
by sdrplay
Hi Jukka,

Just wanted to confirm that this functionality will be in SDRuno 1.3 as follows...

RE; // return recording stats
RE0; // stop recording
RE1; // start recording
RE4; // pause recording

return codes:

RE0000; // stopped
RE0001; // recording
RE0002; // paused
RE0006; // set command failure

A call to any of the functions will trigger a return code to be sent back.

I've tried to make this in keeping with the RE function I've seen on compatible Kenwood devices.

Best regards,


Re: Recording by CAT command

Posted: Fri Jan 11, 2019 7:23 am
Hi Andy,

that's very nice to hear, thanks in advance!

This opens nice possibilities to externally trigger SDRuno recording.

As I'm familiar with CAT scripting, I can code something for my own purposes which uses SDRuno for listening, then WSJT-X for decoding and then a script to kick SDRuno recording when nice propagation takes place. I hope that some real programmer also gets interested, so one day we might have a general purpose application to use that idea.

As I have an endless queue of needed new features, let me add this which now rises up: Possibility to select antenna input (RSP2/RSPduo) by a CAT command. Temporary workaround may be to keep three instances of SDRuno running and then use the chosen one to record... but that's a bit clumsy, as also three virtual serial port channels are needed.

73, Jukka

Re: Recording by CAT command

Posted: Thu Jan 24, 2019 11:37 am

Code: Select all

@echo off
REM Mediumwave DX-listeners might find this useful, I hope.
REM This should turn SDRuno recording if 1.8MHz ham band FT8 digital mode activity is high (by information grabbed from
REM That means that the propagation conditions are good.
REM When activity drops low again, the recording will be stopped.
REM Assumptions:
REM You have some GNUWIN32 stuff installed, and in system path: wget, grep, cut and tr.
REM You are running SDRuno version 1.3 or later. (_Not_yet_released_when_writing_this._)
REM Your COM3 port is a virtual serial port redirected to SDRuno and conforms with the CAT configuration of SDRuno.
REM Change 'KP24' for being _your_ Maidenhead Locator square.
REM You can tamper the trigger sensitivity by editing [0-9][0-9][0-9][0-9]...  Separately for starting and stopping. Initially the critical score level is 1000.
REM More interested in FM-BC-band? Use frequency 70154000 (instead of 1840000) for 70MHz ham band situation as a reference.
REM Save this as a BAT script file.
REM You can set it to be run by the Task Scheduler for intervals of let's say 10 minutes. It must be at least 5 minutes.
REM 73, Jukka OH2BUA

REM Query pskreporter for the activity score.
for /f "delims=" %%a in ('wget -t 3 -T 5 --no-cache -O - "" ^2^> nul ^| grep 1840000 ^| cut -d " " -f 2') do @set score=%%a

REM Send CAT command to SDRuno to start recording.
echo %SCORE% | grep -q "[0-9][0-9][0-9][0-9]" && echo RE1; | tr -d "\n\r " > COM3

REM Send CAT command to SDRuno to stop recording.
echo %SCORE% | grep -q "[0-9][0-9][0-9][0-9]" || echo RE0; | tr -d "\n\r " > COM3