XML: Macros - Set Xpndr Code: Difference between revisions
From FSDeveloper Wiki
Jump to navigationJump to search
No edit summary |
No edit summary |
||
| Line 23: | Line 23: | ||
@XPDRSet((L:XPDR_Code,number)) | @XPDRSet((L:XPDR_Code,number)) | ||
'''== Transponder Set Using Units ==''' | '''== Transponder Set Using Units ==''' | ||
| Line 30: | Line 31: | ||
1234 (>L:XPDR_Code, enum) | 1234 (>L:XPDR_Code, enum) | ||
(L:XPDR_Code, Bco16) (>K:XPNDR_SET) | (L:XPDR_Code, Bco16) (>K:XPNDR_SET) | ||
In this example, the transponder will be set the digits 1234 | |||
[[category:Aircraft Design]] | [[category:Aircraft Design]] | ||
[[category:Panel and Gauge Design]] | [[category:Panel and Gauge Design]] | ||
Revision as of 01:25, 30 May 2014
== Transponder Set Macro ==
<Macro id="XPDR Set" Name="XPDRSet">
<MacroValue>
@1 s0 10 % l0 10 /
int 10 % 16 * + l0 100 /
int 10 % 256 * + l0 1000 /
int 4096 * + (>K:XPNDR_SET)
</MacroValue>
</Macro>
@XPDRSet(1200)
@XPDRSet((L:XPDR_Code,number))
== Transponder Set Using Units ==
Alternatively, the following can be used to set transponder code:
1234 (>L:XPDR_Code, enum) (L:XPDR_Code, Bco16) (>K:XPNDR_SET)
In this example, the transponder will be set the digits 1234