@airframes/acars-decoder 1.1.1 → 1.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/babel.config.js +6 -0
- package/coverage/clover.xml +1722 -0
- package/coverage/coverage-final.json +23 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +131 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +196 -0
- package/coverage/lcov.info +2177 -0
- package/dist/IcaoDecoder.d.ts +0 -4
- package/dist/IcaoDecoder.js +9 -40
- package/dist/MessageDecoder.js +5 -0
- package/dist/bin/acars-decoder-test.js +2 -0
- package/dist/bin/acars-decoder.js +0 -0
- package/dist/plugins/Label_8E.d.ts +10 -0
- package/dist/plugins/Label_8E.js +57 -0
- package/dist/plugins/Label_QP.d.ts +10 -0
- package/dist/plugins/Label_QP.js +51 -0
- package/dist/plugins/Label_QQ.d.ts +10 -0
- package/dist/plugins/Label_QQ.js +51 -0
- package/dist/plugins/Label_QR.d.ts +10 -0
- package/dist/plugins/Label_QR.js +51 -0
- package/dist/plugins/Label_QS.d.ts +10 -0
- package/dist/plugins/Label_QS.js +51 -0
- package/dist/plugins/Label_SQ.js +36 -34
- package/dist/plugins/official.d.ts +5 -0
- package/dist/plugins/official.js +5 -0
- package/jest.config.ts +195 -0
- package/package.json +12 -4
package/dist/IcaoDecoder.d.ts
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
export declare class IcaoDecoder {
|
|
2
2
|
name: string;
|
|
3
3
|
icao: string;
|
|
4
|
-
milRegex: Array<Object>;
|
|
5
4
|
constructor(icao: string);
|
|
6
|
-
matchAnyRegex(array: Array<RegExp>): boolean;
|
|
7
|
-
dataForCountryCode(code: String): any;
|
|
8
|
-
isUSMilitary(): boolean;
|
|
9
5
|
isMilitary(): true | RegExpMatchArray | null;
|
|
10
6
|
}
|
|
11
7
|
declare const _default: {};
|
package/dist/IcaoDecoder.js
CHANGED
|
@@ -4,50 +4,19 @@ class IcaoDecoder {
|
|
|
4
4
|
constructor(icao) {
|
|
5
5
|
this.name = 'icao-decoder-typescript';
|
|
6
6
|
this.icao = icao;
|
|
7
|
-
this.milRegex = [
|
|
8
|
-
{
|
|
9
|
-
code: "us",
|
|
10
|
-
country: "United States",
|
|
11
|
-
regex: [
|
|
12
|
-
/^adf[7-9]/,
|
|
13
|
-
/^adf[a-f]/,
|
|
14
|
-
/^a(e|f)/
|
|
15
|
-
]
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
code: "eg",
|
|
19
|
-
regex: [
|
|
20
|
-
/^0100(7|8)/
|
|
21
|
-
]
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
code: "ap",
|
|
25
|
-
regex: [
|
|
26
|
-
/^0a4/
|
|
27
|
-
]
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"code": "iy",
|
|
31
|
-
"regex": [
|
|
32
|
-
/^33ff/
|
|
33
|
-
]
|
|
34
|
-
}
|
|
35
|
-
];
|
|
36
|
-
}
|
|
37
|
-
matchAnyRegex(array) {
|
|
38
|
-
return array.some((item) => this.icao.match(item));
|
|
39
|
-
}
|
|
40
|
-
dataForCountryCode(code) {
|
|
41
|
-
var item = this.milRegex.find((item) => item.code == code);
|
|
42
|
-
return item;
|
|
43
|
-
}
|
|
44
|
-
isUSMilitary() {
|
|
45
|
-
return this.matchAnyRegex(this.dataForCountryCode('us'));
|
|
46
7
|
}
|
|
47
8
|
isMilitary() {
|
|
48
9
|
let i = this.icao;
|
|
49
10
|
return (false
|
|
50
|
-
|
|
11
|
+
// us military
|
|
12
|
+
//adf7c8-adf7cf = united states mil_5(uf)
|
|
13
|
+
//adf7d0-adf7df = united states mil_4(uf)
|
|
14
|
+
//adf7e0-adf7ff = united states mil_3(uf)
|
|
15
|
+
//adf800-adffff = united states mil_2(uf)
|
|
16
|
+
|| i.match(/^adf[7-9]/)
|
|
17
|
+
|| i.match(/^adf[a-f]/)
|
|
18
|
+
//ae0000-afffff = united states mil_1(uf)
|
|
19
|
+
|| i.match(/^a(e|f)/)
|
|
51
20
|
//010070-01008f = egypt_mil
|
|
52
21
|
|| i.match(/^0100(7|8)/)
|
|
53
22
|
//0a4000-0a4fff = algeria mil(ap)
|
package/dist/MessageDecoder.js
CHANGED
|
@@ -18,7 +18,12 @@ class MessageDecoder {
|
|
|
18
18
|
this.registerPlugin(new Plugins.Label_B6_Forwardslash(this));
|
|
19
19
|
this.registerPlugin(new Plugins.Label_H1_M1BPOS(this));
|
|
20
20
|
this.registerPlugin(new Plugins.Label_80(this));
|
|
21
|
+
this.registerPlugin(new Plugins.Label_8E(this));
|
|
21
22
|
this.registerPlugin(new Plugins.Label_SQ(this));
|
|
23
|
+
this.registerPlugin(new Plugins.Label_QP(this));
|
|
24
|
+
this.registerPlugin(new Plugins.Label_QQ(this));
|
|
25
|
+
this.registerPlugin(new Plugins.Label_QR(this));
|
|
26
|
+
this.registerPlugin(new Plugins.Label_QS(this));
|
|
22
27
|
}
|
|
23
28
|
registerPlugin(plugin) {
|
|
24
29
|
const pluginInstance = plugin;
|
|
@@ -34,3 +34,5 @@ decode('80', "3N01 POSRPT 0570/13 MSLP/KJFK .N603AV/04F 00:59\n\
|
|
|
34
34
|
/SWND 079/DWND 216/FOB N006857/ETA 01:40.3");
|
|
35
35
|
// Label H1 + M1BPOS
|
|
36
36
|
decode('H1', '#M1BPOSN32492W117178,N33492W118335,195835,350,N32463W117143,195907,N32359W117014,M51,25872,249/TS195835,1214195C27');
|
|
37
|
+
// Label 8E
|
|
38
|
+
decode("8E", "EGSS,1618");
|
|
File without changes
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DecoderPlugin } from '../DecoderPlugin';
|
|
2
|
+
export declare class Label_8E extends DecoderPlugin {
|
|
3
|
+
name: string;
|
|
4
|
+
qualifiers(): {
|
|
5
|
+
labels: string[];
|
|
6
|
+
};
|
|
7
|
+
decode(message: any, options?: any): any;
|
|
8
|
+
}
|
|
9
|
+
declare const _default: {};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const DecoderPlugin_1 = require("../DecoderPlugin");
|
|
4
|
+
// ETA
|
|
5
|
+
class Label_8E extends DecoderPlugin_1.DecoderPlugin {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.name = 'label-8E';
|
|
9
|
+
}
|
|
10
|
+
qualifiers() {
|
|
11
|
+
return {
|
|
12
|
+
labels: ["8E"],
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
decode(message, options = {}) {
|
|
16
|
+
const decodeResult = this.defaultResult;
|
|
17
|
+
decodeResult.decoder.name = this.name;
|
|
18
|
+
decodeResult.formatted.description = 'ETA Report';
|
|
19
|
+
decodeResult.message = message;
|
|
20
|
+
// Style: EGSS,1618
|
|
21
|
+
// Match: arrival_icao,arrival_eta
|
|
22
|
+
const regex = /^(?<arrival_icao>\w{4}),(?<arrival_eta>\d{4})$/;
|
|
23
|
+
const results = message.text.match(regex);
|
|
24
|
+
if (results) {
|
|
25
|
+
if (options.debug) {
|
|
26
|
+
console.log(`Label 8E ETA: groups`);
|
|
27
|
+
console.log(results.groups);
|
|
28
|
+
}
|
|
29
|
+
decodeResult.raw.arrival_eta = new Date();
|
|
30
|
+
decodeResult.raw.arrival_eta.setUTCHours(results.groups.arrival_eta.substr(0, 2), results.groups.arrival_eta.substr(2, 2));
|
|
31
|
+
if (new Date().getUTCHours() > decodeResult.raw.arrival_eta.getUTCHours()) { // Check if ETA is in the past, which would imply it is for the next day
|
|
32
|
+
if (options.debug) {
|
|
33
|
+
console.log("Label 8E: Moving ETA to subsequent day");
|
|
34
|
+
}
|
|
35
|
+
decodeResult.raw.arrival_eta.setDate(decodeResult.raw.arrival_eta.getDate() + 1);
|
|
36
|
+
}
|
|
37
|
+
decodeResult.formatted.items.push({
|
|
38
|
+
type: 'eta',
|
|
39
|
+
code: 'ETA',
|
|
40
|
+
label: 'Estimated Time of Arrival',
|
|
41
|
+
value: decodeResult.raw.arrival_eta.toGMTString(),
|
|
42
|
+
});
|
|
43
|
+
decodeResult.raw.arrival_icao = results.groups.arrival_icao;
|
|
44
|
+
decodeResult.formatted.items.push({
|
|
45
|
+
type: 'destination',
|
|
46
|
+
code: 'DST',
|
|
47
|
+
label: 'Destination',
|
|
48
|
+
value: decodeResult.raw.arrival_icao,
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
decodeResult.decoded = true;
|
|
52
|
+
decodeResult.decoder.decodeLevel = 'full';
|
|
53
|
+
return decodeResult;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
exports.Label_8E = Label_8E;
|
|
57
|
+
exports.default = {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DecoderPlugin } from '../DecoderPlugin';
|
|
2
|
+
export declare class Label_QP extends DecoderPlugin {
|
|
3
|
+
name: string;
|
|
4
|
+
qualifiers(): {
|
|
5
|
+
labels: string[];
|
|
6
|
+
};
|
|
7
|
+
decode(message: any, options?: any): any;
|
|
8
|
+
}
|
|
9
|
+
declare const _default: {};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const DecoderPlugin_1 = require("../DecoderPlugin");
|
|
4
|
+
class Label_QP extends DecoderPlugin_1.DecoderPlugin {
|
|
5
|
+
constructor() {
|
|
6
|
+
super(...arguments);
|
|
7
|
+
this.name = 'label-qp';
|
|
8
|
+
}
|
|
9
|
+
qualifiers() {
|
|
10
|
+
return {
|
|
11
|
+
labels: ['QP'],
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
decode(message, options = {}) {
|
|
15
|
+
const decodeResult = this.defaultResult;
|
|
16
|
+
decodeResult.decoder.name = this.name;
|
|
17
|
+
decodeResult.raw.origin = message.text.substring(0, 4);
|
|
18
|
+
decodeResult.raw.destination = message.text.substring(4, 8);
|
|
19
|
+
decodeResult.raw.gate_out = message.text.substring(8, 12);
|
|
20
|
+
decodeResult.remaining.text = message.text.substring(12);
|
|
21
|
+
decodeResult.formatted.description = 'OUT Report';
|
|
22
|
+
decodeResult.formatted.items = [
|
|
23
|
+
{
|
|
24
|
+
type: 'origin',
|
|
25
|
+
code: 'ORG',
|
|
26
|
+
label: 'Origin',
|
|
27
|
+
value: decodeResult.raw.origin,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
type: 'destination',
|
|
31
|
+
code: 'DST',
|
|
32
|
+
label: 'Destination',
|
|
33
|
+
value: decodeResult.raw.destination,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
type: 'gate_out',
|
|
37
|
+
code: 'GOUT',
|
|
38
|
+
label: 'Gate OUT',
|
|
39
|
+
value: decodeResult.raw.gate_out,
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
decodeResult.decoded = true;
|
|
43
|
+
if (decodeResult.remaining.text === "")
|
|
44
|
+
decodeResult.decoder.decodeLevel = 'full';
|
|
45
|
+
else
|
|
46
|
+
decodeResult.decoder.decodeLevel = 'partial';
|
|
47
|
+
return decodeResult;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.Label_QP = Label_QP;
|
|
51
|
+
exports.default = {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DecoderPlugin } from '../DecoderPlugin';
|
|
2
|
+
export declare class Label_QQ extends DecoderPlugin {
|
|
3
|
+
name: string;
|
|
4
|
+
qualifiers(): {
|
|
5
|
+
labels: string[];
|
|
6
|
+
};
|
|
7
|
+
decode(message: any, options?: any): any;
|
|
8
|
+
}
|
|
9
|
+
declare const _default: {};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const DecoderPlugin_1 = require("../DecoderPlugin");
|
|
4
|
+
class Label_QQ extends DecoderPlugin_1.DecoderPlugin {
|
|
5
|
+
constructor() {
|
|
6
|
+
super(...arguments);
|
|
7
|
+
this.name = 'label-qq';
|
|
8
|
+
}
|
|
9
|
+
qualifiers() {
|
|
10
|
+
return {
|
|
11
|
+
labels: ['QQ'],
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
decode(message, options = {}) {
|
|
15
|
+
const decodeResult = this.defaultResult;
|
|
16
|
+
decodeResult.decoder.name = this.name;
|
|
17
|
+
decodeResult.raw.origin = message.text.substring(0, 4);
|
|
18
|
+
decodeResult.raw.destination = message.text.substring(4, 8);
|
|
19
|
+
decodeResult.raw.wheels_off = message.text.substring(8, 12);
|
|
20
|
+
decodeResult.remaining.text = message.text.substring(12);
|
|
21
|
+
decodeResult.formatted.description = 'OFF Report';
|
|
22
|
+
decodeResult.formatted.items = [
|
|
23
|
+
{
|
|
24
|
+
type: 'origin',
|
|
25
|
+
code: 'ORG',
|
|
26
|
+
label: 'Origin',
|
|
27
|
+
value: decodeResult.raw.origin,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
type: 'destination',
|
|
31
|
+
code: 'DST',
|
|
32
|
+
label: 'Destination',
|
|
33
|
+
value: decodeResult.raw.destination,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
type: 'wheels_off',
|
|
37
|
+
code: 'WOFF',
|
|
38
|
+
label: 'Wheels OFF',
|
|
39
|
+
value: decodeResult.raw.wheels_off,
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
decodeResult.decoded = true;
|
|
43
|
+
if (decodeResult.remaining.text === "")
|
|
44
|
+
decodeResult.decoder.decodeLevel = 'full';
|
|
45
|
+
else
|
|
46
|
+
decodeResult.decoder.decodeLevel = 'partial';
|
|
47
|
+
return decodeResult;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.Label_QQ = Label_QQ;
|
|
51
|
+
exports.default = {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DecoderPlugin } from '../DecoderPlugin';
|
|
2
|
+
export declare class Label_QR extends DecoderPlugin {
|
|
3
|
+
name: string;
|
|
4
|
+
qualifiers(): {
|
|
5
|
+
labels: string[];
|
|
6
|
+
};
|
|
7
|
+
decode(message: any, options?: any): any;
|
|
8
|
+
}
|
|
9
|
+
declare const _default: {};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const DecoderPlugin_1 = require("../DecoderPlugin");
|
|
4
|
+
class Label_QR extends DecoderPlugin_1.DecoderPlugin {
|
|
5
|
+
constructor() {
|
|
6
|
+
super(...arguments);
|
|
7
|
+
this.name = 'label-qr';
|
|
8
|
+
}
|
|
9
|
+
qualifiers() {
|
|
10
|
+
return {
|
|
11
|
+
labels: ['QR'],
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
decode(message, options = {}) {
|
|
15
|
+
const decodeResult = this.defaultResult;
|
|
16
|
+
decodeResult.decoder.name = this.name;
|
|
17
|
+
decodeResult.raw.origin = message.text.substring(0, 4);
|
|
18
|
+
decodeResult.raw.destination = message.text.substring(4, 8);
|
|
19
|
+
decodeResult.raw.wheels_on = message.text.substring(8, 12);
|
|
20
|
+
decodeResult.remaining.text = message.text.substring(12);
|
|
21
|
+
decodeResult.formatted.description = 'ON Report';
|
|
22
|
+
decodeResult.formatted.items = [
|
|
23
|
+
{
|
|
24
|
+
type: 'origin',
|
|
25
|
+
code: 'ORG',
|
|
26
|
+
label: 'Origin',
|
|
27
|
+
value: decodeResult.raw.origin,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
type: 'destination',
|
|
31
|
+
code: 'DST',
|
|
32
|
+
label: 'Destination',
|
|
33
|
+
value: decodeResult.raw.destination,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
type: 'wheels_on',
|
|
37
|
+
code: 'WON',
|
|
38
|
+
label: 'Wheels ON',
|
|
39
|
+
value: decodeResult.raw.wheels_on,
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
decodeResult.decoded = true;
|
|
43
|
+
if (decodeResult.remaining.text === "")
|
|
44
|
+
decodeResult.decoder.decodeLevel = 'full';
|
|
45
|
+
else
|
|
46
|
+
decodeResult.decoder.decodeLevel = 'partial';
|
|
47
|
+
return decodeResult;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.Label_QR = Label_QR;
|
|
51
|
+
exports.default = {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DecoderPlugin } from '../DecoderPlugin';
|
|
2
|
+
export declare class Label_QS extends DecoderPlugin {
|
|
3
|
+
name: string;
|
|
4
|
+
qualifiers(): {
|
|
5
|
+
labels: string[];
|
|
6
|
+
};
|
|
7
|
+
decode(message: any, options?: any): any;
|
|
8
|
+
}
|
|
9
|
+
declare const _default: {};
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const DecoderPlugin_1 = require("../DecoderPlugin");
|
|
4
|
+
class Label_QS extends DecoderPlugin_1.DecoderPlugin {
|
|
5
|
+
constructor() {
|
|
6
|
+
super(...arguments);
|
|
7
|
+
this.name = 'label-qs';
|
|
8
|
+
}
|
|
9
|
+
qualifiers() {
|
|
10
|
+
return {
|
|
11
|
+
labels: ['QS'],
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
decode(message, options = {}) {
|
|
15
|
+
const decodeResult = this.defaultResult;
|
|
16
|
+
decodeResult.decoder.name = this.name;
|
|
17
|
+
decodeResult.raw.origin = message.text.substring(0, 4);
|
|
18
|
+
decodeResult.raw.destination = message.text.substring(4, 8);
|
|
19
|
+
decodeResult.raw.gate_in = message.text.substring(8, 12);
|
|
20
|
+
decodeResult.remaining.text = message.text.substring(12);
|
|
21
|
+
decodeResult.formatted.description = 'IN Report';
|
|
22
|
+
decodeResult.formatted.items = [
|
|
23
|
+
{
|
|
24
|
+
type: 'origin',
|
|
25
|
+
code: 'ORG',
|
|
26
|
+
label: 'Origin',
|
|
27
|
+
value: decodeResult.raw.origin,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
type: 'destination',
|
|
31
|
+
code: 'DST',
|
|
32
|
+
label: 'Destination',
|
|
33
|
+
value: decodeResult.raw.destination,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
type: 'gate_in',
|
|
37
|
+
code: 'GIN',
|
|
38
|
+
label: 'Gate IN',
|
|
39
|
+
value: decodeResult.raw.gate_in,
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
decodeResult.decoded = true;
|
|
43
|
+
if (decodeResult.remaining.text === "")
|
|
44
|
+
decodeResult.decoder.decodeLevel = 'full';
|
|
45
|
+
else
|
|
46
|
+
decodeResult.decoder.decodeLevel = 'partial';
|
|
47
|
+
return decodeResult;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.Label_QS = Label_QS;
|
|
51
|
+
exports.default = {};
|
package/dist/plugins/Label_SQ.js
CHANGED
|
@@ -53,40 +53,42 @@ class Label_SQ extends DecoderPlugin_1.DecoderPlugin {
|
|
|
53
53
|
value: decodeResult.raw.version,
|
|
54
54
|
}
|
|
55
55
|
];
|
|
56
|
-
if (decodeResult.raw.groundStation
|
|
57
|
-
decodeResult.
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
decodeResult.
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
decodeResult.
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
decodeResult.
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
decodeResult.
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
56
|
+
if (decodeResult.raw.groundStation) {
|
|
57
|
+
if (decodeResult.raw.groundStation.icaoCode && decodeResult.raw.groundStation.number) {
|
|
58
|
+
decodeResult.formatted.items.push({
|
|
59
|
+
type: 'ground_station',
|
|
60
|
+
label: 'Ground Station',
|
|
61
|
+
value: `${decodeResult.raw.groundStation.icaoCode}${decodeResult.raw.groundStation.number}`,
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
if (decodeResult.raw.groundStation.iataCode) {
|
|
65
|
+
decodeResult.formatted.items.push({
|
|
66
|
+
type: 'iataCode',
|
|
67
|
+
label: 'IATA',
|
|
68
|
+
value: decodeResult.raw.groundStation.iataCode,
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
if (decodeResult.raw.groundStation.icaoCode) {
|
|
72
|
+
decodeResult.formatted.items.push({
|
|
73
|
+
type: 'icaoCode',
|
|
74
|
+
label: 'ICAO',
|
|
75
|
+
value: decodeResult.raw.groundStation.icaoCode,
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
if (decodeResult.raw.groundStation.coordinates.latitude) {
|
|
79
|
+
decodeResult.formatted.items.push({
|
|
80
|
+
type: 'coordinates',
|
|
81
|
+
label: 'Ground Station Location',
|
|
82
|
+
value: `${decodeResult.raw.groundStation.coordinates.latitude}, ${decodeResult.raw.groundStation.coordinates.longitude}`,
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
if (decodeResult.raw.groundStation.airport) {
|
|
86
|
+
decodeResult.formatted.items.push({
|
|
87
|
+
type: 'airport',
|
|
88
|
+
label: 'Airport',
|
|
89
|
+
value: `${decodeResult.raw.groundStation.airport.name} (${decodeResult.raw.groundStation.airport.icao}) in ${decodeResult.raw.groundStation.airport.location}`,
|
|
90
|
+
});
|
|
91
|
+
}
|
|
90
92
|
}
|
|
91
93
|
if (decodeResult.raw.vdlFrequency) {
|
|
92
94
|
decodeResult.formatted.items.push({
|
|
@@ -7,8 +7,13 @@ export * from './Label_44_OFF';
|
|
|
7
7
|
export * from './Label_44_ON';
|
|
8
8
|
export * from './Label_44_POS';
|
|
9
9
|
export * from './Label_80';
|
|
10
|
+
export * from './Label_8E';
|
|
10
11
|
export * from './Label_B6';
|
|
11
12
|
export * from './Label_ColonComma';
|
|
12
13
|
export * from './Label_H1_M1BPOS';
|
|
13
14
|
export * from './Label_H1_M1BPRG';
|
|
14
15
|
export * from './Label_SQ';
|
|
16
|
+
export * from './Label_QR';
|
|
17
|
+
export * from './Label_QP';
|
|
18
|
+
export * from './Label_QS';
|
|
19
|
+
export * from './Label_QQ';
|
package/dist/plugins/official.js
CHANGED
|
@@ -12,8 +12,13 @@ __export(require("./Label_44_OFF"));
|
|
|
12
12
|
__export(require("./Label_44_ON"));
|
|
13
13
|
__export(require("./Label_44_POS"));
|
|
14
14
|
__export(require("./Label_80"));
|
|
15
|
+
__export(require("./Label_8E"));
|
|
15
16
|
__export(require("./Label_B6"));
|
|
16
17
|
__export(require("./Label_ColonComma"));
|
|
17
18
|
__export(require("./Label_H1_M1BPOS"));
|
|
18
19
|
__export(require("./Label_H1_M1BPRG"));
|
|
19
20
|
__export(require("./Label_SQ"));
|
|
21
|
+
__export(require("./Label_QR"));
|
|
22
|
+
__export(require("./Label_QP"));
|
|
23
|
+
__export(require("./Label_QS"));
|
|
24
|
+
__export(require("./Label_QQ"));
|