SimForums.com Homepage
Forum Home Forum Home > Flight One Software Forums > BN-2 Islander Forum
  New Posts New Posts RSS Feed - Generator Voltage Lamps for hardware cockpit
  FAQ FAQ  Forum Search   Register Register  Login Login

Generator Voltage Lamps for hardware cockpit

 Post Reply Post Reply
Author
Message
Rich_Cooke View Drop Down
New Member
New Member


Joined: June-03-2013
Location: UK
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rich_Cooke Quote  Post ReplyReply Direct Link To This Post Topic: Generator Voltage Lamps for hardware cockpit
    Posted: June-03-2013 at 2:03pm
Love the Flight1 Islander. A fantastic achievement. Was lucky enough to fly in a real one in the Shetland Islands last year and the sounds and "feel" of the FSX version are incredibly accurate in my view. My wife was in another room but recognised what it was immediately just from hearing it!

I am flying with a (home made) hardware cockpit. I would like to replicate the operation of the port and starboard Generator Voltage lamps (Using an Open Cockpits output card and leds) I have just about all the other indicators working but I am having trouble identifying which SimConnect Variable/FSUIPC Offset is behind the operation of the port and starboard Generator Voltage lamps. I am trying to work out which values illuminate/extinguish these lights so I can emulate that in my hardware panel set up. I have tried using FSUIPC logging. It looks like it should be Offsets "2880/2890 8 Generator alternator 1/2 bus voltage" for both engines but if I monitor these it stays at zero throughout during the start up process. Hope someone can help me sort this out. Its the last piece of my jigsaw!

Thanks Rich Cooke
Back to Top
Rich_Cooke View Drop Down
New Member
New Member


Joined: June-03-2013
Location: UK
Points: 13
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rich_Cooke Quote  Post ReplyReply Direct Link To This Post Posted: June-05-2013 at 1:35pm
Well amazingly after many months of niggling away at this I've solved it. The offsets in my original post are correct and they move from 0% (lights on) to 28% (lights off). The only issue I have now is that the lights illuminate when the aircraft is cold and dark before the battery is put on. So I now have to learn to do a bit more complex programming so they are off when the battery is off. It looks like this is a very minority interest but I thought I would post that its solved in case anyone else ever wants to do the same.

Rich Cooke
Back to Top
hovercrafter View Drop Down
New Member
New Member


Joined: April-17-2009
Location: United Kingdom
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote hovercrafter Quote  Post ReplyReply Direct Link To This Post Posted: October-27-2013 at 4:51pm
Hello Rich. I have a makeshift cockpit for the BN2 and the offsets data you list is very helpful.

My contribution to this thread is;
offset byte togglebits x08b2 param x01 = carb heat levers

Also, I use a Go-flight GFP8 circuit board to run annunciator lights. In the GFP8 ini file I use x08ba=0 U16 #*55/16384 Its a kludge but does switch oil pressure warning lights on when the engine stops. (generic offset works on all of my hanger)

Can't get FSUIPC mouse macros to work on the radio's... anybody got some offsets or L.vars I could use?

Regards to all BN2'ers
Gordon
Back to Top
HS748 View Drop Down
New Member
New Member


Joined: August-23-2013
Location: BC, Canada
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote HS748 Quote  Post ReplyReply Direct Link To This Post Posted: November-18-2013 at 5:27pm
I believe that there is a LUA file that logs L:Vars in FSUIPC. I use it all the time, but it's hard to explain how to use. I'll see if I can find the tutorial for it.
Back to Top
hovercrafter View Drop Down
New Member
New Member


Joined: April-17-2009
Location: United Kingdom
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote hovercrafter Quote  Post ReplyReply Direct Link To This Post Posted: November-19-2013 at 2:41am
Thank you HS748 - that would be very helpful. I am only just beginning having a go with Lua so all guidance is appreciated.

Gordon
Back to Top
HS748 View Drop Down
New Member
New Member


Joined: August-23-2013
Location: BC, Canada
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote HS748 Quote  Post ReplyReply Direct Link To This Post Posted: November-19-2013 at 10:52am
You won't need any Lua knowledge for this, it's a script that can be mapped to a key press.
Back to Top
HS748 View Drop Down
New Member
New Member


Joined: August-23-2013
Location: BC, Canada
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote HS748 Quote  Post ReplyReply Direct Link To This Post Posted: November-19-2013 at 10:59am
But bear in mind that I don't have the BN2, so I don't know if there's any XML in it. LVars only correspond to XML stuff.
Back to Top
HS748 View Drop Down
New Member
New Member


Joined: August-23-2013
Location: BC, Canada
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote HS748 Quote  Post ReplyReply Direct Link To This Post Posted: November-19-2013 at 1:57pm
Back to Top
hovercrafter View Drop Down
New Member
New Member


Joined: April-17-2009
Location: United Kingdom
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote hovercrafter Quote  Post ReplyReply Direct Link To This Post Posted: November-20-2013 at 2:16am
Many thanks for that link HS748

kind regards
Gordon
Back to Top
hovercrafter View Drop Down
New Member
New Member


Joined: April-17-2009
Location: United Kingdom
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote hovercrafter Quote  Post ReplyReply Direct Link To This Post Posted: November-20-2013 at 6:34am
Got there in the end.... Used Linda to find the L:Vars.   All this is new to me so if any mistakes please advise.

