Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MB-339 Radio controls added #424

Merged
merged 2 commits into from
Oct 15, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Scripts/DCS-BIOS/doc/Addresses.h
Original file line number Diff line number Diff line change
Expand Up @@ -17498,6 +17498,8 @@
#define MB_339_AFT_COM2_SQUELCH 0x83AE, 0x00C0, 6
#define MB_339_AFT_COM2_TOD 0x83AE, 0x0100, 8
#define MB_339_AFT_COM2_TOD_AM 0x83AE, 0x0100
#define MB_339_AFT_COMM1_A 0x8406
#define MB_339_AFT_COMM2_A 0x840E
#define MB_339_AFT_CONTROL_ADF 0x8350, 0x0800, 11
#define MB_339_AFT_CONTROL_ADF_AM 0x8350, 0x0800
#define MB_339_AFT_CONTROL_ADF_L 0x8352, 0x0080, 7
Expand Down Expand Up @@ -17929,6 +17931,8 @@
#define MB_339_FLAP_LVR_G_A 0x8268
#define MB_339_FUEL_FLOW_G 0x831A, 0xFFFF, 0
#define MB_339_FUEL_FLOW_G_A 0x831A
#define MB_339_FWD_COMM1_A 0x83F6
#define MB_339_FWD_COMM2_A 0x83FE
#define MB_339_FW_ACCEL_G 0x8238, 0xFFFF, 0
#define MB_339_FW_ACCEL_G_A 0x8238
#define MB_339_FW_ACCEL_MAX 0x823C, 0xFFFF, 0
Expand Down
82 changes: 82 additions & 0 deletions Scripts/DCS-BIOS/doc/json/MB-339.json
Original file line number Diff line number Diff line change
Expand Up @@ -14875,6 +14875,88 @@
"physical_variant": "toggle_switch"
}
},
"Radio Frequencies": {
"AFT_COMM1": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Aft COMM1",
"identifier": "AFT_COMM1",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33798,
"address_identifier": "MB_339_AFT_COMM1_A",
"address_mask_identifier": "MB_339_AFT_COMM1_AM",
"address_mask_shift_identifier": "MB_339_AFT_COMM1",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"AFT_COMM2": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Aft COMM2",
"identifier": "AFT_COMM2",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33806,
"address_identifier": "MB_339_AFT_COMM2_A",
"address_mask_identifier": "MB_339_AFT_COMM2_AM",
"address_mask_shift_identifier": "MB_339_AFT_COMM2",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"FWD_COMM1": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Forward COMM1",
"identifier": "FWD_COMM1",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33782,
"address_identifier": "MB_339_FWD_COMM1_A",
"address_mask_identifier": "MB_339_FWD_COMM1_AM",
"address_mask_shift_identifier": "MB_339_FWD_COMM1",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"FWD_COMM2": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Forward COMM2",
"identifier": "FWD_COMM2",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33790,
"address_identifier": "MB_339_FWD_COMM2_A",
"address_mask_identifier": "MB_339_FWD_COMM2_AM",
"address_mask_shift_identifier": "MB_339_FWD_COMM2",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
}
},
"Seat": {
"SEAT_ADJ": {
"category": "Seat",
Expand Down
82 changes: 82 additions & 0 deletions Scripts/DCS-BIOS/doc/json/MB-339.jsonp
Original file line number Diff line number Diff line change
Expand Up @@ -14876,6 +14876,88 @@ docdata["MB-339"] =
"physical_variant": "toggle_switch"
}
},
"Radio Frequencies": {
"AFT_COMM1": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Aft COMM1",
"identifier": "AFT_COMM1",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33798,
"address_identifier": "MB_339_AFT_COMM1_A",
"address_mask_identifier": "MB_339_AFT_COMM1_AM",
"address_mask_shift_identifier": "MB_339_AFT_COMM1",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"AFT_COMM2": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Aft COMM2",
"identifier": "AFT_COMM2",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33806,
"address_identifier": "MB_339_AFT_COMM2_A",
"address_mask_identifier": "MB_339_AFT_COMM2_AM",
"address_mask_shift_identifier": "MB_339_AFT_COMM2",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"FWD_COMM1": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Forward COMM1",
"identifier": "FWD_COMM1",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33782,
"address_identifier": "MB_339_FWD_COMM1_A",
"address_mask_identifier": "MB_339_FWD_COMM1_AM",
"address_mask_shift_identifier": "MB_339_FWD_COMM1",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
},
"FWD_COMM2": {
"category": "Radio Frequencies",
"control_type": "radio",
"description": "Forward COMM2",
"identifier": "FWD_COMM2",
"inputs": [ {
"description": "The frequency to set, with or without a decimal place",
"interface": "set_string"
} ],
"outputs": [ {
"address": 33790,
"address_identifier": "MB_339_FWD_COMM2_A",
"address_mask_identifier": "MB_339_FWD_COMM2_AM",
"address_mask_shift_identifier": "MB_339_FWD_COMM2",
"description": "The current frequency the radio is set to",
"max_length": 7,
"suffix": "",
"type": "string"
} ]
}
},
"Seat": {
"SEAT_ADJ": {
"category": "Seat",
Expand Down
5 changes: 5 additions & 0 deletions Scripts/DCS-BIOS/lib/modules/aircraft_modules/MB-339.lua
Original file line number Diff line number Diff line change
Expand Up @@ -794,4 +794,9 @@ MB_339:defineBitFromDrawArgument("EXT_WOW_NOSE", 1, "External Aircraft Model", "
MB_339:defineBitFromDrawArgument("EXT_WOW_RIGHT", 4, "External Aircraft Model", "Weight ON Wheels Right Gear")
MB_339:defineBitFromDrawArgument("EXT_WOW_LEFT", 6, "External Aircraft Model", "Weight ON Wheels Left Gear")

MB_339:defineReadWriteRadio("FWD_COMM1", 6, 7, 3, 1000, "Forward COMM1")
MB_339:defineReadWriteRadio("FWD_COMM2", 7, 7, 3, 1000, "Forward COMM2")
MB_339:defineReadWriteRadio("AFT_COMM1", 9, 7, 3, 1000, "Aft COMM1")
MB_339:defineReadWriteRadio("AFT_COMM2", 10, 7, 3, 1000, "Aft COMM2")

return MB_339
Loading