installed on RPi2 following instructions but not working

hello,

I’ve installed piaware on a raspberry Pi2 having debian 8.0 following instructions provided on flightaware site, I’ve also copied /etc/udev/rules.d/rtl-sdr.rules and /etc/modprobe.d/no-rtl.conf from piaware sd distrubution image; but it’s not producing any data.

The dongle I’m using is:
Bus 001 Device 005: ID 0bda:2838 Realtek Semiconductor Corp. RTL2838 DVB-T

The strange thing is that if I use the ready made sd image it works perfectly on a RP1 but if I move the dongle on the RPi 2 configured as described above It neither produces any data nor lets me connect from a browser an the 8080 port.

Is there anything I can try to do to discover what is wrong ?

I’ve also asked the same question by replying to the outage email that was informing me that my Pi was not providing any data but maybe that nobody read what I wrote because they said: now it’s working. (I know that it works when I use your SD, the problem is that I want to use the official raspbian image )

hope someone will find some time to help me.

Is this a Jessie or wheezy install? What diagnostics have you run? Is dump1090 running? Is piaware running? What do the piaware logs say?

Is this a Jessie or wheezy install?
jessie

What diagnostics have you run?
tried to run dump1090 on the command line having this result:
pi@raspberrypi ~ $ dump1090
Found 1 device(s):
0: , , SN: (currently selected)
rtlsdr_write_reg failed with -1
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

Is dump1090 running?
yes

Is piaware running?
yes

What do the piaware logs say?
is there a specific log ? (cannot find anything related under /var/log)

Given what you got when you ran dump1090 by hand, I’d say that dump1090 is probably not running correctly; you will need to investigate that. (It looks like a bad dongle or a USB problem)

What do the piaware logs say?
is there a specific log ? (cannot find anything related under /var/log)

See /tmp/piaware.out

Does the standard piaware sdcard image work on your Pi 2?

the dongle is ok because connecting it to another RPi that has the ready made sd card image it produces data.

cleaned up the log file, restarted the Rpi this is the content still not working.

Also tried to connect using a browser but it keeps loading and no data and no map showed although the Pi has port 8080 listening.

02/12/2016 10:53:04 ****************************************************
02/12/2016 10:53:04 piaware version 2.1-5 is running, process ID 576
02/12/2016 10:53:04 your system info is: Linux raspberrypi 4.1.13-v7+ #826 SMP PREEMPT Fri Nov 13 20:19:03
GMT 2015 armv7l GNU/Linux
02/12/2016 10:53:04 Connecting to FlightAware adept server at piaware.flightaware.com/1200
02/12/2016 10:53:04 Connection to adept server at piaware.flightaware.com/1200 failed: couldn’t open socket
: no such device or address (Temporary failure in name resolution)
02/12/2016 10:53:04 reconnecting in 107 seconds…
02/12/2016 10:53:04 ADS-B data program ‘dump1090’ is listening on port 30005, so far so good
02/12/2016 10:53:04 Starting faup1090: /usr/lib/piaware/helpers/faup1090 --net-bo-ipaddr localhost --net-bo
-port 30005 --stdout
02/12/2016 10:53:04 Started faup1090 (pid 740) to connect to dump1090
02/12/2016 10:53:34 0 msgs recv’d from dump1090; 0 msgs sent to FlightAware
02/12/2016 10:54:51 Connecting to FlightAware adept server at piaware.flightaware.com/1200
02/12/2016 10:54:51 Connection with adept server at piaware.flightaware.com/1200 established
02/12/2016 10:54:52 FlightAware server SSL certificate validated
02/12/2016 10:54:52 encrypted session established with FlightAware
02/12/2016 10:54:52 autoUpdate in adept config is enabled, allowing update
02/12/2016 10:54:52 manualUpdate in adept config is enabled, allowing update
02/12/2016 10:54:52 multilateration support enabled (use piaware-config to disable)
02/12/2016 10:54:52 logged in to FlightAware as user marsim

Does the standard piaware sdcard image work on your Pi 2?

will try this night and advice.

Perhaps your power adapter is insufficient? Pi2 draws more current than Pi1 (and of course the dongles use a lot)

You could also try a different route if you want to start from a clean Debian image. The ads-b feeder project run by jprochazka is an excellent script package that provides a lot more functionality than the stock image. Just put a clean build of Jessie on the SD card, get it updated, and then run the installer for the project.

ads-b-flight-tracking-f21/ads-b-feeder-project-setup-scripts-t36532.html

I’ve made some more tests but to be clear I’ll try to summarize what is working.

  • I’m sure that the dongle is compatible and fully working because if connected to the RPi 1 it captures data and it is stable because I’ve gathered data for several days without crashes and without interruptions, web server on the 8080 port gives me map and flight data
  • I’m using a powerful usb power adapter capable to provide all needed current, to be sure I’ve also tested by using a different single power source that provides 2A having same results

The newest test I’ve made is using the flightaware SD image connecting it to the RPi 2, obviously used the same dongle and surprise, it doesn’t work i.e. web server on the 8080 port is not responding, no data are capured and the log file /tmp/piaware.out doesn’t contain error messages, after usual messages that inform that it is started, logged in the flightaware, started faup1090 etc it periodically logs that receeived 0 msgs from dump1090.

Now I wonder if piaware is not compatible with RPi2 and why.

piaware is compatible with a Pi 2 (I do all my piaware development these days on a Pi 2)

I think you might have a bad Pi 2, perhaps it has a fault somewhere in the USB parts.

A couple of things you can look at:

  • check “dmesg” output for any USB errors
  • stop piaware & dump1090, then run dump1090 from a shell as root with no special args. It should start up and detect the dongle with a correct serial number (probably 00000001) and should not report any errors, and then it should start spewing out decoded Mode S messages. If you get a garbage serial number or rtlsdr_write_reg errors, then dump1090 can’t talk to the dongle properly.

edit: it should look something like this:



# dump1090
Found 1 device(s):
0: Realtek, RTL2838UHIDIR, SN: 00020055 (currently selected)
Found Rafael Micro R820T tuner
Max available gain is: 49.60 dB
Setting gain to: 49.60 dB
Exact sample rate is: 2000000.052982 Hz
Gain reported by device: 49.60 dB
*5d89630342a73b;
CRC: 000044
RSSI: -35.0 dBFS
Time: 328156.50us (phase: 0)
DF 11: All Call Reply.
  Capability  : 5 (Level 2+, airborne)
  ICAO Address: 896303
  IID         : SI-52



Do a lsmod to make sure that the DVB receiver drivers (dvb_usb_rtl28xxu, rtl_2832, and rtl_2830) are NOT loaded They will seize the dongle and prevent dump1090 from using it. If you use a standard OS instead of the piaware image, they could be there and you need to blacklist them.

after lots of tests and changes I solved the problem in the easyest way by removing the usb extension cable that I was using to connect the receiver to the Pi i.e. connecting the receiver directly to the usb port it works perfectly also under RPi2.

So it seems that although the Pi has enough current provided by the power adapter the usb extension was causing some apparently invisible problem :frowning: maybe that the extension is too slim or something else. I can exclude that is broken because it works if used whith other usb periferals. In any case now it works. Thank you for support and attention.

Best regards