kdlovell
-
Posts
6 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Gallery
Downloads
Posts posted by kdlovell
-
-
TESTED: Works like a charm!
Thanks Pete
Keith
-
Thanks! I'll be testing this out tonight after work.
Keith
-
Thank you Pete, I appreciate the confirmation that I am not crazy after all! I couldn't understand why I was having issues after reading through the forums for hours trying to figure this out.
Once again you have proven your legendary status in the sim community :)
Thanks,
Keith
-
Hi Peter,
Thanks for the response. I should have mentioned that the reason I am trying to accomplish this is so that a virtual airline acars system can read the taxi light from FSUIPC when the Aerosoft Airbus is used.
I created a simpler example and turned on the logging as you suggested:
Sim: FSX Steam Edition
FSUIPC: 4.949
Aircraft: Default 737-800
Steps:
1) Load Aircraft and turn on all lights except taxi light
2) Run Lua script
Result: Taxi light turns on and all other lights turn off
Expected Result: Taxi light turns on and all others remain as is
Lua Script:
ipc.sleep(100)ipc.display("Turning on Taxi Light...")ipc.sleep(2000)ipc.setbitsUW(0x0D0C, 8)ipc.display("Done")ipc.sleep(2000)Lua Debug Log:********* LUA: "test" Log [from FSUIPC version 4.949] *********156203 System time = 13/01/2016 08:16:01, Simulator time = 11:14:15 (16:14Z)156203 LUA: beginning "D:\Program Files (x86)\Steam\steamapps\common\FSX\Modules\test.lua"160421 LUA: ended "D:\Program Files (x86)\Steam\steamapps\common\FSX\Modules\test.lua"160421 System time = 13/01/2016 08:16:06, Simulator time = 11:14:19 (16:14Z)********* LUA execution terminated: Log Closed *********FSUIPC Log:********* FSUIPC4, Version 4.949 by Pete Dowson *********fsx.exe version = 10.0.62615.0Reading options from "D:\Program Files (x86)\Steam\steamapps\common\FSX\Modules\FSUIPC4.ini"Running inside FSX Steam Edition on Windows 8.0Module base=55FF0000User Name="Keith Lovell"User Addr="keithlovell@metrocast.net"FSUIPC4 Key is providedWideFS7 Key is provided62 System time = 13/01/2016 08:13:2562 FLT UNC path = "C:\Users\Keith\Documents\Flight Simulator X Files\"62 ------ Module Version Check ------62 acontain.dll: 10.0.62615.062 api.dll: 10.0.62615.062 controls.dll: 10.0.62615.062 fs-traffic.dll: 10.0.62615.062 G3D.dll: 10.0.62615.062 sim1.dll: 10.0.62615.062 visualfx.dll: 10.0.62615.062 weather.dll: 10.0.62615.062 window.dll: 10.0.62615.062 ----------------------------------93 Trying to connect to SimConnect Steam ...93 FS UNC path = "D:\Program Files (x86)\Steam\steamapps\common\FSX\"390 ---------------------- Joystick Device Scan -----------------------390 -------------------------------------------------------------------406 LogOptions=00000000 00000001406 -------------------------------------------------------------------406 ------ Setting the hooks and direct calls into the simulator ------406 --- CONTROLS timer memory location obtained ok406 --- SIM1 Frictions access gained406 --- FS Controls Table located ok406 --- Installed Mouse Macro hooks ok.406 --- Wind smoothing fix is fully installed406 --- All links checked okay406 -------------------------------------------------------------------406 SimConnect_Open succeeded: waiting to check version okay406 Trying to use SimConnect Steam4015 Running in "Microsoft Flight Simulator X", Version: 10.0.62615.0 (SimConnect: 10.0.62615.0)4015 Initialising SimConnect data requests now4015 FSUIPC Menu entry added4031 D:\Program Files (x86)\Steam\steamapps\common\FSX\flights\other\FLTSIM.FLT4031 D:\Program Files (x86)\Steam\steamapps\common\FSX\SimObjects\Airplanes\Aircreation_582SL\Aircreation_582SL.air7453 Weather Mode now = Theme21765 D:\Program Files (x86)\Steam\steamapps\common\FSX\SimObjects\Airplanes\B737_800\Boeing737-800.air59000 Aircraft="Boeing 737-800 Paint1"59000 System time = 13/01/2016 08:14:24, Simulator time = 11:13:32 (16:13Z)66078 Starting everything now ...82781 Advanced Weather Interface Enabled129703 LogOptions changed, now 80000000 00000001129718 Monitor IPC:0D0C (U16) = 2144109 Monitor IPC:0D0C (U16) = 6144109 SimRead: 0D0C="LIGHT LANDING"INT32: 1 (0x00000001)148093 Monitor IPC:0D0C (U16) = 262148093 SimRead: 0D0C="LIGHT LOGO"INT32: 1 (0x00000001)150093 Monitor IPC:0D0C (U16) = 278150093 SimRead: 0D0C="LIGHT STROBE"INT32: 1 (0x00000001)158375 Monitor IPC:0D0C (U16) = 8 <================ This is where the Lua script was run164937 Sim stopped: average frame rate for last 35 secs = 92.3 fps168671 System time = 13/01/2016 08:16:14, Simulator time = 11:14:23 (16:14Z)168671 *** FSUIPC log file being closedMinimum frame rate was 75.8 fps, Maximum was 122.2 fpsMinimum available memory recorded was 3015MbAverage frame rate for running time of 51 secs = 99.7 fpsMemory managed: 27 Allocs, 27 Freed********* FSUIPC Log file closed ***********Thank you again for your time.Keith -
Hello,
I have been reading through the forums on how to toggle the lights in the 0D0C offset. My goal is to use a lua event to appropriately set the taxi light based on the Aerosoft Airbus Lvar. I understand each light is controlled by a separate bit and normally this would be done using AND and OR logic. However, based on what I have been reading in the forums and the Lua Library doc, the setbitsUW and clearbitsUW should work in place of using the AND and OR logic. Unfortunately, in all of my testing it seems to reset all of the other light offsets rather than just operate on the taxi light. I have also tested a one line script using setbitsUW to toggle the taxi light in the default 737 with the same result.
Am I using the code below incorrectly? Do I need the AND and OR logic when using the setbitsUW and clearbitsUW
-- set the pollrate to 250ms = 4 times per secondpollrate = 250function writeTaxi(varname, value)if value == 1 thenipc.setbitsUW(0x0D0C, 8)elseipc.clearbitsUW(0x0D0C, 8)endend-- create an event listener to monitor the LVAR-- this will call the function above when the LVAR changes-- Aerosoft Airbus Taxi Lightevent.Lvar("L:AB_TAXI_LT", pollrate, "writeTaxi")Thank You
Toggle Taxi Light with Lua Script
in FSUIPC Support Pete Dowson Modules
Posted
Hi Pete,
Do you have an idea when this version of FSUIPC will be released on the download page? I'm just planning my code updates to line up with the new version's availability.
Thanks,
Keith