antenna switch, all on when no user is online
Hi KiwiSDR friends, my name is Schorschi and i just registered to this forum.
I searched for my problem, but i could not find anything about it on this page. Please tell me, if there is already a discussion about this problem.
When no user is online on my KiwiSDR, after some time the antenna switch extension turns all the relays on. In my case the 3 big antennas overload the SDR. Also filters an attenuators are in bypass.
Do you have the same Problem?
I searched for my problem, but i could not find anything about it on this page. Please tell me, if there is already a discussion about this problem.
When no user is online on my KiwiSDR, after some time the antenna switch extension turns all the relays on. In my case the 3 big antennas overload the SDR. Also filters an attenuators are in bypass.
Do you have the same Problem?
Comments
I connected the port pins from the beagle with resistors to darlington transistors on a very old relay card.
I use the antenna switch extension since quite a while, and this never happened. I use the snaptek-style protocol, even my HW is not from snaptek, it is home brewed.
I'd try un-installing the switch and re-installing it, just in case something got corrupted.
Regards,
Martin - G8JNJ
If I understood Kari right, I only had to delete a script.
https://raw.githubusercontent.com/OH1KK/KiwiSDR-antenna-switch-extension/master/scripts/reset-to-default-antennas-when-no-users-online
That script is not enabled by default. You have to manually enable it by
modifying crontab file. If you are not done so, it is unlikely that
script turns your relays on. That script is not essential to ant_switch
extension normal operation, and it is safe to delete it from your
KiwiSDR. If you delete script comletely, then it obviously cannot turn
your relays on (anymore). If your relays still turn after deleting that
script, then there is something else going on.
To delete the script:
2. then write
sudo su -
find / -name reset-to-default-antennas-when-no-users-online -exec rm {} \;
What do you think about it? I'm careful because I don't want to completely reinstall the SDR if I fail. My skills are more in hardware, not software.
73
I'm using the (unmodified) antenna switch extension (many thanks for it!) with a homebrew gpio backend, and it works fine. But I noticed that after each bootup all relays are initially on. Only opening the extension for the first time causes a defined state: then all relays go off until one is selected. I suppose the all-on state is due to the gpio lines having been initialized as inputs before the switch extension gets control over them. In my situation, the all-on state is unwanted, so I thought about a workaround.
First idea was to put a line like
/root/extensions/ant_switch/frontend/ant-switch-frontend 2 &>/dev/null
into /etc/rc.local, in order to cause port initialization and select one of the antennas (#2 in my case) as the initial default on each boot. But it turned out that this line is then executed too early and therefore has no effect. One has to wait until the kiwi server has started completely, but on the other hand not too long, as the switching should occur before users could be confused by it. So the idea was to first wait for appearing of the kiwid process and then execute the shown line. But that was still too early. At last I found that looking for kiwi.leds was a perfect criteria.So what I finally put into /etc/rc.local (before the "exit 0" line) was the following: Additionally, I had to change the very first line (shebang) from
#!/bin/sh -e
to#!/bin/bash
in order to have the while condition executed correctly. Now the antenna switch behaves reliably as wanted.(Small caveat: These lines are only excuted on beagle boot, but not on server restart, so there are still chances to cause an all-on state. In my case, where automatic updates are disabled, this will never happen without my knowledge as admin, so it's tolerable for me.)