Jump to content
The simFlight Network Forums

STF-DIR

Members
  • Posts

    86
  • Joined

  • Last visited

Everything posted by STF-DIR

  1. Hello, can anyone help me with setting some offsets in Linda for my VRInsight MCP? Here http://www.projectma....com/pmoffsets/ is the site with the Project Magenta offsets. Prosim will use these offsets for the EFIS and so on. Now lets take the F/D or A/T Button. Its Offset 0x5410 Bit 37 for F/D1 on nd Bit 18 for F/D1 off. How have i to set these Offsets with Linda/LUA? ipc.setbits??(0x5410, ??) Can anyone help here? Another possible solution is to run the PM Macro with ipc.runmacro("??"), but there i dont know the Macro Name to enter? I think i can not use the name from the FSUIPC like "PM MCP A/T On" you can assign to a Joistick Button. Please,can anyone help Thanks Matthias
  2. Hello, how can i read the lights of the Overhead in the PMDG737 NGX? Lets say the Light for the Ground Power availeble. Is this possible? Matthias
  3. Hello, some questions about LUA and ipc.writeLvars() I have started the lua script read lvars includet in the FSUIPC and also the log function of FSUIPC. Now i have loaded the FSX PMDG 737 NGX. Ok, thats the setup. Now lets take the Button for the left Engine were i can select "GRD","OFF", "cont" and "FLY". Wen i now turn the knob to the left the LUA Display says "L:ngx_switch_119_a=0", after the first turn to the right "L:ngx_switch_119_a=10" and so on. Now..how can i set the Button state via ipc.writeLvars ? I have testet ipc.writeLvars("L:ngx_switch_119_a",0) ipc.writeLvars("L:ngx_switch_119_a",10) and ipc.writeLvars("ngx_switch_119_a",0) ipc.writeLvars("ngx_switch_119_a",10) ipc.writeLvars("ngx_switch_119_a",30) nothing worked for me. What did i wrong here? How can i set the Button position directly ? Thanks Matthias
  4. Hello Pete, thank's for preparing the new Version so fast, but it did work for the iFLY..sorry. Always when i use the A/T Autopilot the Joistick has the command. Matthias
  5. Hi Pete, you are right, the Option .. exclude... was not the Problem, after the second test it dosent work again :-) I'm realy happy about that you provide a new update regarding my problem .. thanks. The problem with the Callibration .. i dont know what the problem is. I start FSX , then i calibrate the Joi in FSUIPC and then i can fly. ( I must calibrate because the Reverser comes up in Idle position of the Joi without calibration). The i leave the FSX and restart and now, when i start the Engines and set the Throttle to Idle with the Joi, most times the reverser comes up in idle position. So i must recalibrate the joi again. Thanks Matthias
  6. Ahhhhh, it works now.... The reason is on the 3 Joystick setup site. I have deselected the option Exclude Throttlen_Set Ok, works now. But if its ok in this Thread i want to ask you why i have to Kalibrate the Joystick every time i start the FlightSim? Matthias
  7. Hello Pete, i have an Saitek X52 Flight Controler, Joystick and Throttle control. At the first site of the FSUIPC Joystick configuration i have selected the option MAP to 4 throttles. Then on page 3 in the Joystick configuration i have setet up the Axis for the Throttle. One times, two times and so on, i testet many things and many times before i asked you. As above .. i have also testt as button press only and also as button press and release. One picture say more then tausend words :smile: Matthias
  8. Hallo Pete, thanks for explaining .. now i understand, but it wont work for me. I have tired Setbit and setbyte , see the pictures. it works only for the left ( 1 ) lever, the right one is not inhibited. What did i wrong? Matthias
  9. Hello, i need a litle help with the Offset 310A for the Joystick control. 1. The Problem: Whenever i fly with the iFLY 737 often, i have the problem when i will start on the Runway and i power up the engines with 40%, wait until the engines run stable and the comes it up. When i now press the TOGA Button nothing will happen because the FSX recive a signal from my Joystick ( Saitek X52 with Throttle control ) and works only with this values. In the iFLY menu you can select to inhibit the Throttle contro when Autothrottle is enabled, but it did not work. Ok, so i have tried to set the Offset 310A bit 3 to 8 the cut off the throttle by FSUIPC Button Control. It works only for Axis 1 ( Throttle lever 1 ) not for all? I have also tried to do the same with Offset 310B, but it dosent work. Ps.: I have FSUIPC 4.751a .. the last one Can anyone help with this? Thanks Matthias
  10. Hello, sorry, but for me mot all is working. The KeyAssignment.ini seams to be wrong. When i take a look over the FS Men into the IFly Key Assignments there are no keys assigned. Is this correct?? In this case the MIN and BARO knobs etc. are not working. Please help Thanks Matthias
  11. Hello Pete, some times before i have byed you FSUIPC. Now i want to programm some Buttons + Switches from my VRInsight MCP. For that i need a List what all the Macros mean in the List "Control sent when Button pressed" on the Tab Button + Switches. Some of the Names are not so clear for me. I hope for your Support. Olease send me a list with the Macro name and what they do. Thanks Matthias
  12. Ok, you dont understand me. i mean the blue marked section in the atached picture. Have you for that ( called macro or not ) a description what the functions do ? About the offsets a question: on the PM Site you can find that: But when i select Offset Byte Set and enter the Offset and Parameter nothing will happen. See the Atached Picture FSUIPC_1.jpg Matthias
  13. Hello Pete, i am on the way to programm my VRinsight MCP Combo with the FSUIPC Macros for Project Magenta. Now i need a litle bit more description for the Macros. e.g. i need the Macro for the Button on the left top in the EICAS for the setting of Decition and Radio height. PM can also press the Button, but i dont know the correct name of the Macro for the Button and can also not find it. So the Question: Have you a litle Description what all the PM Macros do ? Here are Macro Names e.g. "PM MCP LNAV MODE BUTTON", ok here is all clear, but here are some other names not so clear. Also how must i use the "PM MCP Kcodes ( by Param )" ? Please can you explain this? Thanks Matthias
  14. Hello, thanks for the very useful Answer !! That helps me enought to get this working. Thanks a very lot! Matthias Ps.: You have not a VRinsight MCP or?
  15. Hello, can you please help me again setting the ADF Frequency? I read a Value of 1234,5 from my MCP and must set this as a Frequency for ADF. The Offset is 0x034C for the main digits (i think here 234) and 0x0356 for the Hi and Lo byte, ( i think here mus be 1 and 5) But i dont know how to set this variable in the both offsets and how to get the 2 different values in C#. Can you please explain me how to do that ? Thanks a lot Matthias
  16. Hello, ahh...ok, thanks a lot !! Matthias
  17. Hello, i have a regstered FSUIPC 4.460a for FSX and try to read and write offsets for the COM interface in FSX. I have normaly implemented the FSUIPC.dll and it works with other Offsets fine, but here i haave Problems with COM1 and so on. This are the Offsets: ( I have tried different types of variables ) // FS Offsets Offset fs_COM1 = new Offset(0x034E); Offset fs_COM2 = new Offset(0x3118); Offset fs_COM1_STBY = new Offset(0x311A); After i have called this: using FSUIPC; namespace FSUIPC_Test { class Program { static void Main(string[] args) { // FS Offsets Offset fs_COM1 = new Offset(0x034E); Offset fs_COM2 = new Offset(0x3118); Offset fs_COM1_STBY = new Offset(0x311A); while(true) { FSUIPCConnection.Open(); FSUIPCConnection.Process(); Console.WriteLine("Com1: " + fs_COM1.Value); Console.WriteLine("Com2: " + fs_COM2.Value); Console.WriteLine("Com1_stby: " + fs_COM1_STBY.Value); FSUIPCConnection.Close(); Console.ReadKey(); } } } } i have here outputs like com1: 9349 Com2: 612705413 Com1_stby: 9349 What is here wrong? Can you helpp please? Matthias
  18. Hello, yes he does. For this IVAO has also a Manual. Matthias
  19. Sorry, i was wrong...i meant the IVAP Offset. Thanks again for all your Help Matthias
  20. Hello Pete and all other, i have ready the Plugin: -- if VRImodel == nil then -- Set known ports if testing with Lua not loaded automatically VRIdriver = "COM3" VRIdevice = "COM4" end speed = 115200 -- is this the same for all VRI devices? handshake = 0 -- No handshake minsize = 8 maxsize = 8 -- VRI seems to use fixed length blocks of 8 bytes dev = com.open(VRIdevice, speed, handshake) spd = 0 hdg = 0 alt = 0 function SetFsToPm(handle, str) end function displayVars() --ipc.display("SPD: " .. spd .. "\nHDG: " .. hdg .. "\nALT:" .. alt) ipc.writeUW(0x5406, spd) ipc.writeUW(0x5408, hdg) ipc.writeUW(0x540A, alt) end function setSPD(off,val) spd = val displayVars() end function setHDG(off,val) hdg = (val / 65536 * 360) hdg = math.floor(hdg + 0.5) displayVars() end function setALT(off,val) alt = val / 65536 * 3.28084 alt = math.floor(alt + 0.5) alt = alt / 100 if alt <= 0 then alt = 1 end displayVars() end setSPD(0x7e2, ipc.readUW(0x7e2)) setHDG(0x7cc, ipc.readUW(0x7cc)) setALT(0x7d4, ipc.readUD(0x7d4)) -- FSUIPC AP_SPD -- 07E2 2 Autopilot airspeed value, in knots event.offset(0x7e2, "UW", "setSPD") -- FSUIPC AP_HDG -- 07CC 2 Autopilot heading value, as degrees*65536/360 event.offset(0x7cc, "UW", "setHDG") -- FSUIPC AP_ALT -- 07D4 4 Autopilot altitude value, as metres*65536 event.offset(0x7d4, "UD", "setALT") --event.VRIread(dev, "SetFsToPm") It holds the PM MCP always congruent to the MCP Displays :-) Pete: One question: I anywhere a listing from the "Control sent when Button pressed" actions? I search for the Transponder ON/OFF action. Matthias
  21. Hello, ah, now i understand how to restart the LUA Plugin...thanks and sorry for not understanding you. But at the moment i have the File ready for me. All works perfekt, and for understanding: I only need to set the PM SPD, HDG and ALT Values with the LUA PlugIn. Thats all i need. For that the file shows like this: function SetFsToPm(handle, str) ipc.log("SetFsToPm=" .. str) if string.match(str, "SPD") ~= nil then speed = tonumber(string.match(str, "SPD(%d%d%d)")) ipc.writeUD(0x5406, speed) --ipc.log(" --> SPD=" .. speed) end if string.match(str, "HDG") ~= nil then hdg = tonumber(string.match(str, "HDG(%d%d%d)")) ipc.writeUD(0x5408, hdg) --ipc.log(" --> HDG=" .. hdg) end if string.match(str, "ALT") ~= nil then alt = tonumber(string.match(str, "ALT(%d%d%d)")) ipc.writeUD(0x540A,alt) --ipc.log(" --> ALT=" .. alt) end end event.VRIread(dev, "SetFsToPm") The Problem here is that : 1. i turn the SPD knob at the MCP. The Values at PM MCP are exact the same as in the MCP Display...OK, fine !! 2. i turn the HDG Knob in the MCP. The Values at the PM MCP are exactly the same as in the MCP DIsplay...fine !!! But when i now again turn the SPD Knob at the MCP, the HDG Value at the PM MCP displays 000. Why that? Matthias
  22. Hello, i dont know if understand correct, sorry. You mean i can take any changes in the LUA file and save it ( FSX is running ) and after that i push the SPD or HDG Knob on the MCP again and the changes take effect? Understand i correct? I mean not. I have read in your documentation about LUA Plugins "LUA Plugins for VRInsight Devices.pdf" Thats what i trying to do. Right click on the "test_1.lua" File and then select Edit Script. The LUA SCITe opens. Then i want to start the Script from here. Matthias
  23. Ahhh, ok, thanks, i will test it outside of the FS. At the moment i must restart the FSX for every Code changes to test. Pls. Can you explain how the test file must show if i want to use it outside of the FS? ( as i write in the last post) So it is easyer for me to test with the events and offsets. Thanks a lot Matthias
  24. Sorry, can you please explain how the LUA file must show if i want to test it outside of the FSX? I have tried this test file -- test_1.lua if VRImodel == nil then -- Set known ports if testing with Lua not loaded automatically VRIdriver = "COM2" VRIdevice = "COM5" end speed = 115200 -- is this the same for all VRI devices? handshake = 0 -- No handshake minsize = 8 maxsize = 8 -- VRI seems to use fixed length blocks of 8 bytes hdg_1 = "HDG123+" hdg_2 = "HDG124++" dev = com.open(VRIdevice, speed, handshake) if dev == 0 then ipc.log("Could not open VRIdevice port") ipc.exit() end print(hdg_1) nbr = tonumber(string.match(hdg_1, "HDG(%d%d%d)")) print("nbr: " .. nbr) str = string.format("HDG%03d", nbr) print("str: " .. str) io.read() but i earn an error in Line 18 "lua: test_1.lua:18: attempt to index global 'com' (a nil value)" Matthias
  25. Hello, ok, so i need only one event in the LUA File for any event from the MCP: function setMCP_TO_PM(handle, str) -- need to check only for SPDnnn+/- and send speed or mach to PM speed = tonumber(string.match(str, "SPD(%d%d%d)")) if speed ~= nil then speed = speed * 655.36 ipc.writeUD(0x7e8, speed) end end event.VRIread(dev, "setMCP_TO_PM") And this are the 3 PM Offsets for me: so i have to change this line ipc.writeUD(0x7e8, speed) to this ipc.writeUD(5406, speed) Am i right here? Sorry, but for the one i need a litle bit more help Thanks Matthias
×
×
  • 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.