
Matthew Twomey
Members-
Content Count
44 -
Joined
-
Last visited
-
Days Won
1
Matthew Twomey last won the day on October 25 2020
Matthew Twomey had the most liked content!
Community Reputation
1 NeutralAbout Matthew Twomey
-
Rank
Advanced Member
Profile Information
-
Gender
Male
-
Location
Palatine, IL
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
-
Well, unless / until you're familiar with most of the controls you might not really know what letter a given control starts with. For example, looking for landing gear controls I might type "gear" or "land" or "up" or "down" or "raise", ...etc. For lua scripts - they all start with Lua and there's several sections of them - so typing "buttonScript1" would narrow it down quite a bit. If I wanted to see any controls with "radio" in the name, I could type "radio". In general - just having it match anywhere in the name and filtering the list to matches would be quite useful and _really_ useful for
-
Is it currently possible to get Airspeed Hold status?
Matthew Twomey replied to Matthew Twomey's topic in FSUIPC7 MSFS
That works, thanks. -
Is it currently possible to get Airspeed Hold status?
Matthew Twomey replied to Matthew Twomey's topic in FSUIPC7 MSFS
Thanks John. I read those those threads and did some more testing tonight. A 1 byte read to 0x0B49 is exactly what I needed!! Thanks - this reads 1 when FLC mode is engaged on the G1k/C208 (just pointing that out for anyone else that comes along). By the way, is there a "live" document somewhere out there of offsets / controls for FSUIPC 7? I realize as the SDK gets refined on the MSFS side, these might be getting updates, changes, additions as we go along. -
Is it currently possible to get Airspeed Hold status?
Matthew Twomey replied to Matthew Twomey's topic in FSUIPC7 MSFS
I've been working with the c208 / g1000 on this project. -
Is it currently possible to get Airspeed Hold status from 0x07DC in MSFS? I'm trying to read this to detect the status of FLC autopilot mode, however it just always reads zero when testing?
-
@John Dowson - yep, works. Thank you!
-
Ok - thank you sir!
-
For #2, if it's a valid test - I can confirm that I can certainly play sounds from other Windows applications while MSFS is running and producing sound. For example I can watch Youtube videos with audio, use the media player, ...etc. I Can also play the wav file(s) in question.
-
1. [[STRING]] is quoted literal format for Lua. It works fine and avoids the need to escape anything, you can read more about it on lua.org. None the less, I've tried it several ways including a regular escaped string. 2. What is the best way to check this? -Matt
-
I can't seem to get the sound working in FSUIPC7. Here's what I'm doing: ipc.log(sound.device(0)); sound.path([[C:\]]); s = sound.play("click2"); if (sound.query(s)) then ipc.log("Sound played."); else ipc.log("Sound not played."); end Here's the result I'm getting: (and obviously no sound is playing) I have a 1 minute long wav file (named 'click2.wav') right in C:\ (just to make sure there were no path spaces issues). Windows can play the file fine, but I've also tried several different files.
-
Yep +1 on this, just ran into it myself. Using the map-to-key for now.
-
[Lua] Scan controller buttons from Lua on startup / auto
Matthew Twomey replied to Matthew Twomey's topic in FSUIPC7 MSFS
Ok - this seems to take care of it: handle, rd, rdf, wr, initreport = com.openhid(0x04D8, 0x8A3D); initreport = com.readreport(handle, 0); for i = 0, 3, 1 do local state = com.testhidbutton(handle, i, initreport); if (state) then ipc.log(i .. ": on"); else ipc.log(i .. ": off"); end end ipc.log("val1: " .. com.gethidbuttons(handle, initreport)); I'm not sure if that com.readreport is the right approach, but it's working. If anyone has a thought on this, please share. -
Looking for the easiest way to get the button state from a controller in a lua script that I'm running as "Auto" when FSUIPC starts up. My code is working, but things don't fall into place until I put some input on the controller I'm mapping. As soon as I provide any input - everything starts acting as expected. I tried using the initreport from com.openhid, but I may not be doing this right. Here's what I'm at with this: handle, rd, rdf, wr, initreport = com.openhid(0x04D8, 0x8A3D); for i = 0, 3, 1 do local state = com.testhidbutton(handle, i, initreport); if (state) then
-
Ok. I'll take a look. I've been flying the c208 with a g1000 and it does it in the sim, but I'll have to defer to other as to if it also does this in real life. I've found a suitable workaround to this issue for now (posted here in case anyone stumbled across this thread and would like to do something similar): currentAlt = ipc.readSD(Offsets.AutoPilotAltitudeValue) / 65536 * 3.28084; ipc.control(66124, currentAlt + amount * 100); Although you can't write negative values, you can send them via the control. So this method will read the value from the offset, modify it, then send a