why don’t you just post the syslog?
you know that’s what is interesting to look at
Yeah seems like the audio group does not help.
You need to make sure the audio package is not installed:
apt remove soapysdr0.5-2-module-audio
why don’t you just post the syslog?
you know that’s what is interesting to look at
Yeah seems like the audio group does not help.
You need to make sure the audio package is not installed:
apt remove soapysdr0.5-2-module-audio
It would be really useful to get complete information about what conditions trigger these errors - in particular what options are you passing to dump978 and what is the syslog/journalctl output? Otherwise I’m going to have a hard time reproducing anything.
(I am currently unable to test any of this, but the more I look at this thread the more I think it’s just a problem with the command line)
RPi Stretch, default dump978-fa settings 12 RECEIVER_OPTIONS="--sdr 'driver=rtlsdr' --format CS8"
If the package soapysdr0.5-2-module-audio is installed it will give errors:
root@pi ~ # /usr/share/dump978-fa/start-dump978-fa
raw-port: listening for connections on 0.0.0.0:30978
raw-port: listening for connections on [::]:30978
json-port: listening for connections on 0.0.0.0:30979
json-port: listening for connections on [::]:30979
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
Found Rafael Micro R820T tuner
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
SoapySDR: using maximum manual gain 0.0 dB
SoapySDR: INFO: Using format CS8.
Uncaught exception: Dynamic exception type: std::runtime_error
std::exception::what: RtAudio init error 'RtApiPulse::probeDeviceOpen: unsupported sample rate.
It works fine with these options when the package is not installed.
I’m not sure if that package is part of the recommends of the soapysdr-module-rtlsdr package, someone on a fresh pi would have to check.
Maybe it’s not even a problem because it’s normally not installed.
The other problem was selecting a dongle by serial number i’ll post that problem in a separate post.
.
Here you go
pi@raspberrypi:~ $ cat /var/log/syslog
Copy-pasted in this post, and got this
.
Selecting a dongle by serial number with these options:
RECEIVER_OPTIONS="--sdr 'driver=rtlsdr,serial=00001000' --format CS8"
Serial number works when used with dump1090-fa.
Output with dump978-fa:
root@pi ~ # /usr/share/dump978-fa/start-dump978-fa
raw-port: listening for connections on 0.0.0.0:30978
raw-port: listening for connections on [::]:30978
json-port: listening for connections on 0.0.0.0:30979
json-port: listening for connections on [::]:30979
Found Rafael Micro R820T tuner
SoapySDR: using maximum manual gain 0.0 dB
Uncaught exception: Dynamic exception type: std::runtime_error
std::exception::what: failed to construct stream
Can you try removing the single quotes from 'driver=rtlsdr'
That solved at least the problem with selecting a dongle by serial number!
I’ll check interaction with the audio package.
Yeah it fixed the problem with the audio package as well.
Seems the single quotes screw with the option parser
Cut and paste just the relevant part of syslog that shows the attempt to start the process and the errors it reported; pasting the whole thing is very pointless.
Ok, great! I think the over-quoting ends up as literal quotes in the option and then soapysdr parses it as a key of 'driver
which doesn’t match anything and so doesn’t actually restrict the driver selected… so if you have more than one driver installed it’s just luck what you get. This is a much better bug to deal with
Just like the before.
journalctl -f -u dump978-fa
That is a good approach no matter which service you are looking at.
Anyway hopefully it just works now, you can also select the dongle by serial number:
In the /etc/default/dump978-fa config file, you can use it like this:
RECEIVER_OPTIONS="--sdr driver=rtlsdr,serial=00001000 --format CS8"
Make sure you remove the single quotes.
Indeed! I’ll remove the pull request for adding to the audio group
pi@raspberrypi:~ $ cat /var/log/syslog > syslog.txt
Uploaded to Dropbox:
https://www.dropbox.com/s/4h9n4h8eb3c8m9p/syslog.txt?dl=1
.
As i wrote two post up the complete syslog is not useful most of the time.
Also the problem is probably solved by removing the single quotes.
So try that and then if it still fails if you could show the relevant log.
pi@raspberrypi:~ $ journalctl > journalctl.txt
.
Uploaded to Dropbox
https://www.dropbox.com/s/nun8164fox5dl1r/journalctl.txt?dl=1
.
Yeah no that’s not the relevant log.
This would output the relevant log:
journalctl -f -u dump978-fa
Also screenshots of textfiles are really pointless or are you trying to make a point?
.
Yes I did, but stll failed
pi@raspberrypi:~ $ sudo nano /etc/default/dump978-fa
# dump978-fa configuration
# This is sourced by /usr/share/dump978-fa/start-dump978-fa as a
# shellscript fragment.
# If you are using a PiAware sdcard image, this config file is regenerated
# on boot based on the contents of piaware-config.txt; any changes made to this
# file will be lost.
# dump978-fa won't automatically start unless ENABLED=yes
ENABLED=yes
RECEIVER_OPTIONS="--sdr driver=rtlsdr --format CS8"
DECODER_OPTIONS=""
NET_OPTIONS="--raw-port 30978 --json-port 30979"
.
.
pi@raspberrypi:~ $ sudo reboot
.
pi@raspberrypi:~ $ sudo systemctl status dump978-fa
● dump978-fa.service - dump978 ADS-B UAT receiver
Loaded: loaded (/lib/systemd/system/dump978-fa.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Sun 2019-03-31 10:19:51 EDT; 13s ago
Docs: https://flightaware.com/adsb/piaware/
Process: 422 ExecStart=/usr/share/dump978-fa/start-dump978-fa (code=exited, status=1/FAILURE)
Main PID: 422 (code=exited, status=1/FAILURE)
.
.
pi@raspberrypi:~ $ rtl_test -t
Found 2 device(s):
0: Realtek, RTL2832UFA, SN: 00000001
1: Realtek, RTL2838UHIDIR, SN: 00000001
Using device 0: Generic RTL2832U
usb_claim_interface error -6
Failed to open rtlsdr device #0.
pi@raspberrypi:~ $ rtl_test -t -d 1
Found 2 device(s):
0: Realtek, RTL2832UFA, SN: 00000001
1: Realtek, RTL2838UHIDIR, SN: 00000001
Using device 1: Generic RTL2832U OEM
Detached kernel driver
Found Rafael Micro R820T tuner
Supported gain values (29): 0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.4 15.7 16.6 19.7 20.7 22.9 25.4 28.0 29.7 32.8 33.8 36.4 37.2 38.6 40.2 42.1 43.4 43.9 44.5 48.0 49.6
[R82XX] PLL not locked!
Sampling at 2048000 S/s.
No E4000 tuner found, aborting.
Reattached kernel driver
.
Just to highlight that
.
.
pi@raspberrypi:~ $ journalctl -f -u dump978-fa
-- Logs begin at Sun 2019-03-31 10:19:35 EDT. --
Mar 31 10:32:58 raspberrypi dump978-fa[1544]: Found Rafael Micro R820T tuner
Mar 31 10:32:59 raspberrypi dump978-fa[1544]: Reattached kernel driver
Mar 31 10:32:59 raspberrypi dump978-fa[1544]: usb_claim_interface error -6
Mar 31 10:32:59 raspberrypi dump978-fa[1544]: SoapySDR: using maximum manual gain 49.6 dB
Mar 31 10:32:59 raspberrypi dump978-fa[1544]: SoapySDR: INFO: Using format CS8.
Mar 31 10:33:00 raspberrypi dump978-fa[1544]: Sample source reports error: TIMEOUT
Mar 31 10:33:00 raspberrypi dump978-fa[1544]: Abnormal exit
Mar 31 10:33:00 raspberrypi systemd[1]: dump978-fa.service: Main process exited, code=exited, status=1/FAILURE
Mar 31 10:33:00 raspberrypi systemd[1]: dump978-fa.service: Unit entered failed state.
Mar 31 10:33:00 raspberrypi systemd[1]: dump978-fa.service: Failed with result 'exit-code'.
Mar 31 10:33:30 raspberrypi systemd[1]: dump978-fa.service: Service hold-off time over, scheduling restart.
Mar 31 10:33:30 raspberrypi systemd[1]: Stopped dump978 ADS-B UAT receiver.
Mar 31 10:33:30 raspberrypi systemd[1]: Started dump978 ADS-B UAT receiver.
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: raw-port: listening for connections on 0.0.0.0:30978
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: raw-port: listening for connections on [::]:30978
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: json-port: listening for connections on 0.0.0.0:30979
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: json-port: listening for connections on [::]:30979
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: linux; GNU C++ version 6.2.0 20161010; Boost_106100; UHD_003.009.005-0-unknown
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: usb_claim_interface error -6
Mar 31 10:33:30 raspberrypi dump978-fa[1605]: Detached kernel driver
Mar 31 10:33:31 raspberrypi dump978-fa[1605]: Found Rafael Micro R820T tuner
Mar 31 10:33:31 raspberrypi dump978-fa[1605]: Reattached kernel driver
Mar 31 10:33:31 raspberrypi dump978-fa[1605]: usb_claim_interface error -6
Mar 31 10:33:31 raspberrypi dump978-fa[1605]: SoapySDR: using maximum manual gain 49.6 dB
Mar 31 10:33:31 raspberrypi dump978-fa[1605]: SoapySDR: INFO: Using format CS8.
Mar 31 10:33:32 raspberrypi dump978-fa[1605]: Sample source reports error: TIMEOUT
Mar 31 10:33:32 raspberrypi dump978-fa[1605]: Abnormal exit
Mar 31 10:33:32 raspberrypi systemd[1]: dump978-fa.service: Main process exited, code=exited, status=1/FAILURE
Mar 31 10:33:32 raspberrypi systemd[1]: dump978-fa.service: Unit entered failed state.
Mar 31 10:33:32 raspberrypi systemd[1]: dump978-fa.service: Failed with result 'exit-code'.
Mar 31 10:34:02 raspberrypi systemd[1]: dump978-fa.service: Service hold-off time over, scheduling restart.
Mar 31 10:34:02 raspberrypi systemd[1]: Stopped dump978 ADS-B UAT receiver.
Mar 31 10:34:02 raspberrypi systemd[1]: Started dump978 ADS-B UAT receiver.
Mar 31 10:34:02 raspberrypi dump978-fa[1643]: raw-port: listening for connections on 0.0.0.0:30978
Mar 31 10:34:02 raspberrypi dump978-fa[1643]: raw-port: listening for connections on [::]:30978
Mar 31 10:34:02 raspberrypi dump978-fa[1643]: json-port: listening for connections on 0.0.0.0:30979
Mar 31 10:34:02 raspberrypi dump978-fa[1643]: json-port: listening for connections on [::]:30979
Mar 31 10:34:02 raspberrypi dump978-fa[1643]: linux; GNU C++ version 6.2.0 20161010; Boost_106100; UHD_003.009.005-0-unknown
Mar 31 10:34:03 raspberrypi dump978-fa[1643]: usb_claim_interface error -6
Mar 31 10:34:03 raspberrypi dump978-fa[1643]: Detached kernel driver
Mar 31 10:34:03 raspberrypi dump978-fa[1643]: Found Rafael Micro R820T tuner
Mar 31 10:34:04 raspberrypi dump978-fa[1643]: Reattached kernel driver
Mar 31 10:34:04 raspberrypi dump978-fa[1643]: usb_claim_interface error -6
Mar 31 10:34:04 raspberrypi dump978-fa[1643]: SoapySDR: using maximum manual gain 49.6 dB
Mar 31 10:34:04 raspberrypi dump978-fa[1643]: SoapySDR: INFO: Using format CS8.
Mar 31 10:34:05 raspberrypi dump978-fa[1643]: Sample source reports error: TIMEOUT
Mar 31 10:34:05 raspberrypi dump978-fa[1643]: Abnormal exit
Mar 31 10:34:05 raspberrypi systemd[1]: dump978-fa.service: Main process exited, code=exited, status=1/FAILURE
Mar 31 10:34:05 raspberrypi systemd[1]: dump978-fa.service: Unit entered failed state.
Mar 31 10:34:05 raspberrypi systemd[1]: dump978-fa.service: Failed with result 'exit-code'.
It’s trying to use the dongle in use by dump1090-fa.
Use the serial number to specify a dongle.
RECEIVER_OPTIONS="--sdr driver=rtlsdr,serial=00001000 --format CS8"
.
Both have same serial number 00000001.
I will have to change serial number of one of these to say 00000000
.
.
I will try this and see
sudo systemctl stop dump1090-fa
sudo systemctl restart dump978-fa
OK, by stopping dump1090-fa and releasing the dongle, dump978 started working.
It seems both dumps have fallen in love with same dongle, and had a duel, and dump-fa won the duel
Is 2nd dongle very ugly that no one wants her?
pi@raspberrypi:~ $ sudo systemctl stop dump1090-fa
pi@raspberrypi:~ $ sudo systemctl restart dump978-fa
pi@raspberrypi:~ $ sudo systemctl status dump978-fa
● dump978-fa.service - dump978 ADS-B UAT receiver
Loaded: loaded (/lib/systemd/system/dump978-fa.service; enabled; vendor preset: enabled)
Active: active (running) since Sun 2019-03-31 10:47:23 EDT; 9s ago
Docs: https://flightaware.com/adsb/piaware/
Main PID: 2684 (dump978-fa)
CGroup: /system.slice/dump978-fa.service
└─2684 /usr/bin/dump978-fa --sdr driver=rtlsdr --format CS8 --raw-port 30978 --json-port
Mar 31 10:47:25 raspberrypi dump978-fa[2684]: Detached kernel driver
Mar 31 10:47:25 raspberrypi dump978-fa[2684]: Found Rafael Micro R820T tuner
Mar 31 10:47:25 raspberrypi dump978-fa[2684]: Reattached kernel driver
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: Detached kernel driver
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: Found Rafael Micro R820T tuner
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: Exact sample rate is: 2083333.135571 Hz
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: [R82XX] PLL not locked!
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: SoapySDR: using maximum manual gain 49.6 dB
Mar 31 10:47:26 raspberrypi dump978-fa[2684]: SoapySDR: INFO: Using format CS8.
Mar 31 10:47:30 raspberrypi dump978-fa[2684]: [::]:30978: accepted a connection from [::1]:35716