Change the following so that M$ compilers and debuggers complain less
1) change all long long data types to uint64_t.
2) Typecast all malloc function returns to the correct pointer types.
3) Explicitly typecast all float to int conversions.
4) Remove inline variable declaration. Allowed in C++, but not in C.
Apparently, the Beast output timestamp has a frequency of 12 Mhz.
Therefore, I've updated the timestamp counter to simulate a 12 Mhz
frequency.
Also incorporate terribls latest updates
Increase the speed of the I/Q to magnitude calculation lookup by
expanding the table to 65536 entries (256*256*2 bytes). At runtime, this
allows us to pick up raw I/Q bytes as a 16 bit value and index into the
magnitude table to get a 16 bit result. This removes the need for
subtracting 127, and then correcting for -ve numbers, so should be
faster, at the expense of a larger data table.
Change the maglut lookup table from 129*129 to 256*256
Initialise the maglut buffer accordingly
Change the data->maglut lookup to use the new maglut buffer
Change the I/Q data buffer pointet to a uint16_t *
I messed up merging the Squawk display in interactive mode into my
master.
However, the original source posted by terribl causes a print line
length greater than 80 characters. This in turn causes the lines to
spill over on a terminal display. I have therefore re-formatted some of
the output so that it fits within 80 characters.
Increase the speed of the I/Q to magnitude calculation lookup by
expanding the table to 65536 entries (256*256*2 bytes). At runtime, this
allows us to pick up raw I/Q bytes as a 16 bit value and index into the
magnitude table to get a 16 bit result. This removes the need for
subtracting 127, and then correcting for -ve numbers, so should be
faster, at the expense of a larger data table.
Change the maglut lookup table from 129*129 to 256*256
Initialise the maglut buffer accordingly
Change the data->maglut lookup to use the new maglut buffer
To try to decode messages with a fundamentally flawed preamble is mostly
a useless waste of CPU time.
The new aggressive mode still detects a sensible percentage of
additional messages because of the error tolerance and two-bits fixes
but does not waste your CPU time.
The phase correction was applied only to a subset of bits! Because of an
offset error.
The detection code layout was modified a bit to make it simpler to
implement more corrections in the future. However only phase correction
is performed currently. Slope correction, or to compensate for the cycloid
effect are two possible improvements.
* Better preamble detection to skip most of the messages we'll likely
not be able to decode.
* A Phase correction algorithm that improves the recognition compared
to the previous algorithm used.
* Javascript output in debug mode, and a debug.html file that can be
used in order to see graphically undecoded samples.
* Ability to detect cross-read messages, that are, messages that happen
to start and end across two different reads from the device or file.
* A few bugx fixed.
* README improved.
This commit address two issues with the implementation of CPR decoding:
Fix#1: The two functions N() and DLon() used to have the latitude
parameter as an integer (!), basically truncating the fractional part
before calling the NL() function to perform the lookup.
This resulted into random strange movements of aircrafts, especially
jumps or shifted positions.
Fix#2: Use milliseconds for CPR odd/even timestamps. Dump1090 already
tried to use the most recent packet received among the odd and even
packets currently available, however to do this correctly millisecond
resolution should be used, otherwise many times the odd and even packet
appear to have the same time in seconds and we don't always use the
latest received.