SDR on linux

jhowelljr

Feed Broadcaster
Feed Provider
Joined
Jul 3, 2012
Messages
24
Reaction score
2
Location
Sebring, Ohio
I am running an SDR on a raspberry pi 6 with the raspberry pi version of Debian. When I used to run this software in windows I could run it as a service so it would be persistent and not close. Now in Linux the app closes out every couple days and I have to remote in and restart the app. Is there a way to either set the app to be persistent and never close, or a way to set it to auto run on close? Thank you in advance.
 

jhowelljr

Feed Broadcaster
Feed Provider
Joined
Jul 3, 2012
Messages
24
Reaction score
2
Location
Sebring, Ohio
No I am running basically Debian with gui. I was able to struggle my way to setting this up so I could benefit from using sdr rather than a physical scanner, however I am less than newbie when it comes to Linux anything.
 

wgbecks

Active Member
Joined
Jan 17, 2005
Messages
1,181
Reaction score
430
Location
NE Wisconsin
I am running an SDR on a raspberry pi 6 with the raspberry pi version of Debian. When I used to run this software in windows I could run it as a service so it would be persistent and not close.
What Linux OS, and specifically, what SDR application software?
 

jhowelljr

Feed Broadcaster
Feed Provider
Joined
Jul 3, 2012
Messages
24
Reaction score
2
Location
Sebring, Ohio
What Linux OS, and specifically, what SDR application software?
Linux raspberrypi 6.12.34+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.12.34-1+rpt1~bookworm (2025-06-26) aarch64 GNU/Linux

running SDRTrunk version 0.6.1

correction raspberry pi 5
 
Last edited:

merlin

Active Member
Joined
Jul 3, 2003
Messages
3,948
Reaction score
1,895
Location
DN32su
I am running SDR# on Kali, it just works the way it is supposed to. Getting the drivers installed was a chore, an all nighter and I first had persistence issues with Kali. Kali is Debian based but don't know what the difference is.
I am fairly new to Linux myself.
 

saioke

Member
Joined
Apr 18, 2010
Messages
262
Reaction score
125
You didn't specify what application you're trying to run and It's been a minute since I've used Linux - but you could try a bash script perhaps. Create a .sh file and in it, add(If I remember correctly):

#!/bin/bash
while true; do
/path/to/your/application
done
while true: do argument if I remember correctly is an infinite loop and it signifies that if an application is closed or crashes, it'll start up again.

Sometimes you may need to add "sleep 1" or higher below the path of your application, to delay the application from starting too fast.

If you want the bash script to run in the background, I forget how to do this unfortunately but maybe someone else could chime in.

Most importantly, make sure your SD card isn't failing or anything like that. Could be a reason why it's crashing and if that's the case, I don't think even a bash script won't fix that.
 
Last edited:

jhowelljr

Feed Broadcaster
Feed Provider
Joined
Jul 3, 2012
Messages
24
Reaction score
2
Location
Sebring, Ohio
The application is sdtrunk, my raspberry pi 5 has an SSD no sd card and the application is crashing (closing) about every other day. I'm not advanced enough to create a bash script can you explain it like I'm a newbie because I am, lol.
 

saioke

Member
Joined
Apr 18, 2010
Messages
262
Reaction score
125
The application is sdtrunk, my raspberry pi 5 has an SSD no sd card and the application is crashing (closing) about every other day. I'm not advanced enough to create a bash script can you explain it like I'm a newbie because I am, lol.
It's unusual that it's closing like that, are you using the latest stable version of SDRTrunk or a nightly? I don't use SDRTrunk myself but in the past when I attempted to, I couldn't even get the nightly at the time working properly. Could've been a bad build. I didn't know the latest raspberry pi had an SSD kit, that's cool!

Anyways, Bash is similar to .bat on Windows in that it runs through terminal/cmd. Easiest way to create one is to open your text document editor on Linux and add the code, then save it as a .sh file. On Linux though, you'll have to give the .sh file executable permissions, and you can do that by opening the terminal and cd into the directory that sh file is located and typing "chmod +x my_script.sh" and to run the script, you can just navigate to the directory of the script and type "./my_script.sh"

I would personally add both SDRTrunk and the .sh script to a single folder in your home directory. The home directory is the easiest to navigate to, since you can get there by just typing cd in terminal, or "cd ~". You can confirm what directory you're located in the terminal by typing "pwd" and the most useful command in the terminal imo will be "ls" or "ls -a" which will list all the files and folders that are located in your current location.

Oh I forgot to mention but not every Linux distro will use bash. Some debian flavors will use alternatives like ash, or zsh. I've never once used a Linux distro that didn't use bash though, so I assume you won't have any issues there.

I miss using Linux lol. I'd be using it now if I could find a digital audio workstation that I liked. Not a fan of Reaper or Ardour. Oh, and dsd+ fastlane. It doesn't have a native linux port. I think you can run it through WINE but I'd rather not.
 
Last edited:

DC31

Member
Feed Provider
Joined
Feb 19, 2011
Messages
1,648
Reaction score
184
Location
Massachusetts
The application is sdtrunk, my raspberry pi 5 has an SSD no sd card and the application is crashing (closing) about every other day. I'm not advanced enough to create a bash script can you explain it like I'm a newbie because I am, lol.
are you plugging the sdr stick directly into the usb port on the pi? If so, try a short usb extension cable. for some reason the sdr sticks make a poor connection to the pi’s usb port.
 
Top