diff --git a/conversions/trueheading.js b/conversions/trueheading.js new file mode 100644 index 0000000..287e302 --- /dev/null +++ b/conversions/trueheading.js @@ -0,0 +1,34 @@ + +module.exports = (app, plugin) => { + return { + pgn: 127250, + title: 'TrueHeading (127250)', + optionKey: 'TRUE_HEADING', + keys: [ + "navigation.headingTrue" + ], + callback: (heading) => { + return [{ + pgn: 127250, + SID: 87, + Heading: heading, + "Variation": undefined, + Reference: "True" + }] + }, + tests: [{ + input: [ 1.35, undefined ], + expected: [{ + "prio": 2, + "pgn": 127250, + "dst": 255, + "fields": { + "SID": 87, + "Heading": 1.35, + "Variation": undefined, + "Reference": "True" + } + }] + }] + } +}