Breakers pulled Code
-
I want to use the variables for Breakers pulled. The code-example for Oil L Breaker is working but only in Devmode when the BehaviourDebug-Window is open and Display Value is selected (MSFS 2020). What do I have to do to make it work outside of developer mode?
2·(>A:BUS·LOOKUP·INDEX,·Number)·(A:CIRCUIT·CONNECTION·ON:14,·Bool)
-
You might have done this on purpose, but make sure the · characters in your code are replaced with spaces.
It sounds like you're trying figure out when a breaker is pulled, not to actually do the pulling? What you have should work in XML, but it's difficult to use this code outside of XML, because the first command needs to complete before you read from the variable. What environment are you using to do this? Also, if push comes to shove, you can add
<EXPORT_LVAR>TRUE</EXPORT_LVAR>to each breaker in the XML, and then read the value with(L:var_#NODE_ID#_readonly, bool). -
Yes, I want to figure out when a breaker is pulled using Axis and Ohs. How to do the pulling I know. You've already helped me find the solution with editing the XML and use the vars. It works reliably. I can't get the code to work outside XML not even with pause commands in between. Now my virtual copilot can talk to me when an electrical failure occurs.
Nick, thank you very much for your help!
-
Yes, I want to figure out when a breaker is pulled using Axis and Ohs. How to do the pulling I know. You've already helped me find the solution with editing the XML and use the vars. It works reliably. I can't get the code to work outside XML not even with pause commands in between. Now my virtual copilot can talk to me when an electrical failure occurs.
Nick, thank you very much for your help!
@Humbi said in Breakers pulled Code:
Nick, thank you very much for your help!
That's what I'm here for

What's not working outside the XML? You should be able to read those new L:Vars anywhere.