Jump to content
The simFlight Network Forums

DaveSCUSA

Members
  • Posts

    162
  • Joined

  • Last visited

Everything posted by DaveSCUSA

  1. Thank you. Your answer doesn't have to be specific to an aircraft, however, the aircraft is the Cessna Longitude Citation. The switch I'm using is a single press button providing keypresses. I have tried 3 options: 1. Preset only, 2. Preset and Input Event, and 3. Input Event only. The only option that worked was #3 without the offset modifier. My problem, is I want first press on and second press off. The example in my post (without the preset) works to turn the event on but not off. In addition, I am trying to use the offset modifier technique to use a rocker switch (as on the Alpha and Bravo) with a simconnect toggle event. Push top on, push bottom off.
  2. Thank you for the hint to use x0D00zzzz Offset Byte Togglebits. Thank you but I'm confused. I use an offset of an LVar to determine the state of the switch. E.g. 42=L:Elect_Ext_Pwr=UB0x66DB C700s_New_Ext_Pwr#(L:Elect_Ext_Pwr) if{ (>K:TOGGLE_EXTERNAL_POWER) 0 (>L:Elect_Ext_Pwr) }els{ (>K:TOGGLE_EXTERNAL_POWER) 1 (>L:Elect_Ext_Pwr) } 86=B66DB<1 N53,14,PC700s_New_Ext_Pwr,0 -{Preset Control}- 88=B66DB<1 N53,14,IELECTRICAL_ExternalPower_1,1.000000 -{Input Event}- 90=B66DB>0 N53,14,PC700s_New_Ext_Pwr,0 -{Preset Control}- 92=B66DB>0 N53,14,IELECTRICAL_ExternalPower_1,0.000000 -{Input Event}- Sometimes it doesn't work based, I believe, on the internal sequence and timing. I have seen in the log: 34329 KEYDOWN: VK=53, Waiting=0, Repeat=N, lParam=0 (0x0), Shifts=6 34329 .. This key is programmed in FSUIPC7 'Keys' options 34594 EV_KEYDOWN received: 0x35 (5): repeat set (rate=250/100) 34594 KEYDOWN: VK=53, Waiting=0, Repeat=Y, lParam=1073741824 (0x40000000), Shifts=6 34594 .. This key is programmed in FSUIPC7 'Keys' options 34610 *** EVENT: Cntrl= 67091 (0x00010613), Param= 0 (0x00000000) SET_EXTERNAL_POWER 34610 *** EVENT: Cntrl= 67091 (0x00010613), Param= 1 (0x00000001) SET_EXTERNAL_POWER For the above use of the button, the documentation of Offset Byte Togglebits that I found is: x0D00zzzz Offset Byte Togglebits (offset = zzzz), hexadecimal, and [LvarOffsets.B747] 1=L:XMLVAR_YokeHidden1=UB0xA000 Once an lvar has been added to an offset, you can use the offset for the lvar value as you would any other offset. You can also update the lvar by updating the offset value, using, for example, one of the FSUIPC Offset Controls (see page 35), such as Offset Word Set, or Offset Byte Togglebits. Make sure that the control that you use matches the size of the offset defined to hold the value. So, taking my previous example using the lvar XMLVAR_YokeHidden1, to assign a button/switch to control this lvar via the offset I have assigned (A000), I would assign to the control Offset Byte Togglebits, giving A000 as the offset and 1 (or x1) as the parameter. Due to my lack of expreience, I have difficulty understanding how to use the Offset Byte Togglebits and the offsets. I thought the above would suffice for the Mom switch. Could you please provide specific code that allows the above switch to work. It is problematic when there is an Input Event in play. Presets can't update Input Events and Presets can't update offsets. A dilemma.
  3. Thank you Al and John for your time. Didn't expect an answer so quickly. Just to make sure I looked at everything, I did a quick look on the events using SPAD.NeXt. It showed Input Event B:ELECTRICAL_ExternalPower_1 (not sure why the FSUIPC7.log didn't show it) is used. I didn't pick up the preset as I extracted the presets from Mobiflight to myevents.txt to reduce the number of entries. My bad, I missed the preset. It's a shame that presets can't manipulate Input Events. Perhaps I need to use Lua. Is there a technique to turn an on/off Input Event to a toggle event? Thank you both.
  4. I am still struggling with getting events to work with now the Cessna Logitude. I have attached a file with the pertinant information. The control I'm trying to get to work is the SET_EXTERNAL_POWER by pressing a key on my USB device. I'm using this key to debug my procedures. The attached file shows the Log from two methods to turn the Cessna Longitude External Power switch on and off. The first entries in the Log are turning the External Power on and off using the virtual cockpit button resulting in 24829 *** EVENT: Cntrl= 67091 (0x00010613), Param1= 1 (0x00000001), Param2= 1 (0x00000001) SET_EXTERNAL_POWER. This works. The second entries show the Log using the USB key resulting in the entry 34610 *** EVENT: Cntrl= 67091 (0x00010613), Param= 1 (0x00000001) SET_EXTERNAL_POWER. This did not work. Included in the file are the entries in the profile for the key and the preset entry for the key. Not sure why the SET_EXTERNAL_POWER control is not working and why there are two SET_EXTERNAL_POWER entries in the keypress logging. Would you help please? I will incude the Log file. Thanks External Power Log Results.txt FSUIPC7.log
  5. I seemed to figured it out. Thanks
  6. PS - Between V7.4.13 and the second V7.4.15, I completely deletedthe FSUIPC7 folder from the C Drive.
  7. John, I have 2 PCs that I can run FSUIPC7. It seems that V 15 is the issue of not showing in the task bar and can't use alt+F to bring up the UI. I did not check the System Tray. Below, I have the FSUIPC7.ini and FSUIPC7.log files from two different versions. All were manually started and MSFS was not used. Files FSUIPC7-V15-1st These files were from the 1st test of FSUIPC7 V15. The icon was not in the task bar, the splash screen displayed and the console disappeared after approximatel 2-3 seconds. Immendiately started FSUIPC7 again no splash screen nor the console displayed. Files FSUIPC7-V13 Uninstalled V7.4.15 and installed V7.4.13 (I didn't have V14). All worked fine. Displayed both the UI and console and Splash screen. Was able to see the icon in the task bar, and was able to open and close and open again both windows. Files FSUIPC7-V15-2nd Uninstalled V13 and reinstalled V15 with the same results as the first iteration of V15 above. I don't have V14 on my machine. The only version I can find online is V7.4.15. Could you provide V14? FSUIPC7-V15-1st.iniFSUIPC7-V15-1st.logFSUIPC7-V13.iniFSUIPC7-V13.logFSUIPC7-V15-2nd.iniFSUIPC7-V15-2nd.log
  8. I have had this also. Normally, the FSUIPC7 icon appears in the task bar. Upon a right click, the small windows above the task bar shows both the console and ui. One can choose one or the other. The case above describes the instance where there is no icon. In addition, in my case, the alt+f did not display the ui. Also, when I opened FSUIPC7 without MSFS executing, neither the console nor the ui appeared. I removed all of FSUIPC7 files and installed again. I'll retest today.
  9. I have noticed that when using the Offset Logging in the FSUIPC7 UI (attached), there are control entries in the FSUIPC7.ini file (attached). I there a four entry limit for control logging or may there be more entries coded in the FSUIPC7.ini file? If there are more, what is the limit of the number of entries? Thanks
  10. Often when activating a switch or button in a cockpit, the FSUIPC7 Log shows several entries. An example is a battery switch on activation may show a master battery control event, a toggle bus control event and a "B:Battery" input event. Is there any way to obtain which event was triggered by the switch on. Or must one test each separately to observe the action?
  11. Thank you
  12. In searching the FSUIPC7 forum, I cannot find where ipcPARAM is set. Searching the internet, found many ipcPARAM discussions, but not where the value in the ipcPARAM is set. Could you explain, please.
  13. You Said: What does this ('functions are executed') mean? I see no need to provide any further documentation, and you don't seem to be looking at the documentation already provided. Start with that before asking for further documentation. Why is the current documentation not sufficient? Cockpit builders have been using FSUIPC for > 15 years with the current documentation... I say you will prpbably bar me from the sire for saying this. Europe has a stronger CANCEL culture than the USA (and we're bad). Have worked allover the world in Asia as well as Eurompe and the USA. European software providers tend to put out products that are not ready (how about MSFS) and have no patience for the user. If this software was free, no one would have a complaint. But you have no idea how many FSUIPC7 users are disatified and end up using SPAD.NeXt or Mobiflight. The only reason I use FSUIPC is for the keypress functions. USA users would have no patience for the quality of documentation. You said to look in the Lua Plug-ins documentation, I certainly will. However, the two items I was looking for from ('functions are executed') was what is the sequence of strategix execution of events from.................................................. I have been using FSUIPC7 long before you took over from your father. So, 15 years is not much. Oh the hell with it, you wouldn't listen anyway. There is no overall view of the documentation other than the file names. Do you expect everyone to memorize the docs? An over view document with subject detail of the information in each documernt or an FSUIPC7 index would be helpful. I quit. If your documentation was so great, whay are there so many basic questions. As I said, if it were free, who would complain.
  14. There is a function and a facility, I believe, that would be most helpful to users who are building a cockpit. Function - The ability to test a variable for "nil" value or empty. To find if LVars have been loaded, I tried testing an LVar for a "nil" or less than one. Obviously there is an Lua ERROR. Or setting a variable to when the LVars and Input Events are loaded. Facility - It would be most useful if there were a document that explained step by step of how all FSUIPC7 functions are executed. When Luas are loaded, when profiles are loaded, when the aircraft is loaded, when the aircraft is ready to fly. It would help some sophisticated Lua programming to know when items are available to use. The following code gets an error. if ipc.getLvarID("L:AS3000_IsLocalVarDefined") == nil or ipc.getLvarID("L:AS3000_IsLocalVarDefined") < 1 then (statements) end 99719 *** LUA Error: C:\FSUIPC7\C700_InitLVars.lua:24: attempt to call field 'getLvarID' (a nil value) Thanks
  15. Thank you again, I've tried a couple of methods (e.g. event.control(67209,"StartLVars") --PANEL_LIGHTS_POWER_SETTING_SET or event.control(67213,"StartLVars") ELECTRICAL_EXECUTE_PROCEDURE) as they are executed after loading the aircraft - didn't work. Can you advise me of a method of executing an Lua function() after the LVars, HVars and Input events are loaded? If I'm on the ground or it's a specific aircraft, I will execute the code I want (I know how to determine ground and aircraft).
  16. I'm fine now as I didn't read or didn't notice one needed to confirm in the keypress assignments. Thanks again.
  17. I normally dont use Confirm. Not needed, aparently, in button assignments but needed in keypress assignments. Thanks
  18. Hello John, I'm not at my PC so I can't "Add Files". But I do have a question if I may. I'm trying to execute an Lua function based on the routine "event.sim". It's coded event.sim(FLIGHTLOAD,"StartLVar"). I want the code to kick off when a flight is started - "Fly Now". The Lua is loaded and stops at "waiting for an event". Is this routine still available and where in the schema does it light off? Thanks
  19. Thanks for your response. Upon assigning a button or key in the assignment UI, FSUIPC7 enters the programming in the FSUIPC7.ini file under a [Buttons] or [Keys] section. I wa talking about the <Entry Number> for each assignment. If memory serves (?????), the number had incremented by 2. Now it seems to increment by 1 starting with 0.
  20. I have several questions and requests: 1. The keypress assignments doesn't retain the profile radio button to the next assignment as does the button0 assignment. When performing numerous assignments for an aircraft, forgetting to select the check can obviously cause issues. Could you carry the profile button forward? 2. When entering the first few letters in the control, preset, input event field, the first occurance appears at the bottom of the window. Could the first occurrence appear at the top of the window? Would save many mouse clicks. 3. The increment of the button or keypress assignments now ncrements by one (1). I seem to remember the entries were incremented by two (2). Could you change the increment to more than 1. 4. Is there a way, other than assigning to an offset, to display the LVar used with an event or input event in the log? Or, a method to select one or more LVars to display their values in the log? Thanks
  21. PS - A question I forgot to ask. Does including an LVar in a preset define the LVar in the Sim as it does in the model behaviors?
  22. Thank you. I have given up on the Mustang. Sometimes the key presses work sometimes they don't. I have switched to the C700 Longitude. The above toggles only work in one direction, turns the valve on but not off with the second push. I understand the above in principle. But could you explain: C700s_ANTI_COLL#(L:LIGHTING_STROBE_1) ! s0 (>L:LIGHTING_STROBE_1) 1 l0 (>K:2:STROBES_SET), I don't understand the role of S0 and I0. What number is set into the >K:2:STROBES_SET? C700s_Elec_Stby_Pwr_On#(A:ELECTRICAL MASTER BATTERY:3, bool) ! if{ 3 (>K:TOGGLE_MASTER_BATTERY) } 0 (>L:XMLVAR_STBYBattery_Test), in this case is it asking if A:ELECTRICAL MASTER BATTERY:3 is not true. These things can get kind of tricky. Thanks
  23. Thanks for all your input, I have it working. M_LH_Fuel_On#0 (>L:switch_fuel_left, bool) (>K:TOGGLE_FUEL_VALVE_ENG1) 1 (>L:C510L_Fuel_1, Enum) M_RH_Fuel_On#0 (>L:switch_fuel_right, bool) (>K:TOGGLE_FUEL_VALVE_ENG2) 1 (>L:C510L_Fuel_2, Enum) M_LH_Fuel_Off#1 (>L:switch_fuel_left, bool) (>K:TOGGLE_FUEL_VALVE_ENG1) 0 (>L:C510L_Fuel_1, Enum) M_RH_Fuel_Off#1 (>L:switch_fuel_right bool) (>K:TOGGLE_FUEL_VALVE_ENG2) 0 (>L:C510L_Fuel_2, Enum)
  24. Not sure what your terminology is for the logging function. In the Log drop down in the UI there is an entry for offsets. Upon opening the window, there are four boxes to enter offsets. I used two spare offsets to attach L:switch_fuel_left and L:switch_fuel_right found in the C510_interior.xml file. Both offsets x66C6 and x66C7 showed in the log as 0 value at flight initialization. When the fuel valve switches were turned on, then off in the cockpit at startup, the only entry shown in the log are two events - TOGGLE_FUEL_VALVE_ENG_1 and TOGGLE_FUEL_VALVE_ENG2. No Input Event is displayed. There are no additional offset log entries. A sample of code from the C510_interior.xml file is <LEFT_SINGLE_CODE>(L:switch_fuel_left, bool) ! (&gt;L:switch_fuel_left, bool) (>K:TOGGLE_FUEL_VALVE_ENG1)</LEFT_SINGLE_CODE>
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.