
ark1320
Members-
Posts
664 -
Joined
-
Last visited
-
Days Won
17
ark1320 last won the day on January 3
ark1320 had the most liked content!
Profile Information
-
Gender
Male
-
Location
Colorado, USA
Recent Profile Visitors
5,389 profile views
ark1320's Achievements
-
Hi John, Making Lvar names in FSUIPC insensitive would certainly be helpful when you have time to do it. Thanks very much, Al
-
In my experience Lvar names are not case sensitive in XML coding. But when used in Lua scripts with commands such as ipc.writeLvar("L: Name", value) or ipc.readLvar("L:Name") they are case sensitive, I assume because when enclosed in quotation marks they are treated like strings. This caused me a problem lately in MS2024 because in the XML code for an aircraft, the developer accidentally (I assume) was not consistent case-wise with some of the Lvars names. As a result my Lua scrip, which used Lvar read and write commands like the above, did not work as expected. So I'm posting this in case it helps someone in the future. What I eventually noted was in the Lvar list that the FSUIPC7 wasm provides, a few of the Lvar names had a different case then in the section of XML coding I was trying to access. Perhaps the wasm Lvar list "uses" whatever case the first Lvar it comes across is using -- don't really know. The Lvar list did not include both case variations of the Lvar name. It would be convenient if commands like ipc.readLvar( ) were not case sensitive, but that may not be possible. In my case, I had to use ipc.execCalcCode(" ") to get around the case issue because the Lvar names are not case sensitive in the XML CalcCode. If something above is not correct, or there is a better solution to this case sensitive Lvar issue, please let me know. Thanks, Al
-
Hi John, I did in fact try some things that didn't work. FSUIPC has added some Lua functionality (such as all the ipc.wxy commands) that are not in the formal Lua documentation, so I thought I'd ask here "just in case". Thanks for checking, Al
-
Is there a way to represent numbers directly in binary format? For example, instead of writing ipc.writeUB(0x1234, 0xF2), write ipc.writeUB(0x1234, 0b11110010) ? I can't seem to find anything that shows how to indicate the number is binary. Thanks, Al
-
I don't have a physical trim wheel so have no experience with that, but I don't see why it would not be recognized as an axis in the sims. When you turn it does FSUIPC7 recognize it as an axis similar to what I showed above?
-
If you assign the trim to an axis in FSUIPC7 and send it to FSUIPC7 Calibration, then you can adjust the slope (sensitivity) of the trim curve as shown below.
-
The Set Trim binding in MSFS2020 did nothing because "Set" commands require a value that you want to set the target control to, but there is no way to include the value in Asobo's binding interface. Suggest you use the FSUIPC7 Offset Sword Decrement and Offset Sword Increment controls. Shown below for the sake of this explanation, I have assigned the U key to Offset Sword Decrement so that the current elevator trim setting will be decremented by a value of 64. FSUIPC7 offset x0BC0 holds the elevator trim control input which goes from –16383 to +16383 decimal. The Parameter 64/-16383 means each time this control is activated, decrease the current trim setting by 64, but do not go below the lower limit of -16383. The smaller the increment, 64 in this case, the finer the trim control. As far as I know, you can make this increment just about anything you want, 64 is just an example. Similar to the below, you would also assign a different key (or more likely use two buttons for trim up and down) to the control Offset Sword Increment, again using x0BC0 as the Offset, and a Parameter of 64/16383 (no minus sign this time since the upper trim limit is a positive 16383). Each time this control is activated, the current trim will be increased by 64.
-
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
It was the C: in front of the XML code that I was missing. ☹️ Thanks, Al -
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
If I simply want to display the result of a calculator code calculation, what would be the best way to do that -- which PilotsDeck action? For example, suppose I just wanted to display the numerical result of this calculation which provides the fuel burn per NM based on ground speed. (A:ENG FUEL FLOW PPH:1,Pounds per hour) (A:ENG FUEL FLOW PPH:2,Pounds per hour) + (A:GROUND VELOCITY,Knots) / Thanks, Al -
For completeness, here is how I expanded the information in my post above for the HJet throttles to use two physical throttle levers on my Saitek Throttle Quadrant. With the throttle1 main script the Saitek controller throttle axis value is stored in offset 0xA000. If the value changes by at least a magnitude of 128 the function HJet_Throttle1() is called to convert the raw axis value to a number between 0 and 1, and this number is written to the HJet Lvar that controls HJet throttle1. Same idea for throttle2 which uses offset 0xA002. These scripts are loaded automatically when FSUIPC7 starts through the FSUIPC7.ini Profile Specific file entry as shown below: [Auto.HJet] 1=Lua HJet_Throttle1 2=Lua HJet_Throttle2 Here are the two main throttle Lua scripts that get loaded automatically: -- HJet_Throttle1.lua function HJet_throttle1() throttle = (ipc.axis("T","X") + 16384)/32587 -- need throttle range of 0 to 1 for TQ throttle axis range of -16384 to +16203, which is idle to full power. ipc.writeLvar("L:THROTTLE1_SET", throttle) -- ipc.axis("T","X") is the FSUIPC "X" axis value of TQ "T" (approximately between -16384 and + 16384 ) end --*********************************************************************** --*** Main Part of Throttle1 Program That Calls the Above Function *** --************************************************************************ ipc.writeLvar("L:THROTTLE1_SET", 0) -- initialize throttle1 to idle position. ipc.writeLvar("L:HA420_ThrottlePos_L", 50) event.offsetmask(0xA000, 0xFF80, "SW", "HJet_throttle1") -- mask requires a change of at least 128 in offset 0xA000 to trigger the function call. -- Under FSUJIPC7 Axis Assignments, this HJet throttle1 axis value has been assigned to Offset 0xA000 as Offset Word Set as shown below Main script throttle1 FSUIPC7 axis assignment. -- HJet_Throttle2.lua function HJet_throttle2() throttle = (ipc.axis("T","Y") + 16384)/32587 -- need throttle range of 0 to 1 for TQ throttle axis range of -16384 to +16203, which is idle to full power. ipc.writeLvar("L:THROTTLE2_SET", throttle) -- ipc.axis("T","Y") is the FSUIPC "Y" axis value of TQ "T" (approximately between -16384 and + 16384 ) end --*********************************************************************** --*** Main Part of Throttle 2 Program That Calls the Above Function *** --************************************************************************ ipc.writeLvar("L:THROTTLE2_SET", 0) -- initialize throttle2 to idle position. ipc.writeLvar("L:HA420_ThrottlePos_R", 50) event.offsetmask(0xA000, 0xFF80, "SW", "HJet_throttle2") -- mask requires a change of at least 128 in offset 0xA000 to trigger the function call. -- Under FSUJIPC7 Axis Assignments, this HJet throttle2 axis value has been assigned to Offset 0xA002 as Offset Word Set as shown below. Main script throttle2 FSUIPC7 axis assignment. The four tiny scripts below move the HJet throttles between cutoff and idle. There is a switch at the bottom of my Saitek throttle axes. When the switch is closed by moving a throttle lever down into the switch, the associated HjetThrotCuttoff script is called, and when the lever is moved up out of the switch position the associated HjetThrotIdle.lua is called. Here are the two scripts for throttle1 --HjetThrotCutoff1.lua ipc.writeLvar("L:THROTTLE1_SET", -1) -- cutoff value is -1, idle to full power is 0 to 100 ipc.writeLvar("L:HA420_ThrottlePos_L", 0) -- cuttoff position, 50 is idle, 100 is full power position --HjetThrotIdle1.lua ipc.writeLvar("L:THROTTLE1_SET", 0) -- idle value, -1 is cuttoff, 1 is full power ipc.writeLvar("L:HA420_ThrottlePos_L", 50) -- idle position of throttle lever, 0 is cuttoff, 50 is idle, 100 is full power position Here are the two scripts for throttle 2 --HjetThrotCutoff2.lua ipc.writeLvar("L:THROTTLE2_SET", -1) -- cutoff value is -1, idle to full power is 0 to 100 ipc.writeLvar("L:HA420_ThrottlePos_R", 0) -- cuttoff position, 50 is idle, 100 is full power position --HjetThrotIdle2.lua ipc.writeLvar("L:THROTTLE2_SET", 0) -- idle value, -1 is cuttoff, 1 is full power ipc.writeLvar("L:HA420_ThrottlePos_R", 50) -- idle position of throttle lever, 0 is cuttoff, 50 is idle, 100 is full power position HjetThrotIdle1.lua HJet_Throttle1.lua HJet_Throttle2.lua HjetThrotCutoff1.lua HjetThrotCutoff2.lua HjetThrotIdle2.lua
-
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
The PilotsDeck displays look OK as shown below, didn't see much change from the originals. Profiles: Test CTL.streamDeckProfile Test+.streamDeckProfile -
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
Just to make sure I understand the big picture, I am to basically repeat the first test I did above but using a new version of PilotDeck and with new actions put into the new "empty" profiles. Correct? -
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
Yes, seemed close to what it was as best as I can recall. I can go in an adjust the font sizes if necessary, just don't want it to change significantly between displays. -
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
1. I started the computer with the small main display. 2. Created the two profiles below 3. Downloaded and installed the PilotsDeck test version from MediaFire. 3. You didn't mention starting the sim in your list above -- so I did not do that. Here are the two profiles and the associated displays on the StreamDecks. Looks good to me. Hope this is what you wanted. Test CTL.streamDeckProfileTest+.streamDeckProf -
Introducing Pilot's Deck, a StreamDeck Plugin
ark1320 replied to Fragtality's topic in User Contributions
When the computer boots with the smaller main display and I move the sim window to the 4K display, the PilotsDeck displays are still correct and Powershell reports a DPI of 96. When the computer boots with the larger 4K main display and the sim is running and the PilotsDeck fonts are too large and the ALT VALUE is truncated, Powershell reports a DPI of 168. I noticed the 168 value is 175% of 96. In the first case above I am accessing Power Shell using the smaller display since that is where the Start Menu is, and in the second case above I am accessing Power Shell using the 4K display since again that is where the Start Menu is. Hope I did that right, and that is the info you wanted.