Mode-S Beast to dump1090

I recently have been experimenting with replacing my dongle (although you can run the dongle in parallel using two antennas) with my old Beast receiver. This has always been a good receiver, and it outperforms the dongle.

A couple of obvious things to an oblivious user, was I noticed I was no longer getting any squawks. I seem to remember there being a switch inside the Beast, but I really didn’t want to open the box. EDIT: I opened the box and fixed the switches.

Linux has a neat little tool called ser2net. This has a config file in /etc/ser2net.conf and when you plug a USB device in, you can redirect the output to a TCP port. This was just the ticket for the Beast. I have the Beast now on TCP port 2000. Now all I had to do was move it to port 30104 that dump1090 listens to. Netcat to the rescue.

So, if anyone wants to use their Beast with dump1090 (which I’ve found to be an excellent airborne and surface position plotter), here’s the two config files I use.

ser2net.conf:


2000:raw:3600:/dev/ttyUSB0:3000000 8DATABITS NONE 1STOPBIT

run-dump1090:


#!/bin/bash
/usr/local/bin/dump1090 --net-only --quiet --lat +/-XX.xxxxx --lon +/-XXX.xxxxx &
/bin/sleep 3
/bin/nc -d localhost 2000 | /bin/nc localhost 30004 &

Make sure you have a high quality (5 digit or so) lat/lon position, as the surface postions works a lot better.

Good luck!

1 Like

I actually have a chunk of code waiting for release that will talk to a Mode S Beast serial port and split the data out to an arbitrary number of network sockets while retaining the message framing and handling any Beast settings messages. Might be useful?

I’ll either get it released in the next 3-4 days or at the end of May, I have a holiday in between.

1 Like

I think so, yes. I’m sure the ser2net/netcat is not optimal, although I don’t have lots of data.

I wrote a program a few years ago, with the “one to many” Multicast UDP port. Still though, it used ser2net so I didn’t have to learn about USB interfacing.

I’ll give 'er a test when you’re done.

Have a 2 channel Mode-S beast feeding BaseStation and PlanePlotter displays via ModeSmixer2 TCP output for ADS-B. Have 2 Pi’s - one on each antenna getting MLAT and feeding that to BaseStation and PlanePlotter also via the ModeSmixer. ModeSmixer handles the USB to TCP conversion nicely. Would really like to remove the Pi dongles, use only one Pi, then use the 2 channel Beast TCP on the Pi to feed FA for MLAT. Tried a few things with netcat and modeSmixer - not being a Linux guy have had no success.

This all may be a little messy but I do see everything from both channels and their ADS-B plus MLAT on one display - either Basestation or PlanePlotter (also VRS). Just have lots of hardware and loose 3+db per channel with the splitters.

Any ideas on how to feed Beast TCP from Win7 into a PIAware Rpi and get MLAT etc. would be appreciated.

That would be great! I’ve been using the BEAST receiver using modesmixer2 for a long time now on one of my sites but that uses quite a bit of CPU to do it.

I have a mode s beast that i want to hook up to a raspberry pi 3 and feed plane plotter and flightaware.

When I ran the Beast and piaware (on ubuntu desktop 14.04) my MLAT status said “receiver not supported”. Although the log showed I was synchronized to XX other receivers.

I never did receive any targets (that I could tell). I assume said targets would appear on port 30003, as I don’t run the web server.

The stats page makes a guess about mlat support based on the reported piaware version / image type. Sometimes that can get confused by unusual package configs etc.
If you are seeing synchronization in the local logs, then mlat is working.

You won’t see mlat results on port 30003; they are deliberately not sent there because it was far too common for them to get looped back to FlightAware (or other sites) via other external software and there’s no way to detect that because the port 30003 format does not indicate that a result is mlat.

If you do want a basestation-style feed of mlat and you’re sure that it won’t loop back then you can reconfigure the piaware mlat results format to generate output as you want.

1 Like

Aha, OK I wasn’t sure about that, and it makes sense. I was just looking at some diagram, and not internal code. Yea, I may modify that, as I’m just storing the port 30003 data locally.

Hmm, I scared myself. I commented out the code in net_io.c



    /****** MODIFIED TO ALLOW REMOTE GOING OUT 30003 ********/
    if (/*!is_mlat &&*/ mm->correctedbits < 2) {
        // Don't ever forward 2-bit-corrected messages via SBS output.
        // Don't ever forward mlat messages via SBS output.
        modesSendSBSOutput(mm, a);
    }


and then I saw in the log



04/24/2016 17:38:28 21 msgs recv'd from dump1090; 21 msgs sent to FlightAware


Ah good… But then



04/24/2016 17:43:28 215 msgs recv'd from dump1090 (194 in last 5m); 215 msgs sent to FlightAware


I guess I don’t know why I was sending everything back, since I didn’t modify the other ports.

Maybe I’m just a worry wart…

piaware reads from port 30005 so that change shouldn’t affect it.

But it’s simpler to just make mlat-client generate the results directly on a different port, assuming you have something that can combine a couple of datasources (e.g. VRS will do this). Try something like:



$ piaware-config -mlatResultsFormat "basestation,listen,30106"


(nb: this will disable the normal result path to dump1090 on port 30104 unless you explicitly list it)

Just an update, I did find that I was not looping. I didn’t realize that the log was a running total. I watched for a few minutes, and now I need to get my antenna up in the air, as my view is pretty crappy.

I found out why dump1090 wasn’t giving me any Mode-3 squawks. I had the Beast set for DF17 only - argh!

The added data from FlightAware into the database is pretty neat though. Interesting to watch the MLAT targets scoot about. I need to get back to work on my display program though, as right now I don’t have the plotted points feature working. Thanks for the great software - piaware/dump1090 is neat!

I went to order one and they are out of stock.
I contacted them and they said they should have stock by the end of May.

I ordered a miniadsb, picADSB9 Kit and cavity filter to play with in the mean time.

I saw there is a dump1090-mut branch for this. beast-serial.
It will make things really simple if this works well.
@edgy, did you get the branch to work or are you using your ser2net.conf: and ncat tricks?

It looks like it should be a little better than the airspy USB bandwidth wise, 3Mb/s max. (I know it is a “one trick pony” and the airspy has a huge range of usage)
Also, CPU wise as the majority of the processing is done on the Beast, not the RPI.
It should run well with dump978 as that seems to suck a bit of CPU.
Not sure about bias-t. I may need to make or buy an adapter for this.

I’m still using ser2net/netcat. I’ll have to take a look at that.

Well, I just added the --beast-serial and it seems to work like a champ. I’ll have to add a line to /etc/udev/rules.d to allow non-root, but right now I just use sudo and it opens the USB serial port and goes to town.

That removes the ser2net and netcat bo-jive :slight_smile:

I guess it pays to search the repository for alternative branches!

Obj is pretty quick to add things to the master once they have been tested.
He added the mode ac deco for wide band use to the master after a week or so of testing.
He is on a vacation until the end of May. If a few more can test he may be able to add it to the master a few weeks after he gets back.

Just a note, but I added a file to /etc/udev/rules.d called 71-beast.rules


# Mode-S Beast
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", MODE:="0666"

Seems to work, as I can now attach the USB port as non-root.

The beast-serial branch probably works but I ended up going in a different direction for that with a separate util for talking to the Beast; it was a bit awkward to have dump1090 talk to the beast once you start wanting to do stuff with status messages and settings commands. Will try to get that released once I’m back.

No rush, kick your feet up and watch the bikini’s as you guzzle the rum!

Edgy,
How is your beast going? Your stats are very erriatic so it is hard to tell.
Does it perform better than a std dongle?