Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Landing lights switch

Featured Replies

Does anybody know how to assign landing/taxi lights switch to joystick button or keyboard shortcut?

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

Not tested. but you should be able to assign Ctrl-L to a joystick button. You'll need FSUIPC registered version for this.

  • Author

Not tested. but you should be able to assign Ctrl-L to a joystick button. You'll need FSUIPC registered version for this.

The main problem is that switch has 3 positions: up (landing)/middle(off)/down(taxi). I'd like to switch this positions with two buttons, i.e ctrl-PgUp/ctrl-PgDn.

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

Your question got me thinking about how to do this.  I don't have the Citation but I have the Carenado Phenom 100.  It has a three position landing / taxi light switch but slightly different (DN - OFF, CTR - Taxi Lt, UP - Ldg Lt).  So I wrote a short LUA file with two scripts:  one to move the switch up one position and one to move the switch down one position.  I set the LVar so that the VC switch moves correctly and manipulate the landing and taxi lights through the 0D0C offset.  The LUA file goes in the Modules folder with FSUIPC (need the paid version) and I assign the LUA file as a FS command in FSUIPC, to a two position rocker switch on my throttle quadrant with the parameter "1" for UP and "2" for DN.  It could be assigned to a keypress just as easily.  I'm not a P3D guy so I don't know if it will work there but here is my script.  If you need help finding the Citation LVar for the switch or modifying the script for the Citation, let me know.
Bruce
--------------------------------------------
-- Phenom Landing_Taxi Lights Scripts
--------------------------------------------

--------------------------------------------
-- Parameters by Number
--------------------------------------------
-- 1 Move Ldg_Taxi Lt SW UP one position
-- 2 Move Ldg_Taxi Lt SW DN one position

--------------------------------------------
---- Variables
--------------------------------------------
SW_Pos = "L:ASD_SWITCH_LANDING_TAXI_EMB500"

--------------------------------------------
---- Scripts
--------------------------------------------

-- Move Ldg_Taxi Lt SW UP one position
if ipcPARAM == 1 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == 0 then
ipc.writeLvar(SW_Pos, 1)
ipc.setbitsUW(0x0D0C, 8)
end
if SWPos == 1 then
ipc.writeLvar(SW_Pos, 2)
ipc.setbitsUW(0x0D0C, 4)
ipc.clearbitsUW(0x0D0C, 8)
end
end

-- Move Ldg_Taxi Lt SW DN one position
if ipcPARAM == 2 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == 2 then
ipc.writeLvar(SW_Pos, 1)
ipc.setbitsUW(0x0D0C, 8)
ipc.clearbitsUW(0x0D0C, 4)
end
if SWPos == 1 then
ipc.writeLvar(SW_Pos, 0)
ipc.clearbitsUW(0x0D0C, 8)
end
end

[CPL]  I9-9900K @5.0GHz HT ON, Maximus XI Hero, ASUS TUF RTX4080 OC, 32GB DDR4 3200 14, 1TB NVMe SSD, 500GB SSD, 1TB HDD, 40" Samsung 4K TV, Honeycomb Alpha & Bravo, Logitech Rudder Pedals, WIN11

  • Author

Bruce, a lot of thanks for your respond. I owe Carenado E50P too so I've tested your script and it works completly as I wished. Now can you tell me how to make it work in CJ2?

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

  • Author

It seems I found the solution myself using my genius mind :)

This is lua script I got:

 

--------------------------------------------
-- Carenado CJ2+ Landing_Taxi Lights Scripts
--------------------------------------------
 
--------------------------------------------
-- Parameters by Number
--------------------------------------------
-- 1 Move Ldg_Taxi Lt SW UP one position
-- 2 Move Ldg_Taxi Lt SW DN one position
 
--------------------------------------------
---- Variables
--------------------------------------------
SW_Pos = "L:ASD_SWITCH_CJ2525A_LAND_TAXI_RECOG"
 
--------------------------------------------
---- Scripts
--------------------------------------------
 
-- Move Ldg_Taxi Lt SW UP one position
if ipcPARAM == 1 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == 0 then
ipc.writeLvar(SW_Pos, 1)
ipc.clearbitsUW(0x0D0C, 8)
end
if SWPos == 1 then
ipc.writeLvar(SW_Pos, 2)
ipc.setbitsUW(0x0D0C, 4)
end
end
 
-- Move Ldg_Taxi Lt SW DN one position
if ipcPARAM == 2 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == 2 then
ipc.writeLvar(SW_Pos, 1)
ipc.clearbitsUW(0x0D0C, 4)
end
if SWPos == 1 then
ipc.writeLvar(SW_Pos, 0)
ipc.setbitsUW(0x0D0C, 8)
end
end

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

Great! Glad I could help.

For any others that use this, beware that you need FSUIPC 4949e (I think that was the fix version but not positive) or later (latest is best). Before the fix, using this script would clear all other light bits when setting or clearing the targeted bit.
Bruce

 

EDITED:  I forgot to mention an "improvement" on the E50P scripts is to use the clearbitsUW before the setbitsUW in the two instances where they are together in order to turn off a light before turning the other one on.  Otherwise you get a momentary flash that is both light masks being on at the same time.

[CPL]  I9-9900K @5.0GHz HT ON, Maximus XI Hero, ASUS TUF RTX4080 OC, 32GB DDR4 3200 14, 1TB NVMe SSD, 500GB SSD, 1TB HDD, 40" Samsung 4K TV, Honeycomb Alpha & Bravo, Logitech Rudder Pedals, WIN11

  • Author

I mentioned now that my switches turn ALL lights off somehow. I cannot fix it yet. My genious mind :) stucks.

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

Did you update FSUIPC to 4949h? If you have earlier than 4949c it will turn off all other lights.

[CPL]  I9-9900K @5.0GHz HT ON, Maximus XI Hero, ASUS TUF RTX4080 OC, 32GB DDR4 3200 14, 1TB NVMe SSD, 500GB SSD, 1TB HDD, 40" Samsung 4K TV, Honeycomb Alpha & Bravo, Logitech Rudder Pedals, WIN11

  • Author

Yes! Update to 4.949k solved simultaneous lights toggling. And I rewrite lua code using togglebits command so the final version looks like this:

 

SW_Pos = "L:ASD_SWITCH_CJ2525A_LAND_TAXI_RECOG"
-- Move Ldg_Taxi Lt SW UP one position
if ipcPARAM == 1 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == -1 then
ipc.writeLvar(SW_Pos, 0)
ipc.togglebitsUW(0x0D0C, 8)
end
if SWPos == 0 then
ipc.writeLvar(SW_Pos, 1)
ipc.togglebitsUW(0x0D0C, 4)
end
end
-- Move Ldg_Taxi Lt SW DN one position
if ipcPARAM == 2 then
SWPos = ipc.readLvar(SW_Pos)
if SWPos == 1 then
ipc.writeLvar(SW_Pos, 0)
ipc.togglebitsUW(0x0D0C, 4)
end
if SWPos == 0 then
ipc.writeLvar(SW_Pos, -1)
ipc.togglebitsUW(0x0D0C, 8)
end
end
 
 
 
P.S. God damn it! I'm becoming programist via my simmer way!

Artem Titov

RusJet VA captain

2014_12_13_08_40_06_6038.gif?6652

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.