
ark1320
Members-
Posts
670 -
Joined
-
Last visited
-
Days Won
17
Content Type
Profiles
Forums
Events
Gallery
Downloads
Everything posted by ark1320
-
Ah, a great tip -- thanks! Al
-
Pete, In regard to my second post above about NO display after reinstalling P3Dv4, the solution to the problem was I needed to check the Message Text box found on the P3Dv4 Information Tab under MISCELLANEOUS TEXT. That little detail has cost me many many hours of grief, so I hope this helps someone! Regarding my first post above, I have found the best temporary solution is to grab and reposition/resize the SimConnect Msg window as I want it and leave it there for all Lua scripts to use. I have temporarily commented out all the ipc.setdisplay() commands from the scripts. This is not an ideal solution, but better than what I had. And if you ever find a way to have more than one window active at a time, that would be great! I really miss having that capability. Thanks very much for your efforts with this difficult display issue. Al
-
Pete, Another problem related to the issue of display in P3Dv4 as described above: After reinstalling P3Dv4 and FSUIPC5 (after a Win10 update caused problems), I not getting any Lua script displays at all on the screen (not the green bar or the simconnect message window) even though the Lua scripts are running . For example, I have a script that moves an aircraft after asking the user to input information like new heading, distance to move, etc, using the ipc.ask() function. Even though there is no display as expected as a result of the ipc.ask() functions, the aircraft does move as expected based on the inputs I provide "in the blind". And these scripts have all been used in FSX for a long time. I had the exact same problem the first time I installed P3Dv4 and FSUIPC5 and after a day of struggles the problem went away but I don't know why ( have not been so lucky this time). The issue seems to have to do with somehow initializing the simconnect message window location and size in order to get a display on the screen. Al
-
Hi Pete, Many of my Lua scripts make extensive use of the setowndisplay() command and now that this command does not work in P3Dv4 as it previously did, I am trying to find alternatives to the extent possible. As a first step I'm trying to understand how the ipc.setdisplay() command works with the 'common use' P3D4 simconnect message display window. When I run the small test script below with a keystroke, the display window is not in the location or the size that I expect. I understand ipc.setdisplay parameters are percentages relative to a display window, but what window? Do the percentages apply to the previous window even after it has been closed? Do I perhaps need to somehow reset the P3D4 simconnect display window location and size (e.g., to 'full screen size') before setting it to the size I need? Clearly there is something basic I don't understand about initializing and controlling the common simconnect message window location and size. In addition, when I ran the script below I got the 'dual' display (green bar and the little simconnect msg window) shown below as expected. But if I comment out the ipc.writeSTR() and ipc.writeSW() lines, I get no display at all. It is as if the green bar string display is also triggering the simconnect msg window display somehow. Without that trigger there is no simconnect window display. Also note the ipc.getdisplay() returns a sy window size of 50 vs 60 for some reason. If I change the simconnect location parameters from 100, 100 to 50, 50, the little display window moves about an inch to the left and an inch up on the screen. Test script: ipc.setdisplay (100, 100, 40, 60) ipc.display ("TEST") state, x,y, sx, sy = ipc.getdisplay() ipc.writeSTR(0x3380, state..x..y..sx..sy) ipc.writeSW(0x32FA, 10) ipc.sleep (10000) ipc.display ("") return Thanks for your help, Al FSUIPC 5.14 Win10, P3Dv4.3 Edited with new information
-
Landing_Params is a Lua script for FSX/P3D that displays landing parameters in a small text window that pops up after the aircraft has landed and has slowed to taxi speed. The script should be activated with a key or button (like the gear down key/button) during the approach to landing. Parameters displayed in the window at touchdown are Indicated Airspeed (IAS, Kts), Ground Speed (GS, Kts), Landing Distance (LD, ft), Landing Roll (LR, ft), Vertical Speed (VS, ft/min), Attitude Indicator pitch at touchdown (AI), and Bounce Count (BC). Data collection begins when the a/c passes through a radar altimeter determined threshold altitude window between 45 and 55 ft (i.e., the nominal 50ft threshold height). In addition, more detailed landing parameter information may also be logged. May not display correctly with P3Dv4 due to Lua display limitations. Documentation included. Landing ParamsFiles.zip
-
Approach CallOuts consists of two Lua scripts and a sound folder with wav files that work together to provide altitude, gear and flap settings, and approach minimums (Decision Height) audio callouts on an approach to landing. The altitude callouts are at Radio Altimeter (RA) heights of 2000, 1000, 500, 400, 300, 200, 100, 50, 40, 30, 20, and 10 ft. At 800ft RA (a user settable value) you get a callout of current flap and gear positions. There is no gear callout if the aircraft has a fixed gear. The minimums callout may be based on a RA or BARO (MSL) altitude. May not display correctly with P3Dv4 due to Lua display limitations. Documentation included. ApproachCallOut2Files.zip
-
- 1
-
-
Pete -- thanks very much for the detailed answer. Al
-
Hi Pete, Is my understanding below correct? If a key assignment is made using Lua ScriptName under the FSUIPC Key assignments tab, then when that key is pressed the Lua file ScriptName is loaded and run. In contrast to this, if a key assignment is made using LuaToggle ScriptName along with a Parameter field entry (flag number), then when the key is pressed the associated flag value is toggled, but that is all, the script ScriptName is not loaded and run at that point due to the key stroke. So if ScriptName is to detect and process the changed flag value, [e.g., by using event.flag( ) ], ScriptName must of previously been loaded and run such as by listing it under an [Auto] section in the FSUIPC.ini file. Thanks, Al
-
Hi Pete, Is it correct to say that each Lua plug-in has its own set of 256 flags to be independently manipulated and tested? BTW, there seems to be a minor typo in the event.flag() documentation: "If no flag number (0 – 256 255) is provided, any of the 256 changing will trigger the event. Otherwise only the selected flag will do so." Thx, Al
-
OK, I see. And if the only condition you were trying to detect was a change in the offset value, rather then a particular offset value, you would need to identify the first call to the function associated with event.offset() and handle that as a special case. Thx, Al
-
Hi Pete, In the documentation for event.offset() it says: The function is also executed initially, when the plugin is first run, in order to initialise things. This saves using an explicit call to do the same. Q1. Does this mean, for example, if the purpose of the called function is to terminate the script with an ipc.exit() command when the value in the offset changes, the script will be immediately terminated because the function is executed automatically when the script is first run even though the offset value has not changed? Q2. If execution of the script has been suspended with an ipc.sleep() command, will a change in the offset being monitored by event.offset() be missed or ignored? In other words, does ipc.sleep() also suspend the action of the event.offset() command? Thanks, Al
-
Strange Multi-line Display Issue
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Hi Pete, Perhaps a bit of encouraging news is I've discovered that FSX-SE, which is on the same computer as FSX, does not have the display problem described above. So there is some hope regarding the impact of the latest WIN10 update. I now need to see if I can figure out what might be different between FSX and FSX-SE as far as how the Lua displays are being handled by the system. Al -
Strange Multi-line Display Issue
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
If anyone else has a similar issue, please let me know. I'd like to determine it this Lua display problem is unique to my setup for some reason. Thx, Al -
Strange Multi-line Display Issue
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Pete, In each case all the multi-line data is sent for display with one command that contains the new line characters. For example, in one script we have: if on_ground_flag == 1 then v_rotate = v_rotate_calc() -- call function ipc.display(" Vr = "..v_rotate.."\n Reversers Armed\n Annunciator Lights\n AP Set\n Altitude Set\n Spoilers Off\n Flaps Set\n Trim Set\n Yaw Damper Off\n Lights On\n Heading Bug Set\n Course Set\n Altimeter Set\n NAV/GPS Set\n Pitot Heat On") -- Display check list for TO_list_time sec repeat ias = ipc.readUD(0x02BC)/128 -- IAS in Knots ias = math.floor (ias + 0.5) -- round to no decimal places (nearest integer) until ias >= v_rotate - rotate_callout_gs_delta -- rotate callout is initiated rotate_callout_gs_delta knots before the v_rotate speed is reached ref=sound.play("Rotate",0) -- Rotate callout ipc.display("") -- close takeoff checklist window end Another script displays a menu using ipc.ask: aircraft_sel=ipc.ask(tab.."Select (followed by Enter): \n 1 FSX Default or Std Add-on A/C\n 2 A2A Cherokee 180\n 3 FLIGHT1 KA B200\n 4 PMDG B737 NGX\n 5 PMDG B777\n * NpC Off",1) So I need to figure out what has changed because neither of these scripts previously exhibited the behavior I described above, but do now. The scripts themselves have not been changed. I'm beginning to think the problem is related to the Win10 update -- perhaps how it works with SimConnect. Should I try reinstalling SimConnect? Thanks, Al -
Hi Pete, A strange problem has popped up when using Lua scripts to display multiple lines. This is happening with different scripts that previously had no display problems, and happens with both green bar and ipc.setowndisplay type display windows. Instead of the data just appearing 'smoothly', there is jitter as the multiple lines are displayed (single lines display fine). I am only talking about 10 or so short lines of information. I get the sense there is a tiny delay between the display of each line, but once all the lines are displayed, the window display is stable. With the green bar multi-line display, I can faintly see individual single green lines as the window grows in size vertically as the lines are displayed. I don't know how the multi-line display functions work but wonder if something could be causing the scripts to pause for a tiny fraction of a second between the display of each line, or perhaps something has slowed the overall execution speed of the scripts enough to produce this effect? I apologize for this description of the problem -- just don't know a better way to put it. I did 'suffer' a recent Win10 update, but don't see any other display issues with the computer, and can't be sure if this only started after the update. The Nvidia GPU driver is up to date. Thanks for any ideas on what I might check or look for. Al FSUIPC 4.972 Boxed FSX, Win10/64
-
Hi Pete, In general, does FSUIPC update offset values (such as airspeed, altitude, flight control positions, radar altitude, etc) from FSX at the sim rate (about 18Hz), or only when a particular offset is accessed via one of the ipc.read commands, or perhaps only when FSUIPC detects an offset value has changed? Thanks, Al
-
Hi Pete, Does the ipc.display and setowndisplay combination work in P3Dv4? I recall there have been some issues with this in the past. I'm trying to help a friend but unfortunately don't have P3D myself for testing. Scripts I've written using ipc.display that work in FSX on my friend's machine are not displaying anything in P3Dv4. Thanks for an update on this, Al
-
ipc.setowndisplay window transparency question
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
I forgot to mention I'm using the boxed FSX, but it sounds like in this case the answer is the same regardless of which sim is being used. Thanks for the response, Al -
Offset Value for Retractable Gear
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Yes, a good lesson! Thanks very much for the help. Al -
Offset Value for Retractable Gear
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Hi Pete, Below is information from the FSUIPC4.LOG files for the Baron 58 and B737. Al Baron B58 1141 SimConnect_Open succeeded: waiting to check version okay 1141 Trying to use SimConnect Acc/SP2 Oct07 1141 Opened separate AI Traffic client okay 3563 Running in "Microsoft Flight Simulator X", Version: 10.0.61472.0 (SimConnect: 10.0.61259.0) 3563 Initialising SimConnect data requests now 3563 FSUIPC Menu entry added 3594 C:\Users\Al\Documents\Flight Simulator X Files\Default Safe Flight Baron 58 35L KCOS.FLT 3594 C:\FSX\SimObjects\Airplanes\Beech_Baron_58\Beech_Baron_58.AIR 4219 Monitor IPC:060C (U8) = 0 50313 Aircraft loaded: running normally now ... 50313 User Aircraft ID 1 supplied, now being used 50641 System time = 18/10/2017 16:30:02, Simulator time = 11:49:47 (17:49Z) 50641 Monitor IPC:060C (U8) = 2 50641 SimRead: 060C="IS GEAR RETRACTABLE" INT32: 2 (0x00000002) 51406 Aircraft="Beech Baron 58 EPAV" 51641 Starting everything now ... 51719 ASN active function link set 51719 Ready for ActiveSky WX radar with additional data B737 1109 SimConnect_Open succeeded: waiting to check version okay 1109 Trying to use SimConnect Acc/SP2 Oct07 1109 Opened separate AI Traffic client okay 3609 Running in "Microsoft Flight Simulator X", Version: 10.0.61472.0 (SimConnect: 10.0.61259.0) 3609 Initialising SimConnect data requests now 3609 FSUIPC Menu entry added 3625 C:\Users\Al\Documents\Flight Simulator X Files\Default Safe Flight Baron 58 35L KCOS.FLT 3625 C:\FSX\SimObjects\Airplanes\Beech_Baron_58\Beech_Baron_58.AIR 4297 Monitor IPC:060C (U8) = 0 59859 C:\FSX\SimObjects\Airplanes\B737_800_Default_Modified\Boeing737-800.AIR 139719 User Aircraft ID 1 supplied, now being used 140015 System time = 18/10/2017 16:40:14, Simulator time = 11:49:47 (17:49Z) 140015 Monitor IPC:060C (U8) = 2 140015 SimRead: 060C="IS GEAR RETRACTABLE" INT32: 2 (0x00000002) 140797 Aircraft="Boeing 737-800 EPAV" 141000 Starting everything now ... 141094 ASN active function link set 141094 Ready for ActiveSky WX radar with additional data 141156 Plug-in thread table check: -
Offset Value for Retractable Gear
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Pete, The default a/c I tried were the Baron 58 and the B737. Al -
Offset Value for Retractable Gear
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
Yes, I get the value 2 for a number of different default and add-on a/c. I guess as you say it is a case of non 0 means true. I'll be careful to code accordingly in the future. I don't know how I managed to post in the wrong forum this time -- sorry. Thanks for the help, Al -
Hi Pete, When debugging some code I found that when reading offset 060C with ipc.readUB(0x060C) for an a/c with a retractable landing gear the value returned was 2 instead of 1 as specified in the offset documentation. Is this just a simple documentation typo, or perhaps is there some additional significance (some characteristic of the landing gear) associated with the "2" versus the "1" ? With a fixed gear a/c the value returned is 0 as expected. Thanks, Al FSX with SP2, FSUIPCv4.971, Win10
-
Multiple Assignments to a Button and Profiles
ark1320 replied to ark1320's topic in FSUIPC Support Pete Dowson Modules
I think I understand now. If I have three functions assigned to one button or key and want two of them to be general and one profile specific, I just need to put the two general function assignments in the General section of the FSUIPC ini file, and put all three function assignments in the a/c profile specific section of the FSUIPC ini file. Thanks for the help Thomas. Al