-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
A macro needed to help the page definition on FIP devices
- Macros shall be placed in the plugin folder (resources/plugins/xpanel/64) in a subfolder name
macros - Macros shall have the
name.macrofile name structure - A single line macro can be used as
@macro_name(parameter1,parameter2,...)Where parameters can be
dataref,constantorlua_function
The syntax of a macro file:
[macro_info]
name=garmin_g5
description=Garmin G5 Electronic Flight Instrument created for General Aviation
device=fip ;flight information panel
version=1.0
[page:id="HSI"]
[layer:image="fip-images/HSIb_card_hdg.bmp,ref_x:90,ref_y:90,base_rot:0"]
rotation=@{hsi_course}
offset_x="const:200"
offset_y="const:120"
[layer:image="fip-images/HSIb_pointer_crs_tf.bmp,ref_x:70,ref_y:71,base_rot:0"]
rotation=@{hsi_course_rotation}
offset_x="const:200"
offset_y="const:120"
[layer:image="fip-images/HSIb_mask_front.bmp,ref_x:120,ref_y:120,base_rot:0"]
rotation="const:0"
offset_x="const:200"
offset_y="const:120"
[layer:type="text"]
offset_x="const:3"
offset_y="const:218"
text="const:QNH"
[layer:type="text"]
offset_x="const:38"
offset_y="const:218"
text=@{current_baro_hpa}- The macros can be loaded from airplane configuration with the
@use macro_name - To use a macro defined page:
[device:id="saitek_fip_screen"]
serial="MZB05779E2"
[screen:id="fip-screen"]
@use garmin_g5
[@page:id="HSI"]
@parameter="name: hsi_course, value:dataref:B742/HSI/DG_course_deg[0],scale:-1.0"
@parameter="name: hsi_course_rotation, value:lua:hsi_course_rotation()"
@parameter="name: current_baro_hpa, value: lua:get_current_baro_hpa()"Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request