Jump to content
The simFlight Network Forums


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

1 Follower

About Zoolander64

  • Rank
    Advanced Member
  • Birthday 10/29/1964

Profile Information

  • Gender
  • Location
    Sparks, NV, USA

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Greetings Pete, Always a pleasure hearing from you. That is a good idea to try and reproduce with the default aircraft for you. Thanks the suggestion. I will put aside some time this holiday season to give this a try.
  2. Greetings All, I did a clean install of v4.571 today and after I assigned the throttle and aileron/elevator axis, FSX would freeze. Task Manager required to stop FSX. Assigning just the throttles or just the aileron/elevator, no issues. It was only when they all had there assignments would a freeze occur. Here is a list of details, and a fix. - FSX w/SP2 - Joystick: Saitek Flight X65F - Rudder Pedals: Saitek Flight Combat - nVidia driver version 290.36 - Hardware details in signature - Previous FSUIPC version 4.70b (NOTE: This version worked fine, and downgraded to confirm proper functionality) - Unchecking throttle 1->12, 2->34 seemed to eliminate the freeze - Checking filtering for the aileron and elevator would eliminate the freeze (this is my current solution) - The problem only seems to be with the A2A B17 and the A2A 377 (all with the latest patches) The freeze would only occur with moving the throttle. I noticed a bit of "jitter" with my joystick and thus turned on the filtering. I am going to take a wild guess and wonder if the "jitter" is too much data to where ever this data is sent. I did not have the problem with the 4.70b version. Filtering seems to be working just fine, but I figured I would mention it if somebody else had the issue or something that needs attention. If any further data is needed, just let me know. Best Regards.
  3. Great thanks for the response. I am going to dig into this. If I get something, I will post it here as others may want this LUA script.
  4. Greetings Pete, Always a pleasure hearing from you. I was thinking some possibly a little simpler as I am a KISS type of person. I was thinking I could use LUA to extract CurrentLocationA when the airplane is stopped, but ready to take off, find a variable that denotes that the airplane is airborne (or just determine when the airplane is above the field altitude) as a flag to grab the CurrentLocationB, and "subtract" the two in order to get the distance rolled during a takeoff. Do you think this information is readily available using FSUIPC and LUA to extract from FSX? I am just looking for that jumping off point, as I can dig into whatever documentation or research. Thanks Pete. Hope all is well with you and Happy Holidays.
  5. Greetings All, We are looking at having a Virtual Valdez May Day Fly-In. I am curious if there is a way, using FSUIPC / lua, to extract or determine takeoff and landing distances for our multiplayer pilots? A quick search turned up nothing but possible payware apps. We try to make sure all of our events do not require additional purchased software to have fun. Any suggestions would be greatly appreciated. -Todd
  6. Greetings Pete, Well you have come to my rescue again. I did not realize this was referring to a FSUIPC SDK. Sure enough there it is on the main Schiratti website. Sounds like I am out of luck on view modes. Anyway, it will be interesting to check it out and see what trouble I can get into next :)
  7. Greetings All, I am digging deeper and deeper into FSUIPC. I know just enough to be dangerous now! I have a question about the "standard IPC variables". I am reading up on the FSUIPC monitor facilities and I would like to detect when the flight simulator's view mode is at the virtual cockpit. I am guessing there is a Base and Offset that I can read this information from. In the FSUIPC Advanced Users PDF, it references the "Programmers Guide in the SDK". I am assuming this is the FSX SDK that I installed from the FSX DVD's. I found the FSX SDK help file, but have not found any reference to the FSX information translated to BASE:OFFSET hexadecimal. Any help on where to find this info would be greatly appreciated. Of course, I am also interested in knowing if there is a better way to read the current view information. Thanks in advance.
  8. Greetings Pete, As I am working more and more with LUA files, and seeing your post, I am s-l-o-w-l-y getting it and writing better code (I hope). I am almost done with the event.flag method and this seems much cleaner and not a single crash so far. I am glad that I was able to help out a little, even if only indirectly, to make FSUIPC a stronger offering. I have sent your request to Marneftarr. I'll let you know his thoughts on it. Take care Pete, and stay out of that volcanic ash cloud! I went through three of those from being in Alaska for 30 years. Brutal on anything mechanical.
  9. Currently, not in the product, that I know of. I can send an email to Marniftarr to see about adding it to the list. Marniftarr is really open to ideas and doing a fantastic job. Very responsive and will end up obsoleting the need for my lua script :) and that is okay. Sidenote: Hmm, with my lua script, I could detect "Y" (SLEW), disable EZdok (Pete, I know you want it enabled), and switch to an outside view. I am in the process of converting over my lua to being event driven with event.flag. No need for ipc.get or ipc.set and this seems like a much better way to go about this. So far so good. I'll have more time to work on it tomorrow.
  10. Greetings Andy, Thanks for responding and the suggestions. Correct, these are now supported with 1.14, but I am taking it a step farther and want my Ezdok custom views to respond, aka cycle, with the "Shift-A" and "A" instead of cycling the default cockpit and outside airplane views. SideNote: I traded emails with Marniftarr(EZdok) during his initial release, even learned a little Russian, and suggested native view cycling support. It is on the short list, after spot plane replacement and TrackIR support. Until then, I figured I would give it a go with an lua. I also am turning off TrackIR (this requires state tracking since it is a toggle and not a forced on or off) when I switch to ANY other view. I also track EZdok on/off as well. When I am in the EZdok custom views, I re-enable EZdok, but when switching, "S", to a FSX catagory, I disable EZdok. Default FSX has typically 4 view catagories. For the VC and outside plane views I have the script use EZdok, and for the spot and airport I switch back to FSX. So in effect I am bagging the default FSX views for VC and outside airplane. So far it all works seamless with this script. Next, I have to figure out how to take it to multiple planes without having multiple lua's. With these custom views, I can, for example, have a view for the the A2A B17 that looks at the starter panel, then when I hold down a button, snaps to outside to see what the engine is doing, and at the same time keeping the A2A checklist on the screen (it disappears at each view change). The blind toggling of TrackIR and EZdok, did not work (first attempt w/o lua's) since it provided no tracking of it's current state since both the view change and manually triggering are independent. Now with all that said, I am completely open to ideas and sample scripts that make this process easier. I am happy with the script now, but I am sure the process can be reduced.
  11. Greetings Pete, Thanks for the reply. Enjoy your weekend and company. No hurry on the response. As I poke around in lua this weekend, I may learn about this stuff so as to be more helpful to you.
  12. Greetings Pete, Yes, I probably took on more than I could chew, but it seemed like a nice challenge. It is kinda fun too! I think it is really nifty that you allow such an interface for non-programmer types so we don't have to get into SimConnect and C++. btw: Thanks for the "code" button suggestion. Okay, now on to your questions. Yes, that is correct for the most part. I have a few other items I may want to add. It seemed when I was troubleshooting the issue by eliminated code using If/Then or just commented out segments, anything with a ipc.get seemed to cause the FSX crash. Removing the ipc.get statements resulted in no crashes. Now, with that being said, it could be the ipc.get statement takes a hair longer than intrinsic functions, thus causing a larger delay and leaving threads active? The more I think about it and learning what you have commented on threads, ipc.get may be just fine. Also, I could reproduce the crash much quicker with multiple ipc.get statements back to back. This may all be non-applicable since I am just stressing FSX and threads the wrong way. btw: ipc.set seemed to have no issues in my stress tests. I have also noticed that ipc.log and ipc.display in a tight loop will also causes FSX to crash. This could also be contained to my system since I have not tried my scripts on any other installation of FSX. I saw this as an option in your documentation. I actually thought (and thought wrong) that a lua script interrupted as needed would be better. It is nice to see this is not the case, and in my situation a iterative script with conditional statements would be better. Thanks for the suggestion. Sure, whatever you think I can offer. Especially, since I get to learn more stuff from the master :) I am using registered version FSIUPC v4.60a (4th March 2010)
  13. Greetings Pete, Thanks for taking the time, and on a weekend, to review my feeble attempt at lua. Okay, what you are saying makes perfect sense, and I kinda expected I was getting into thread issues. What I sent was just a sample, of what I thought narrowed done the issue, but I see now this is not the case. Thanks for your explanation. So, since you asked, let me show what I am really trying to do. Below is my actually code for my ini and lua files. I have EZdok and TrackIR. They do not work well with each other. I am tracking the state of each and want to to turn off one, and turn on the other. I am also simulating the default FSX "A" and "Shift-A" since EZdok does not have a view cycle command. I am using the ipc.get and ipc.set commands to remember the last states of TrackIR, Ezdok, and the current view. Note: I have just learning this programming language, and there may be a completely different and better(read as more efficient) way to do this. This is my first attempt. Any advice would be greatly appreciated. -Todd [Buttons] ButtonRepeat=20,10 0=; Joystick - Mode 1 - Normal Flight 1=CP(-0,5)0,4,CL1:R,1 ; TrackIR enable/disable 2=CP(-0,5)0,19,CL1:R,10 ; VC View 3=CR(-0,5)0,22,CL1:R,5 ; Prev View 4=CR(-0,5)0,20,CL1:R,6 ; Next View 5=CR(-0,5)0,21,CL1:R,8 ; Next Catagory -- **************************************** -- -- My EZdok & FSX View Tracking Script -- version: 1.0 -- -- **************************************** -- Passing Parameters -- 0 = Initialize -- 1 = TrackIR enable/disable -- 2 = EZdok state tracking -- 3 - View Next in current catagory -- 4 = View Prev in current catagory -- 5 = View Next Catagory -- 6 = View Prev Catagory -- **************************************** -- Public Variables iMaxView = {12,21} -- EZdok custom views = 10,11,12 VC views & 20,21 outside view (increment when adding new views) iView = {} -- Saved EZdok custom view states iMaxEZCat = 2 -- 2 EZdok catagories (increment when adding new catagories) iMaxCat = iMaxEZCat + 3 -- 2 EZdok catagories + 3 FSX catagories -- **************************************** -- Public Subroutines -- Toggle between 0 and 1. function toggle (iStatus) if iStatus == 0 then return 1 else return 0 end end -- Change TrackIR state -- 0=disabled, 1=enabled, -1=toggle function TrackIREnable(iNewState) -- Get saved state iCurrentState = ipc.get("TrackIR_enabled") -- Check for no previous initialization and assume enabled state if iCurrentState == nil then ipc.set("TrackIR_enabled",1) return end -- Check for toggle if iNewState == -1 then iNewState = toggle(iCurrentState) end -- Send keystroke ONLY if state changed if iNewState ~= iCurrentState then ipc.keypress(120,8) ipc.set("TrackIR_enabled",iNewState) end end -- Change EZdok state -- 0=disabled, 1=enabled, -1=toggle function EZdokEnable(iNewState) -- Get saved state iCurrentState = ipc.get("EZdok_enabled") -- Check for no previous initialization and assume enabled state if iCurrentState == nil then ipc.set("EZdok_enabled",1) return end -- Check for toggle if iNewState == -1 then iNewState = toggle(iCurrentState) end -- Send keystroke ONLY if state changed if iNewState ~= iCurrentState then ipc.keypress(68,8) ipc.set("EZdok_enabled",iNewState) end end --- Select Aircraft View function ShowView(iNewView) TrackIREnable(0) EZdokEnable(1) -- EZdok VC Forward if iNewView == 10 then ipc.keypress(104,2) -- EZdok VC Left elseif iNewView == 11 then ipc.keypress(103,2) -- EZdok VC Right elseif iNewView == 12 then ipc.keypress(105,2) -- EZdok Outside 1 elseif iNewView == 20 then ipc.keypress(100,2) -- EZdok Outside 2 elseif iNewView == 21 then ipc.keypress(102,2) end end -- **************************************** -- Main -- Get the last catagory index, 1=EZdok VC, 2=Ezdok Outside, 3-5 FSX iCat = ipc.get("LastCat") if iCat == nil then iCat = 1 end -- Get the last EZdok VC view iView[1] = ipc.get("LastView10") if iView[1] == nil then iView[1] = 10 end -- Get the last EZdok outside view iView[2] = ipc.get("LastView20") if iView[2] == nil then iView[2] = 20 end -- 0 = Initialize if ipcPARAM == 0 then --Nothing needed here yet end -- TrackIR, -1 = disable, 1 = enable if ipcPARAM == 1 then TrackIREnable(-1) -- Prev View (EZdok) elseif ipcPARAM == 5 and iCat <= iMaxEZCat then -- Decrement to the previous view. If at first EZdok view, -- wrap back to last view iView[iCat] = iView[iCat] - 1 if iView[iCat] < iCat*10 then iView[iCat] = iMaxView[iCat] end ShowView(iView[iCat]) -- Prev View (FSX) -- "Shift-A", as assigned in FSX elseif ipcPARAM == 5 then -- Just issue the keystroke since we dont need to track FSX views. ipc.keypress(65,1) -- Next View (EZdok) elseif ipcPARAM == 6 and iCat <= iMaxEZCat then -- Increment to the next view. If at last availabe EZdok views -- wrap back to first view iView[iCat] = iView[iCat] + 1 if iView[iCat] > iMaxView[iCat] then iView[iCat] = iCat * 10 end ShowView(iView[iCat]) -- Next View (FSX) -- "A", as assigned in FSX elseif ipcPARAM == 6 then -- Just issue the keystroke since we dont need to track FSX views. ipc.keypress(65,8) -- Prev Catagory (EZdok & FSX) elseif ipcPARAM == 7 then -- Decrement catagory counter iCat = iCat - 1 -- Check to see if counter is 0 -- and leave at first catagory (1=Virtual Cockpit), thus no wrap to last catagory. if iCat < 1 then iCat = 1 -- Check to see if now in range of EZdok catagories, typically 2, the VC and outside views. -- and show the saved view in the previous catagory elseif iCat <= iMaxEZCat then ShowView(iView[iCat]) -- Otherwise user still in FSX catagories, so perform a "View Mode Prev" command else ipc.control(65749) EZdokEnable(0) end -- Next Catagory (EZdok & FSX) elseif ipcPARAM == 8 then -- Increment catagory counter iCat = iCat + 1 -- Check to see if exceeded the maximum number of available catagories -- and leave at max, thus no wrap back to virtual cockpit. if iCat > iMaxCat then iCat = iMaxCat -- Check to see if in range of EZdok catagories, typically 2, the VC and outside views. -- and show the saved view in the next catagory elseif iCat <= iMaxEZCat then ShowView(iView[iCat]) -- Otherwise user now in FSX catagories, so perform a "View Mode Prev" command else EZdokEnable(0) ipc.control(65567) end -- Absolute View Selection elseif ipcPARAM >=10 then -- From the user supplied jump-to-direct-view, -- store new catagory and view to be used later iCat = ipcPARAM/10 iView[iCat] = ipcPARAM ShowView(iView[iCat]) end -- Save off these values to use for next time LUA is executed ipc.set("LastCat",iCat) ipc.set("LastView10",iView[1]) ipc.set("LastView20",iView[2]) -- **************************************** -- End
  14. Greetings All, First time posting, long time user of FSUIPC. Over the years I have found this to be a wonderful tool for FSX and earlier versions. I thank Pete for his wonderful efforts. I have recently started creating lua files to learn something new. I am impressed on what can be done, and want to keep at it. I have created a script that cycles through the various views that have been created by another product called EZdok. It simulates the default FSX "S", "Shift-S","A", Shift-A" keys along with tracking and turning on/off TrackIR and EZdok at the appropriate times. So far I have it working very well, except for one command. I am using ipc.get and ipc.set. ipc.set works perfect, but having a little difficulty with ipc.get. It functions as it should for a few passes, but it will eventually crash FSX. I created, separate from my script, a tiny lua that only has the following commands: while 1 do y=0 x = ipc.get("y") ipc.sleep(200) end Not very useful, but suffice for narrowing down my issue. I set this up to repeat (4=CR(-0,5)0,20,CL1:R,0 ; My Test) when I hold down a button on my joystick. In about 30 seconds FSX crashes. I am using the "R" repeat since I believe I read that the lua will complete before starting the next one and not leave a thread hanging. I am curious as what I am doing wrong with using the command. I would appreciate any help I can get. Thanks in advance. -Todd
  • 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.