Running BananaPI M2 Zero

Or as soon as the SDR is used by dump1090 it malfunctions.
It uses 2.4 MSPS sample rate which you might not have done when testing it.

It just uses librtlsdr, nothing special about dump1090-fa.

You can disable the service and start it manually.
Or just check the dmesg for what happens during startup.
Or check the service log using journalctl -u dump1090-fa.

You could also try readsb, not that it’s using the SDR any different than dump1090-fa (https://github.com/wiedehopf/adsb-scripts/wiki/Automatic-installation-for-readsb)

Please reboot BPi. After reboot, issue following commands and post their output:

sudo journalctl -u dump1090-fa -n 15

sudo journalctl -u piaware -n 15

 

Apr 27 12:38:47 bananapim2zero dump1090-fa[4688]: rtlsdr: error querying device #0: Permission denied

… and later then …

Apr 27 12:48:10 bananapim2zero dump1090-fa[1277]: rtlsdr: no supported devices found.
Apr 27 12:48:10 bananapim2zero systemd[1]: dump1090-fa.service: Main process exited, code=exited, status=1/FAILURE
Apr 27 12:48:10 bananapim2zero systemd[1]: dump1090-fa.service: Failed with result 'exit-code'.
Apr 27 15:39:15 bananapim2zero sudo[1227]: pam_unix(sudo:session): session closed for user root
Apr 27 15:39:15 bananapim2zero piaware[866]: no ADS-B data program seen listening on port 30005 for 11 seconds, next check in 60s
Apr 27 15:39:35 bananapim2zero piaware[866]: 0 msgs recv'd from dump1090 (0 in last 100m); 0 msgs sent to FlightAware
Apr 27 15:40:15 bananapim2zero sudo[1235]:  piaware : PWD=/ ; USER=root ; COMMAND=/bin/netstat --program --tcp --wide --all --numeric
Apr 27 15:40:15 bananapim2zero sudo[1235]: pam_unix(sudo:session): session opened for user root(uid=0) by (uid=999)
Apr 27 15:40:15 bananapim2zero sudo[1235]: pam_unix(sudo:session): session closed for user root

Please issue following commands and post output of last command

sudo apt install rtl-sdr   

sudo systemctl stop piaware dump1090-fa   

sudo rtl_test -t   

 

rtl-sdr are present
so …

root@bananapim2zero:~# systemctl stop piaware dump1090-fa
root@bananapim2zero:~# rtl_test -t
No supported devices found.

WHAT THE HECK :face_with_symbols_on_mouth:

Unplug the stick from BPI. Wait for a minute, then replug the stick into BPI. Repeat the test rtl_test -t and post the results.

.. it’s the same result …
Maybe I start over from the backup-image to prevent things I have broken unknown…

Ok, I have start over with the backup image, install the rtlsdr and run the test.
Test runs only once. After that the stick is gone…

Result:

root@bananapim2zero:~# rtl_test -t
Found 1 device(s):
  0:  , , SN:

Using device 0: Generic RTL2832U
rtlsdr_write_reg failed with -7
Resetting device...
rtlsdr_write_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_read_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_read_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_read_reg failed with -4
rtlsdr_write_reg failed with -4
rtlsdr_read_reg failed with -4
rtlsdr_write_reg failed with -4
No supported tuner found
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
Enabled direct sampling mode, input 1
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
Supported gain values (1): 0.0
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
rtlsdr_demod_write_reg failed with -4
rtlsdr_demod_read_reg failed with -4
WARNING: Failed to set sample rate.
No E4000 tuner found, aborting.
rtlsdr_write_reg failed with -4

root@bananapim2zero:~# rtl_test -t
No supported devices found.
root@bananapim2zero:~#

That does not look right, it should be like this, I think

On OrangePiPC with Armbian Bookworm Regular image (NOT minimal / IOT), I get following:

Initially

After plugging out and plugging in the stick:

Seems something wrong with USB port of BPI. Most likely minimal / IOT image has some USB firmware lacking or corrupted. I faced problem of missing WiFi firmware on minimal / IOT image for Debian trixie.

Better try the regular image from Archive.

https://stpete-mirror.armbian.com/archive/bananapim2zero/archive/

 

Sure, I have test it also… Same result.
But to better understand the issue with identical versions, I’ll completely reinstall the “normal” version and create a backup image of it as soon as the system is up to date and BEFORE anything else is installed…

dpkg: unrecoverable fatal error, aborting:
 unable to truncate for updated status of 'armbian-zsh': Read-only file system
/usr/lib/armbian/armbian-apt-updates: line 53: /var/cache/apt/archives/updates.number: Read-only file system
/usr/lib/armbian/armbian-apt-updates: line 61: /var/cache/apt/archives/updates.list: Read-only file system
E: Sub-process /usr/bin/dpkg returned an error code (2)
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - pkgDPkgPM::Go (30: Read-only file system)

:face_with_symbols_on_mouth: :face_with_symbols_on_mouth: :face_with_symbols_on_mouth:

Oops! :angry:

Now try the Ubuntu image suggested by @foxhunter
Bullseye and Bookworm both are available on this page. Choose Bookworm as it is the current version.

 

… I’m just at try #2. Yesterday it goes without any errors… So I think the image like to f*** me… GRRR
If this try also goes wrong i try the FoxHunter-thingy…

Edit say:
2nd try worked without errors. I’m just shutdown, and then I create a backup-image.
After that I try again with the rtl-test

Okay… I’m sick of this crap…

Time to burn my time with other stuff, it might take a few days until I’ve worked through my frustration. For now, I’m just throwing all this junk in the box far away from my eyes…

But thank you so much for your patient help.
I’ll get back to you tomorrow, Tuesday, or Wednesday…

Maybe use a different SD card when you try next time? It says “a file system with errors” in the screen shot?

File system with errors clearly indicates that you have very likely a messed SD card. This can cause lots of errors, even some you might not think it’s related.

According to hwTest and 25 read/write passes, the card is fine. I have no idea why it’s acting up in the BPI.
I’ve now used a different card. This allowed me to install the OS and all updates without errors.
After installing rtl-sdr and subsequent testing, the result is the same as before:

rtlsdr_write_reg failed with -7
Resetting device...
...

The usual errors follow, and then the stick and port no longer exist.

An AirSpy HF+ connected to the port is recognized, but rtl-sdr ignores it.
A connected nooelec nesdr smart isn’t recognized at all.

This isn’t going to work. I’ve removed all the junk and thrown the BPI in the trash.
I’m waiting for the Raspberry Pi. Then we’ll see whether the BPI is just a pile of junk hardware or not…

EDIT say:

With the PoE HAT and DietPI-OS, it’s actually the perfect solution for the project.
What I don’t know (yet) is whether FA and dump1090-fa run under DietPI; does anyone know?

You can.

Or take a look at adsb.im which can be installed via dietpi-software.

1 Like

Yes, I am using DietPi OS on RPi Model 4, and dump1090-fa, dump978-fa and piaware work OK.