From 43b6bf7fc8f2cc184ede6d51aa98453ca3ffbf7e Mon Sep 17 00:00:00 2001 From: Christopher Young Date: Thu, 31 Dec 2015 11:18:07 -0500 Subject: [PATCH 1/5] Change compiler flags dump978. --- dump978/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dump978/Makefile b/dump978/Makefile index 2d4aebb3..6645fdc3 100644 --- a/dump978/Makefile +++ b/dump978/Makefile @@ -1,4 +1,4 @@ -CFLAGS+=-O2 -g -Wall -Werror -Ifec +CFLAGS+=-O2 -Wall -Werror -Ifec LDFLAGS= LIBS=-lm CC=gcc From bb23bd507f2a46706830934c35e068ae65c7e5ca Mon Sep 17 00:00:00 2001 From: Christopher Young Date: Thu, 31 Dec 2015 23:44:47 -0500 Subject: [PATCH 2/5] Fix CPU status byte bug. Change link to spec. --- main/gen_gdl90.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main/gen_gdl90.go b/main/gen_gdl90.go index 50ff54de..a3b17bd6 100644 --- a/main/gen_gdl90.go +++ b/main/gen_gdl90.go @@ -349,7 +349,7 @@ func makeOwnshipGeometricAltitudeReport() bool { /* "SX" Stratux GDL90 message. - http://hiltonsoftware.com/stratux/StratuxStatusMessage-V01.pdf + http://hiltonsoftware.com/stratux/ for latest version (currently using V104) */ @@ -492,7 +492,7 @@ func makeSXHeartbeat() []byte { v := uint16(float32(10.0) * globalStatus.CPUTemp) msg[26] = byte((v & 0xFF00) >> 8) - msg[27] = byte(v * 0xFF) + msg[27] = byte(v & 0xFF) // Number of ADS-B towers. num_towers := uint8(len(ADSBTowers)) From f3a90a3d613bce568770b144a15a35c7e81981cd Mon Sep 17 00:00:00 2001 From: Christopher Young Date: Sat, 2 Jan 2016 22:33:06 -0500 Subject: [PATCH 3/5] Remove dump978 binary copy from build process. --- image/spindle/wheezy-stage4 | 1 - 1 file changed, 1 deletion(-) diff --git a/image/spindle/wheezy-stage4 b/image/spindle/wheezy-stage4 index 5a547a5e..d372e81a 100755 --- a/image/spindle/wheezy-stage4 +++ b/image/spindle/wheezy-stage4 @@ -135,7 +135,6 @@ cd stratux make www make xdump978 make xdump1090 -cp -f dump978/dump978 /usr/bin/ cp -f dump1090/dump1090 /usr/bin/ mv /tmp/gen_gdl90 /usr/bin/gen_gdl90 From 65e82714b4642488ccade1efb333626ccd93808a Mon Sep 17 00:00:00 2001 From: Christopher Young Date: Sun, 3 Jan 2016 13:46:26 -0500 Subject: [PATCH 4/5] Add SBS1 message type comments. --- main/traffic.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main/traffic.go b/main/traffic.go index 05765cb8..d00a37e3 100644 --- a/main/traffic.go +++ b/main/traffic.go @@ -442,7 +442,7 @@ func esListen() { //FIXME: Some stale information will be renewed. valid_change := true - if x[1] == "3" { + if x[1] == "3" { // ES airborne position message. DF17 BDS 0,5. //MSG,3,111,11111,AC2BB7,111111,2015/07/28,03:59:12.363,2015/07/28,03:59:12.353,,5550,,,42.35847,-83.42212,,,,,,0 //MSG,3,111,11111,A5D007,111111, , , , ,,35000,,,42.47454,-82.57433,,,0,0,0,0 alt := x[11] @@ -478,7 +478,7 @@ func esListen() { ti.Position_valid = true } } - if x[1] == "4" { + if x[1] == "4" { // ES airborne velocity message. DF17 BDS 0,9. // MSG,4,111,11111,A3B557,111111,2015/07/28,06:13:36.417,2015/07/28,06:13:36.398,,,414,278,,,-64,,,,,0 speed := x[12] track := x[13] @@ -513,7 +513,7 @@ func esListen() { ti.Speed_valid = true } } - if x[1] == "1" { + if x[1] == "1" { // ES identification and category. DF17 BDS 0,8. // MSG,1,,,%02X%02X%02X,,,,,,%s,,,,,,,,0,0,0,0 tail := x[10] From bba257db6d408e4e86be01120e4eac4d7e7f3a8b Mon Sep 17 00:00:00 2001 From: Christopher Young Date: Sun, 3 Jan 2016 13:52:33 -0500 Subject: [PATCH 5/5] Add SBS1 message type 5 "Surveillance alt message". --- main/traffic.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/main/traffic.go b/main/traffic.go index d00a37e3..0fac4465 100644 --- a/main/traffic.go +++ b/main/traffic.go @@ -525,6 +525,16 @@ func esListen() { ti.Tail = tail } } + if x[1] == "5" { // Surveillance alt message. DF4, DF20. + // MSG,5,,,%02X%02X%02X,,,,,,,%d,,,,,,,%d,%d,%d,%d + // MSG,5,111,11111,AB5F1B,111111,2016/01/03,04:43:52.028,2016/01/03,04:43:52.006,,13050,,,,,,,0,,0,0 + alt := x[11] + + altFloat, err := strconv.ParseFloat(alt, 32) + if len(alt) != 0 && err == nil { + ti.Alt = int32(altFloat) + } + } // Update "last seen" (any type of message, as long as the ICAO addr can be parsed). ti.Last_source = TRAFFIC_SOURCE_1090ES