Implement TCP Heartbeat

Some users have reported issues where the TCP link to dump1090 can be
lost at times of low traffic density - typically in the middle of the
night. One possible reason for this is that some routers drop the link
if there is no traffic for a predetermined period.

To try and resolve this, dump1090 now sends a 'null' packet consisting
of 7 "0x00" bytes approximately once a  minute if there is no real
received traffic during this time. This packet should be discarded by
the application receiving the dump1090 because it will have an invalid
checksum, and ICAO address 0x000000 is also invalid. However, this null
packet should be enough to keep routers alive.
Windows Version of dump1090

Make the modifications necessary to compile dump1090 for WinXP, Win7 and
hopefully Win8.

The files can be compiled using M$ Visual Studio/C++ 6.0. Due to various
licensing issues, I haven't included the libraries or DLLs. You will
need to locate pthreadVC2.lib and rtlsdr.lib to link the file, install
the zadig drivers to support the dongle, and locate libusb-1.0.dll,
msvcr100.dll, pthreadVC2.dll and rtlsdr.dll.

dump1090.exe will not run on any Windows version prior to XP SP2,
because msvcr100.dll imports several functions from the Windows kernel
that are not available on earlier versions. This means dump1090 won't
work on Win2K.

The major change to the code relates to file handles. The original code
assumes Linux behaviour in that handles are allocated from 0
sequentially upwards. However Windows handles are allocated pseudo
randomly, and handle numbers greater than 1024 would break the code. The
code has therefore been modified to use a linked list of connection
structures, rather than a static array limited to 1024 entries.
BUGFIX : Possible linked list bug
BUGFIX : Windows version HTML Web browser support

Allow connection of a web browser to the Windows version via
http://127.0.0.1:8080
Fixed: now skipping correct number of values in magnitude buffer

Variable j points to the current location in the magnitude vector.
When decoding a message  (MODES_PREAMBLE_US+msglen)*2 is added to j.
In the loop head j is increased by 1, so one value was skipped.
Merge pull request #14 from kopppa91/master

Fixed: now skipping correct number of values in magnitude buffer
Fixed: now skipping correct number of values in magnitude buffer

Variable j points to the current location in the magnitude vector.
When decoding a message  (MODES_PREAMBLE_US+msglen)*2 is added to j.
In the loop head j is increased by 1, so one value was skipped.
Publish Version 1.08.2705.14

A few minor additions and bug fixes as detailed below

1) Additional command line option "--net-buffer <n>" to specify the TCP
output buffer size. Default is n=0, which is 64Kb. Specify a value of n
to increase the buffer size according to  Size  = 64Kb * 2^n, so an n of
1 = 128Kb, n=2 is 256Kb etc. n is limited to 7, so the max size is 8Mb.
This option may assist if you have a high number of aircraft being
received, and an unreliable network connection, or if the receiving end
can be busy for an extended time.

2) Bug fix in ppup1090 which prevented the uploading of valid
ModeA/Squawk codes

3) Bug fix per Markus Grab's commit.
Merge remote-tracking branch 'origin/Debug'
Incorrect value for auto-gain

Incorrect value for auto-gain option the Modes.gain is multiplied by 10.
Merge pull request #16 from papasven/master

Incorrect value for auto-gain
B"H decode more data, etc.

- decodes a bit more information
- misc. small changes
B"H allow disable ports, doc disable net heartbeat
Merge pull request #19 from hhm0/decoding

decode more squawk codes
Merge pull request #20 from hhm0/network_disabling

make network services disable-able
B"H view1090: handle disconnection

 - keep trying to reconnect to server if disconnected
B"H view1090: do not block

 - do not block on network data
B"H view1090: sleep a bit between loops

view1090 was using close to 100% CPU before, with the non-blocking
commits and the reconnection code. sleep a bit between loop iterations
to keep CPU usage low.

CPU usage with this addition was down to <1% in testing.
B"H view1090: do not use pthreads

It *seems* that pthreads are used in dump1090 for I/! sample reading
only. So view1090 need not use pthread_exit.
Update dump1090.c