For anyone using FSUIPC but doesn't yet use Lua - copy & paste the following code into Notepad - save as (say) BN2.lua in the modules folder of FSX. In FSUIPC select the button you want to assign then in the function list scroll down until you find Lua:BN2 select and use the parameter number from below.

-- Items for Brittain Norman BN2

-- Parameters

-- 1  = Com1 Toggle (na)
-- 10 = Com1 Off (0)
-- 11 = Com1 On (1)

-- 4  = Adf Power Toggle (na)
-- 40 = ADF Power Off (0)
-- 41 = ADF Power On (1)

-- 5  = Transponder Toggle (na)
-- 57 = Transponder Sequential
-- 58 = Transponder Knob Clockwose
-- 59 = Transponder Knob Anti-Clockwise

-- 60 = DME Off (0)
-- 67 = DME Sequential



-- -- -- -- -- -- -- Com1 -- -- -- -- -- -- --

if ipcPARAM == 1 then -- Toggle
        LVarSet = "L:x3d_asbn2_avs_kx155_power"
        val = 0
if ipc.readLvar(LVarSet) == 0  then
val = 1
end
        ipc.writeLvar(LVarSet, val)
end
if ipcPARAM == 10 then -- Off
ipc.writeLvar("L:x3d_asbn2_avs_kx155_power", 0)
end
if ipcPARAM == 11 then -- On
ipc.writeLvar("L:x3d_asbn2_avs_kx155_power", 1)
end



-- -- -- -- -- -- -- ADF -- -- -- -- -- -- --

if ipcPARAM == 4 then -- Toggle
LVarSet = "L:x3d_asbn2_avs_kr87_adf1_power"
val = 0
if ipc.readLvar(LVarSet) == 0  then
val = 1
end
ipc.writeLvar(LVarSet, val)

        LVarSet = "L:x3d_asbn2_avs_kr87_adf2_power"
val = 0

if ipc.readLvar(LVarSet) == 0  then
val = 1
end

ipc.writeLvar(LVarSet, val)
end
if ipcPARAM == 40 then -- Off
ipc.writeLvar("L:x3d_asbn2_avs_kr87_adf1_power", 0)
ipc.writeLvar("L:x3d_asbn2_avs_kr87_adf2_power", 0)
end
if ipcPARAM == 41 then -- On
ipc.writeLvar("L:x3d_asbn2_avs_kr87_adf1_power", 1)
ipc.writeLvar("L:x3d_asbn2_avs_kr87_adf2_power", 1)
end

-- -- -- -- -- -- Transponder -- -- -- -- -- --

if ipcPARAM == 5 then -- Toggle (Off/On)
LVarSet = "L:x3d_asbn2_avs_xpndr_mode"
val = 0
if ipc.readLvar(LVarSet) == 0  then
val = 3
end
ipc.writeLvar(LVarSet, val)
end
if ipcPARAM == 57 then -- Sequential
LVarSet = "L:x3d_asbn2_avs_xpndr_mode"
if ipc.readLvar(LVarSet) == 0  then
val = 1
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 1  then
val = 2
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 2  then
val = 3
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 3  then
val = 4
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 4  then
val = 0
ipc.writeLvar(LVarSet, val)
end
end

if ipcPARAM == 58 then -- Knob Clockwise
LVarSet = "L:x3d_asbn2_avs_xpndr_mode"
if ipc.readLvar(LVarSet) == 0  then
val = 1
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 1  then
val = 2
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 2  then
val = 3
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 3  then
val = 4
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 4  then
val = 0
ipc.writeLvar(LVarSet, val)
end
end
if ipcPARAM == 59 then -- Knob Anti-Clockwise
LVarSet = "L:x3d_asbn2_avs_xpndr_mode"
if ipc.readLvar(LVarSet) == 5  then
val = 4
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 4  then
val = 3
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 3  then
val = 2
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 2  then
val = 1
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 1  then
val = 0
ipc.writeLvar(LVarSet, val)
end
end

-- -- -- -- -- -- -- DME -- -- -- --  -- -- --

if ipcPARAM == 60 then -- Toggle
        LVarSet = "L:x3d_asbn2_avs_kn54_power"
        val = 0
if ipc.readLvar(LVarSet) == 0  then
val = 1
end
        ipc.writeLvar(LVarSet, val)
end
if ipcPARAM == 67 then -- Sequential
LVarSet = "L:x3d_asbn2_avs_kn54_power"  -- switch on unit
if ipc.readLvar(LVarSet) == 0 then
val = 1
ipc.writeLvar(LVarSet,val)
end
LVarSet = "L:x3d_asbn2_avs_kn54_mode"   -- select modes
if ipc.readLvar(LVarSet) == 0  then
val = 1
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 1  then
val = 2
ipc.writeLvar(LVarSet, val)
elseif ipc.readLvar(LVarSet) == 2  then
val = 0
ipc.writeLvar(LVarSet, val)
end
end

-- End Of File

Back to Top
Robs View Drop Down
New Member
New Member


Joined: April-12-2018
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Robs Quote  Post ReplyReply Direct Link To This Post Posted: April-12-2018 at 7:18pm
Hi there,

I am using Spad next and trying to set up a control set.
Do you now how to access the LNAV switch on the autopilot.
I have no fsuipc experience or LUA experience (or a reg'd copy even) so I need a walkthru!
Who's linda? Does this module interfere with spad.next? 
 Help!
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.01
Copyright ©2001-2018 Web Wiz Ltd.

This page was generated in 0.107 seconds.