Turn off Bias-T after observation? And turn on again at next one

Is it possible to turn off Bias-T when observation is done (after the observation) and then turn it on again at the next observation? Some kind of pre and post scripts?

I’m using a Airspy Mini and have biastee=true and I see it is always turned on, even if the station is in idle and have no ongoing observations.

I also noted today if you remove the “biastee=true” from configuration you need to reboot the RPI. Only Apply does not turn off Bias-T.

Do you have anything else in the post obs script ?
Some hints from: GS Setup: LNA with biast-T from RTL SDR dongle - #10 by SA2KNG

not sure on the airspy, maybe it is the airspy_gpio that does it ?

first make sure some your .conf file inside dir /etc/modprobe.d/ blacklist this mod:

blacklist rtl2832_sdr
blacklist dvb_usb_rtl28xxu
blacklist rtl2832
blacklist airspy
blacklist hackrf
blacklist msi001
blacklist msi2500

not sure on the airspy, maybe it is the airspy_gpio that does it ?

I need to check that. Thanks.

Well, I tried the pre and post scripts with the following:

SoapySDRUtil --probe="driver=airspy,biastee=true"
SoapySDRUtil --probe="driver=airspy,biastee=false"

And that works when there is no running observation. But, as soon as an observation starts, it is not possible to access the Airspy with SoapySDRUtil.

If I run SoapySDRUtil --probe="driver=airspy" during an observation I get “Error probing device: device_id missing.”

Is the Airspy “locked” during an observation and can not be accessed with SoapySDRUtil?

Only one program can use it at once, so yes, it will fail during obs.
the pre-/post obs script is only started outside the main observation time. there might be some race condition on the post obs script where the driver takes a few ms too long to release the device before the script is launched. a short sleep statement could take care of that.

Unfortunately a sleep statement does not work in the post script. I have tried 10 seconds. I guess the driver still is in use and is released after the post script.

@SA2KNG or @fredy Do you know where the Airspy driver is released (what file)?
I also noted that when using HackRF the Bias-T is turned off after every observation, without any need for POST-scripts

not sure what you mean, but guessing Debian -- Details of package airspy in bookworm

Do note that they all work differently, depending on both the driver/library and the soapy implementation.

I think I have found a “kind of” solution. I edit the file tasks.py and added this after upload of the result file:

 os.system("SoapySDRUtil --probe='driver=airspy,biastee=false'")
1 Like

clever. :victory_hand: