Announcement

Collapse
No announcement yet.

Linux feeder software for Flightradar24 (Old software)

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • peterhr
    replied
    Originally posted by digitizing View Post
    Today i just finish setup my raspberry pi after Sdcard error.
    when running the feeder i'v got error

    [e]Data feed time difference too big abs( - )=32037

    after sometimes the error disapear
    [i]Data feed time difference OK abs( - )=0

    and start sending
    [i]sent 2 planes in 1 packets

    but still i can't see the plane at fr24.com
    I have update time using ntp, and set to my local timezone.
    anyone know about the error? how to fix that ?


    T-WARR2
    I wonder if the NTP daemon has managed to set the system time before FR24feed has started?

    If you're using the standard cron job (from the thread http://forum.flightradar24.com/threa...e-to-feed-FR24 ) try increasing the sleep time on the @reboot line in crontab

    If you're starting the feeder as a service (config files /etc/init.d/blah etc ) try putting a 'sleep 10' command before where you start fr24feed app).
    Last edited by peterhr; 2013-11-28, 09:39. Reason: typo's

    Leave a comment:


  • digitizing
    replied
    Originally posted by HermanZA View Post
    You have to make sure the PI is set on timezone UTC. Adjust your time to that and make sure its reports your current time minus time zone difference.
    In my case, when I type in DATE:
    pi@raspberrypi ~ $ date
    Thu Nov 28 09:02:35 UTC 2013


    ... with my timezone being +2, indeed local time now 11:02
    i just change to UTC, and it's still.

    adsb@ADS-B:~/adsbox$ date
    Thu Nov 28 09:16:54 UTC 2013
    adsb@ADS-B:~/adsbox$ sudo ntpdate pool.ntp.org
    28 Nov 09:17:25 ntpdate[3121]: adjust time server 222.165.224.164 offset 0.042131 sec
    adsb@ADS-B:~/adsbox$ ./fr24feed_arm-le_233 --fr24key=b51e336c...
    [i]FR24Feed v233 - built on Jul 9 2013/11:18:23
    [i]Downloading configuration...OK
    [i]Parsing configuration...OK
    [c]Interval: 5s
    [c]Latitude: 0.0000
    [c]Longitude: 0.0000
    [c]GND: YES
    [c]NonADSB: YES
    [i]Source defined as Basestation
    [b]connecting to localhost:30003
    [n]defined 3 servers
    [n]WARR2@83.140.247.21:8099/UDP
    [n]connecting
    [b]connected
    [b]working
    [e]Data feed time difference too big abs( - )=28032
    [e]Data feed time difference too big abs( - )=34403
    [e]Data feed time difference too big abs( - )=33158
    [e]Data feed time difference too big abs( - )=33837
    [n]connected
    [n]switching to UDP
    [e]Data feed time difference too big abs( - )=32172
    [n]working
    [e]Data feed time difference too big abs( - )=32172
    [e]Data feed time difference too big abs( - )=33158
    ..skip....
    [e]Data feed time difference too big abs( - )=32172
    [e]Data feed time difference too big abs( - )=32542
    [i]Data feed time difference OK abs( - )=0
    [i]sent 3 planes in 1 packets
    [i]sent 3 planes in 1 packets
    [i]sent 3 planes in 1 packets

    Leave a comment:


  • HermanZA
    replied
    Originally posted by ricardogerassi View Post
    Fixed. Working like a charm ! Pretty happy with it.

    Its all to do with how many other receivers/feeder stations there are. The F-feeders do have a faster processing and upload time than the T- feeders, but if its only you that have an AC, sure your data will be used and displayed.

    Leave a comment:


  • HermanZA
    replied
    You have to make sure the PI is set on timezone UTC. Adjust your time to that and make sure its reports your current time minus time zone difference.
    In my case, when I type in DATE:
    pi@raspberrypi ~ $ date
    Thu Nov 28 09:02:35 UTC 2013


    ... with my timezone being +2, indeed local time now 11:02

    Leave a comment:


  • digitizing
    replied
    Time error

    Today i just finish setup my raspberry pi after Sdcard error.
    when running the feeder i'v got error

    [e]Data feed time difference too big abs( - )=32037

    after sometimes the error disapear
    [i]Data feed time difference OK abs( - )=0

    and start sending
    [i]sent 2 planes in 1 packets

    but still i can't see the plane at fr24.com
    I have update time using ntp, and set to my local timezone.
    anyone know about the error? how to fix that ?


    T-WARR2

    Leave a comment:


  • ricardogerassi
    replied
    Originally posted by ricardogerassi View Post
    It is working as it should, but FR24 didn't use any packet of mine yet - at least I didn't see any yet. Are FR24 receivers preferred over RTL+RPI ones ?
    Fixed. Working like a charm ! Pretty happy with it.


    Enviado do meu iPad usando o Tapatalk

    Leave a comment:


  • ricardogerassi
    replied
    It is working as it should, but FR24 didn't use any packet of mine yet - at least I didn't see any yet. Are FR24 receivers preferred over RTL+RPI ones ?

    Leave a comment:


  • peterhr
    replied
    The fr24 feed software talks to dump1090 using tcp/ip so as long as both are running on the same machine (localhost), the actual account used shouldnt matter. I dont know if there is a parameter in the fr24 feed that allows you to access dump1090 on another machine.

    Cron should work as root, to check what fr24 feed is doing examine /tmp/fr24feed.log

    The sleep at the start of the @reboot line was to ensure tcp ip (give it time) was ready when we started dump1090 & fr24feed people using wifi might need to increase the delay.

    If you still have problems, consider rebuilding the software on another sd card ... that alows you to revert to the present config at any time by just swapping the card back.


    Sent from my GT-P5110 using Tapatalk

    Leave a comment:


  • ricardogerassi
    replied
    Linux Newbie questions

    I dunno if this is the right place to ask for this question, but since my decoder is Raspberry-Pi based, there it goes:

    I managed to install fr24 package and make it run. I've edited the startup scripts only fr24 after start (since dump1090 is already powered up per instructions stated in http://www.satsignal.eu/raspberry-pi/dump1090.html. I also added this to crontab:

    Code:
    @reboot sleep 5;/etc/init.d/fr24feed.sh            ## calling the startup script
    0 */2 * * * /etc/init.d/fr24feed.sh                ## restart every two hours
    My fr24feed.sh is as follows:

    Code:
    #!/bin/bash
    ### BEGIN INIT INFO
    # Provides: fr24
    # Required-Start: $remote_fs $syslog $time
    # Required-Stop: $remote_fs $syslog $time
    # Should-Start: $network
    # Should-Stop: $network
    # Default-Start: 2 3 4 5
    # Default-Stop: 0 1 6
    # Short-Description: Start 1090dump and fr24 at boot time
    # Description: Start the RTL-SDR decoder and FlightRadar24 feeder at boot
    ### END INIT INFO
    #
    #updated 2013-08-29 - write /tmp/fr24feed.log
    #updated 2013-09-23 - Add INIT INFO section supplied by Jayant
    #
    #make sure fr24feed and dump1090 software are not running
    #
    killall fr24feed_arm-le_233s
    #
    #start dump1090 we dont want output so throw it into a black hole
    # (the null device)
    #the symbol at the end of the line says dont wait for this to finish, just move
    # onto  the next command
    #
    #start the fr24 feeder(use you own key)
    #log output to /tmp/fr24feed.log ... this is actually im memory
    #create a new file each time we start
    #view the file using tail -f /tmp/fr24feed.log
    #(dont do this with dump1090 ... too much output ... will fill memory)
    #
    #
    export FR24AUTHIP=83.140.247.20
    /home/pi/dump1090/fr24feed_arm-le_233s --fr24key=----mykey---- > /tmp/fr24feed.log &
    (Yes, I've moved fr24feed_arm-le_233s to the dump1090 directory)

    I edited the crontab as root and by using ps aux | grep fr24 I got that root is the owner of this process, after a fresh restart. So far, so good. So, my questions are:

    1) Will the fr24 app start every two hours as root, since I edited crontab as root ?
    2) I noticed that with no traffic my feed appears as offline on the Your Account page. Is that correct ?
    3) Is there any order of preference for choosing a feed (i.e. FR24 receivers x RTL-RPI ones) ?

    Sorry for such a bunch of basic questions, but I am totally new in here. Am I doing things ok or am I screwing up things ?

    My feed is available at http://sbfiadsb.no-ip.org.

    Any help will be much appreciated.

    Ricardo
    Brazil

    Leave a comment:


  • peterhr
    replied
    Hi Robert,

    Did you find this (now long) thread - http://forum.flightradar24.com/threa...e-to-feed-FR24

    Generally it has everything you need on the first page - the rest is mainly discussions about problems people have had ... mostly where things haven't quite worked correctly, but usually relating to factors other than the basic software setup.

    ---

    Should you keep having problems, it might be good to set aside your pi SD card use another than do the install starting from installing the the Rasparian Wheezy image (not the pre-built ... not that there's anything wrong with it )

    This takes you through everything you need and explains why we're doing it and can remove some of the mystery that surrounds Linux.

    To build from nothing will take 1 1/2 - 2 hours.
    Last edited by peterhr; 2013-10-31, 09:47.

    Leave a comment:


  • HermanZA
    replied
    Hi Robert,

    Does this happen when you run fr24.sh script, or are you doing the commands manually perhaps?
    You need to be in the right directory to execute them.
    I see you posted colons ( not sure if that is what you are giving the Pi, or just typing it here for clarity ?

    Part of my fr24.sh:

    cd /home/pi/dump1090
    /home/pi/dump1090/dump1090 --enable-agc --modeac --aggressive --net-http-port 8090 --net --net-sbs-port 30003 --quiet --lat -27.912 --lon 25.162 > /dev/null &
    cd ~
    export FR24AUTHIP=83.140.247.20
    /home/pi/fr24feed_arm-le_233s --fr24key=7my-key-here > /tmp/fr24feed.log &

    Leave a comment:


  • RobertNL
    replied
    Hi there,
    I'm very new to all this, i'm trying to get FR24 to work with my Pi but it gives me this after the command "FR24AUTHIP=83.140.247.20 ./fr24feed_arm-le_233s --fr24key=YOUR_SHARING_KEY":

    -bash: ./fr24feed_arm-le_233s: Permission denied

    When I start it with the sudo I will get:

    sudo: ./fr24feed_arm-le_233s: command not found

    Any ideas how to fix this?

    Thanks guys!

    Leave a comment:


  • HermanZA
    replied
    Seems my crontab is still not doing the job, since my process aged beyond 5 past the hour.... I guess its a permission based problem, since cron is owned by root, but dump and feeder are owned/started by pi.
    Whats the easy workaround to get permissions? chmod on something ?

    Leave a comment:


  • peterhr
    replied
    Cron starts things at the user who owns the crontab.

    - but services auto-started as part of bootup are as default run as root - but you can "sudo -u pi sometyhing-to-run' to run it as user pi

    If the task is owned by root then the cronjob may not have sufficient privilege to stop it - unless you sudo the command.

    It gets complicated - which is why I tried to avoid running services for dump1090 and the feeder software.

    at least you're not out of space always worth checking.

    to log something you can do something like

    echo fr24.sh run at `date` >> somefile.txt (put the file into /tmp and it's in memory - uses no space on the sd card)

    ` are the back-ticks found above the tab key

    you can of course get a scrolling list

    Code:
    pi@raspberrypi ~ $ tail -f /tmp/fr24feed.log
    [i]sent 17 planes in 1 packets
    [n]pinging the server
    [i]sent 17 planes in 1 packets
    [i]sent 13 planes in 1 packets
    [i]sent 15 planes in 1 packets
    [i]sent 15 planes in 1 packets
    [i]sent 15 planes in 1 packets
    [i]sent 15 planes in 1 packets
    [i]sent 17 planes in 1 packets
    [i]sent 17 planes in 1 packets
    [i]sent 14 planes in 1 packets
    [i]sent 17 planes in 1 packets

    Leave a comment:


  • HermanZA
    replied
    Peter,

    I am running it as user mode apps, based on your tutorial / instructions you wrote.
    chkconfig seems not to work in Debian - seems it should be update-rc.d ?

    When I do ps -ef (showing selected lines here):
    UID PID PPID C STIME TTY TIME CMD
    root 1 0 0 15:04 ? 00:00:02 init [2]
    root 1898 1 0 15:04 ? 00:00:00 /usr/sbin/cron
    pi 2183 1 31 16:02 ? 00:34:40 /home/pi/dump1090/dump1090 --net-http-port 8090 --net --n
    pi 2184 1 0 16:02 ? 00:00:20 /home/pi/fr24feed_arm-le_233s --fr24key=7fxxxx


    Making me to believe the last 2 PID's were started by user PI. Am I right ?
    Based on that assumption, cron was started by root?
    So, if cron (run by root) attempts to restart dump1090 and fr24feed (started by pi), it will get permission errors (since it did not start the process user pi did). But then again, root is afterall root and should override a user?

    Now that you have me totally confused (again, dare I say!).... shall I comment lines 1-2 in crontab (since it refers to a service), leave line 3 as it starts fr24.sh on reboot, and leave line 4 to restart what line 3 started (maybe bring it down to every hour to test if that will prevent it from hanging) and once eliminated, bring it back to 2 or 4 hourly.

    Will the restart action (triggered by my line 4), be logged anywhere? Want to check if it does happen, else use ps -ef and see how old the process is?

    Free space looks good:
    df -h
    Filesystem Size Used Avail Use% Mounted on
    rootfs 3.6G 1.6G 2.0G 44% /
    /dev/root 3.6G 1.6G 2.0G 44% /
    devtmpfs 212M 0 212M 0% /dev
    tmpfs 44M 216K 44M 1% /run
    tmpfs 5.0M 0 5.0M 0% /run/lock
    tmpfs 88M 0 88M 0% /run/shm
    /dev/mmcblk0p1 56M 19M 38M 33% /boot
    Last edited by HermanZA; 2013-10-29, 18:11. Reason: ...trying to get a fixed width font for the tab'd output

    Leave a comment:

Working...
X