I’m Ketil, the maintainer of the balena ADS-B project. This thread can be used as a starting point if you are stuck, find bugs or experience other issues with the project.
If you want to get started quickly with this project, click the button below:
Hi! I’m having issues getting PlaneFinder and OpenSky to work.
I’ve gone all the way through the Readme, and verified everything else is working.
(I can go to :8080, :8754 and see services running, etc)
The PlaneFinder site shows my sharecode, but says inactive, and the sharecode has been added to my device variables under “PLANEFINDER_SHARECODE”.
In the OpenSky dashboard, I just don’t see any devices at all, even though I’ve added both the OPENSKY_SERIAL and OPENSKY_USERNAME device variables.
I’ve been trying to get these last two services connected/working for hours now, and I’m not sure where to go from here.
Below are the logs from both services. The parts that might be interesting are in Bold.
This is my opensky-network log:
(I’ve redacted the username, serial, and LAT/LON values here)
I did notice that the Sending Serial Number serial number is different from the other serial numbers.
02.05.21 14:42:55 (-0600) planefinder Verifying settings…
02.05.21 14:42:55 (-0600) planefinder
02.05.21 14:42:57 (-0600) planefinder Plane Finder Sharecode is set: [mySharecode]
02.05.21 14:42:57 (-0600) planefinder Receiver latitude is set: [myLat]
02.05.21 14:42:57 (-0600) planefinder Receiver longitude is set: [myLon]
02.05.21 14:42:57 (-0600) planefinder Receiver host is set: dump1090-fa
02.05.21 14:42:57 (-0600) planefinder Receiver port is set: 30005
02.05.21 14:42:57 (-0600) planefinder
02.05.21 14:42:57 (-0600) planefinder Settings verified, proceeding with startup.
02.05.21 14:42:57 (-0600) planefinder 02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.321842 [-] We were unable to locate a configuration file and have entered configuration mode by default. Please visit: http://[myIP]:30053 to complete configuration.
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.324078 [-] Echo port is now listening on: [myIP]:30054
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.325047 [-] Web server is now listening on: http://[myIP]:30053
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.325256 [V] Performing NTP sync (3.planefinder.pool.ntp.org)…
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.538335 [V] NTP sync succeeded with settings:
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.538476 [V] Stratum: 1
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.539475 [V] System clock time: 1619988177.5383
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.540190 [V] Corrected clock time: 1619988177.5378
02.05.21 14:42:57 (-0600) planefinder 2021-05-02 20:42:57.541177 [V] NTP offset: -0.0005s
If I go to [local IP]:30053 it shows the PlaneFinder config screen. From there, I choose “Use an existing sharecode”, enter the sharecode, LAT, and LON, the click “Assign Sharecode” but there’s no indication that anything has happened.
Oh the PlaneFinder website, my sharecode does show up under “receivers”, but it says the receiver is inactive and that no data has been received.
Thanks for providing an elaborate answer, @Kishaihd!
This is strange behavior indeed. Did you deploy using the balena button or using the git-based method? Did you use the main branch or any of the forks? Is the SD card relatively new, or has it been used for a while? It could be worthwhile to attempt a redeploy of the code. If you overwrite your current instance, all your entered settings will be saved.
Starting with Planefinder, it looks like the config file is missing or invalid. Can you try opening the terminal to the Planefinder service and then issue the command cat /etc/pfclient-config.json? Then do a cat /etc/pfclient-config.json.tpl. (This is to figure out if the config and config template files present on the file system, or missing.)
For OpenSky Network, it’s correct that the submitted serial number is different from the serial that’s displayed in the console (which is a negative number). Is the number you entered in the variable positive and on a similar for to this? 2775123522
I did not use the balena button, I went through each step from your github instructions.
For Planefinder,
Both files exist, but I do see that in /etc/pfclient-config.json the sharekey has 8 blank spaces in front of it, is that normal? I would try to remove the spaces, but it looks like the container doesn’t have vim, emacs, nano, or even vi installed.
The ‘key’ fields in both the json and json.tpl files also match up, and aside from the extra spacing in the sharecode, everything else looks like it should be valid.
For OpenSky, that is the same format as my key, it’s fairly similar.
When I go the OpenSky website and look at manually entering a device, it talks about needing to open a port on my firewall. Maybe something on their end has changed with the way devices are connected?
Very interesting. Good catch on the white space. The key should not have any blank spaces preceding it. Can you have a look at your environment variables in the balena dashboard and see if any white space might have sneaked in on the PlaneFinder key? You would need click the “edit variable” button to check this – trailing white spaces is not visible in the variable overview screen.
For the OpenSky Network issues, I might have to consult with their developers directly. But let’s first figure out the PlaneFinder problems.
It looks like the extra spaces were present in the device variable, and now that they’re gone PlaneFinder is working! Like you said, the spaces could only be seen if you clicked on “edit variable”.
I checked the OpenSky Network variables for extra spaces too, but it looks like I entered those ones correctly.
I’m delighted to hear that you were able to get Planefinder working. Good job!
For OpenSky Network, I will reach out to the lead developer and see if he can see traces of your devices on the server-side. I will contact you directly about how to proceed with this.
@Ketil Hi, Thanks for this excellent platform with many rich features. As I live close to a very busy airport and Covid19 travel restrictions relaxing the amount of flights passing by is enormous. As such I wonder if it’s possible to add two features/filter being:
altitude below 600m (that one exists)
range (from my location) within 1km.
capture those flights so I can report them.
too often I have flight passing by at 1/2 of the minimum altitude and having an filter allows my report them to the authorities automatictly.
Thanks for reaching out! The local PlaneFinder UI allows you to specify altitude filters. Just open the PlaneFinder local view as explained here. Then locate the cogwheel on the upper right-hand side of the screen – it allows you to filter for minimum and maximum altitude. You can also specify range rings here.
I just made some changes to the ADSB Exchange integration. The changes will let you monitor your raw data feed through ADSB Exchange’s tar1090 web interface, which has some options for advanced filtering. You’ll find this by upgrading to the latest version of balena-ads-b. Ensure that you have configured the ADSB Exchange integration as explained in part 8 of the ReadMe.
Next, head over to ADSB Exchange’s Feeder Status page. Finally, click on the link to your personal ADSBexchange Anywhere Map.
Hi Keti, thanks for the reply, much appreciated. I’m aware of this functionality and such I wonder if it’s possible to retain this filter and each plain within the treshold set is exported to a file (or even better, to a twitter feed to alert the authorities that flights are too low).
Understood! It should be possible to solve through some scripting. You can view the received data in json format by going to this URL: YOURDEVICEURL/skyaware/data/aircraft.json.
@Ketil I noticed that the SkyAware v5 (part of the Balena build) is pretty much out of date with the public version v6 and I guess the same for the other elements as well. Is this due to me or part of the Balena lifecycle?