Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ciribob committed Mar 21, 2022
1 parent c94cf4a commit bf8deb0
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions Scripts/DCS-SRS/Scripts/DCS-SimpleRadioStandalone.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1343,32 +1343,32 @@ function SR.exportRadioUH1H(_data)

local _panel = GetDevice(0)

local switch = _panel:get_argument_value(30)
local switch = _panel:get_argument_value(30)

if SR.nearlyEqual(switch, 0.1, 0.03) then
_data.selected = 0
elseif SR.nearlyEqual(switch, 0.2, 0.03) then
_data.selected = 1
elseif SR.nearlyEqual(switch, 0.3, 0.03) then
_data.selected = 2
elseif SR.nearlyEqual(switch, 0.4, 0.03) then
_data.selected = 3
else
_data.selected = -1
end

local _pilotPTT = SR.getButtonPosition(194)
if _pilotPTT >= 0.1 then

if _pilotPTT == 0.5 then
-- intercom
if SR.nearlyEqual(switch, 0.1, 0.03) then
_data.selected = 0
elseif SR.nearlyEqual(switch, 0.2, 0.03) then
_data.selected = 1
elseif SR.nearlyEqual(switch, 0.3, 0.03) then
_data.selected = 2
elseif SR.nearlyEqual(switch, 0.4, 0.03) then
_data.selected = 3
else
_data.selected = -1
end

_data.ptt = true
end
local _pilotPTT = SR.getButtonPosition(194)
if _pilotPTT >= 0.1 then

if _pilotPTT == 0.5 then
-- intercom
_data.selected = 0
end

_data.ptt = true
end

_data.control = 1; -- Full Radio
_data.control = 1; -- Full Radio


_data.capabilities = { dcsPtt = true, dcsIFF = true, dcsRadioSwitch = true, intercomHotMic = true, desc = "Hot mic on INT switch" }
Expand Down

0 comments on commit bf8deb0

Please sign in to comment.