Everything posted by geholger
-
Jscript debugging
Thanks. Did not know that there is some additional pre-processing by AAO prior to sending it to WSH. So yeah - then it makes sense and I will rework my scripts to not run into any problems later.
-
Jscript debugging
JavaScript is not very strict - same seems to be true for Jscript which was there a little earlier. - the “var” is not needed, same for the semicolon - the === and !== is a comparison that also checks for the correct type, the == and != are also possible but omitting the type check. I don’t know if the type checking works in Jscript - “interval” is not reserved and indeed, the AaoCmd.setInterval() seems to return a string (seems to be something like a uuid) Great to read that there is at least a WSH exception and that this will be made available in the next version. I will provide you with my proof of purchase later this weekend so I can give it a try. Thanks again for your great support!
-
Jscript debugging
Thanks for the reply - I see that there is just no support for this by WSH. Regarding the code: I just spotted the wrong log-command. Besides this and the typo, I am using this in my project to clear an already running interval started in another script using AaoCmd.setInterval(). Any other hints what’s wrong?
-
Jscript debugging
I am talking about my own variables in the jscript. For example: (WSH:jscript|AaoEntry|ASYNC) function AaoEntry() { interval = (L:A320CA_INTERVAL, String) if (iinterval != '') { // <<< here is a typo! "iinterval" instead of "interval" AaoCmd.AaoCmd.log('stopping interval='+interval); AaoCmd.clearInterval(interval) } } In this case, spotting the type in line #4 is easy. But imagine a jscript script with much more lines. Finding these type of errors is a nightmare as the script just stops executing after line #3 and you have to add logs to narrow down where the issue is located. I hope this will explain the problem. In this example I could have used (L:A320CA_INTERVAL) instead of a variable but the same issue exists for e.g. function calls, etc.
-
Jscript debugging
Hi Lorby_SI, thanks again for your fast and detailed help. I really appreciate it a lot. I already use AaoCmd.log as a workaround to narrow down the location potential issues. I have hoped there is a better approach available. But finding typos for e.g. variable names is really hard work with that approach. Just out of curiocity: How does jscript be compiled or sent to the sim? Does this provide any output that could probably be of use? Again - thanks a lot for your help. This is really great.
-
Jscript debugging
During development of a jscript script, the script may contain syntax errors (eg typos in variables etc) that prevent the script to complete. Is there some logging available that makes it easier to locate the issue or do I need to insert manual log statements to narrow down the location of the issue? Thanks for your help.
-
jscript: using SPEAK
Great - thanks!
-
jscript: using SPEAK
I would like to use the SPEAK command within a jscript script. To goal is to speak a generated string. Any ideas how this could be accomplished? My try that does not work: (WSH:jscript|AaoEntry|ASYNC) function AaoEntry(){ text = 'Hello' SPEAK(text) }
-
Masking axis input
Thanks a lot for the quick response. So far I only have some experience with scripting so I probably go this way. Need to check how to forward the z axis values to the Fenix tiller. The rest should be ok.
-
Masking axis input
I am having a strange issue with my stick. When giving pitch input it gives me a little input on the z-axis as well. As the z-axis is mapped to the tiller on the Fenix, this does not hurt most of the time. However during takeoff, pitch down is required until 100 knots and this is where the problem is. My idea was to mask the z-axis input in a way that as soon as TO-thrust is set, the input of the z-axis will be ignored. Is this something that can be realized using AxisAndOhs? Any help/ideas are highly appreciated.
-
AAO MSFS 2024 / Dumb RNP question
Thanks a lot for the quick help. I knew I screwed up on the RPN...
-
AAO MSFS 2024 / Dumb RNP question
I do not seem to get a simple script running using AAO for MSFS 2024. What do I want to achive: I have three different variables ((L:S_OH_ELEC_BAT1, Number), (L:S_OH_ELEC_BAT2, Number) and (A:BRAKE PARKING POSITION, bool)). If all values of them are 1, I would like to call script A and all other cases call script B. But even checking all variable values using the AND-operator does not work: (L:S_OH_ELEC_BAT1, Number) 1 == && (L:S_OH_ELEC_BAT2, Number) 1 == && (A:BRAKE PARKING POSITION, bool) 1 Using the script editor's debug, this expression does not give me any result other than (L:S_OH_ELEC_BAT1, Number) 1 == && (L:S_OH_ELEC_BAT2, Number) 1 == && (A:BRAKE PARKING POSITION, bool) 1 However, omitting the &&-operator gives the expected result: (L:S_OH_ELEC_BAT1, Number) 1 == (L:S_OH_ELEC_BAT2, Number) 1 == (A:BRAKE PARKING POSITION, bool) 1 Output of the debug window: (L:S_OH_ELEC_BAT1, Number) 1 == (L:S_OH_ELEC_BAT2, Number) 1 == (A:BRAKE PARKING POSITION, bool) 1 1 1 == 1 1 == 0 1 1 But using this expression together with an if-statement does not work. Regardless of the variables's values, it always calls "Script_On" (L:S_OH_ELEC_BAT1, Number) 1 == (L:S_OH_ELEC_BAT2, Number) 1 == (A:BRAKE PARKING POSITION, bool) 1 == 1 if{ (CALL:Script_On) } els{ (CALL:Script_Off) } Any ideas what I am missing here? Thanks a lot for your help.
-
Using SRGS grammar for checklists
Thanks for your help. I will try looking into conversations or the approach for using button assignments with voice using a supplied grammar. It might get complex though. Great that you consider integrating grammars into the checklist system 🙂 Greetings, Holger
-
Using SRGS grammar for checklists
I would like to create interactive checklists where the checklist item is read and I need to respond via voice. The voice recognition should just accept valid answers. This works very good for simple answers like Item: "GEAR PINS & COVERS", expected answer: "Removed" [*removed*](SPEAK:Gear pins and Covers) But how do I do it for more detailed replys like: Item: "TO Speeds & Thrust", expected answer: something like "V1 One Two Five, VR One Two Five, V2 One Two Nine, Flex Fifty Two" I was thinking to use a SRGS grammar mentioned in the AAOs documentation for voice recognition like: <?xml version="1.0" encoding="UTF-8" ?> <grammar version="1.0" xml:lang="en-US" xmlns="http://www.w3.org/2001/06/grammar" tag-format="semantics/1.0" root="Main"> <rule id="Main"> <one-of> <item>V1 <ruleref special="#GARBAGE"/> V2 <ruleref special="#GARBAGE"/> VR <ruleref special="#GARBAGE"/> Flex <ruleref special="#GARBAGE"/></item> <item>V1 <ruleref special="#GARBAGE"/> V2 <ruleref special="#GARBAGE"/> VR <ruleref special="#GARBAGE"/> take off thrust <ruleref special="#GARBAGE"/></item> </one-of> </rule> </grammar> But how can I use the SRGS grammar for checkists? Something like would be great but does not seem to work: [TO Speeds and Thrust.xml](SPEAK:Takeoff speed and thrust) Any other ideas or hints how this could be accomplished? Thanks for your help, Holger
-
Axis and Ohs Documentation
Hi, I really like the product but always having a hard time navigating within the provided documentation. As a suggestion, it would be great if the pages in the documentation are numbered the table of content is clickable to be easily navigate to the different topics. Would be great if this could be considered in one of the upcoming updates. Greetings, Holger
-
Re-selling PMDG addons?
Although it has been answered a couple of times, I'm not 100% sure if the answer is true for the whole world. This might probably be only the case for the US. I'm no lawyer at all (but work in the SW-industry for a long time), at lease for the european community it seems, that it is not allowed to restrict the user from re-selling used software. There have been some decisions e.g. by the court of justice of the european union that state that reselling of software licences can not be restricted by e.g. EULA (see http://curia.europa.eu/jcms/upload/docs/application/pdf/2012-07/cp120094en.pdf). As said, I'm not a lawyer and this is definitly no legal advice and maybe it is completly ok in the case of PMDG to restrict re-selling. Holger Schmid
-
FSX-SE/T7: Issue with saved flight?
At the time of writing, I started with a fresh install of FSX-SE and PMDG T7 and were using the default cold & dark panel state that is provided by PMDG. So unfortunatly no old resp. custom panel states. One other note: As I do have a parallel install of FSX and FSX-SE: The problem only exists in FSX-SE. FSX does not have this issue.
-
FSX-SE/T7: Issue with saved flight?
The problem does only exist, if I'm using the cold & dark panel state as the default one. Using any other panel state as default cures the problem for me. Maybe this helps.
-
FSX-SE/T7: Issue with saved flight?
Chris, the panel state was saved correctly and automatically. However, it did not load automatically when I load the flight. Instead, the default Panel state was loaded. So I'm concerned about two issues: why did the Panel state not load automatically and the default state was loaded instead? why the engines were not running after manually loading the panel state that was saved automatically?
-
FSX-SE/T7: Issue with saved flight?
Maybe someone has encountered the same issue: I currently start using the latest version of the T7 together FSX-SE (and the ASN beta). Therefore, I started cold&dark in EDDM and did all the preparations for a flight to LEPA. Shortly before lining up on runway 08L, I saved the flight just to be able to start over again practicing my departure skills ;-). If I try to load the saved flight later again, the T7 comes up with my default panel state (cold & dark) instead the saved one. This also happens with a just started FSX-SE session. Ok - if I then manually load the saved panel state for this flight and afer the initialization phase, I get lots of warnings and a stabilization error in the display. I also notice that no engines are running any more. However, at the time I saved the flight, the engines were running... Strange. As a workaround, I started the APU. After the APU was running, I could start the engines and after that I finally could do my takeoff. Just wondering if someone experienced the same issue. Would a ticket for PMDG be the correct way to proceed? Thanks for your help, Holger Schmid