Add support for functions in script files? #1108
seanmcleod
started this conversation in
Ideas
Replies: 3 comments
-
Seems useful. I would have assumed something like this is already possible to vary the wind via script file. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Pretty sure the only way to modify properties in JSBSim XML based scripts is via the <set name="propulsion/fuel_freeze" value="1"/>
<set name="fcs/throttle-cmd-norm[0]" action="FG_RAMP" value="0.6" tc="1.0"/>
<set name="fcs/steer-cmd-norm" action="FG_EXP" value="0.0" tc="1"/> enum eAction {
FG_RAMP = 1,
FG_STEP = 2,
FG_EXP = 3
};
enum eType {
FG_VALUE = 1,
FG_DELTA = 2,
FG_BOOL = 3
}; |
Beta Was this translation helpful? Give feedback.
0 replies
-
It makes sense and it should not be too difficult to implement. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In discussion - #1099 a user was asking about a mechanism to vary the wind with altitude from a script file. I suggested adding a function in the FDM to vary the wind. However this isn't ideal, i.e. you should be able to vary the wind without having to edit every aircraft's FDM that you want to use.
If the user was running JSBSim via python or some other host environment then they could implement the logic to vary the wind from the host environment.
So I was wondering whether it would be useful to add the capability of being able to define functions within JSBSim script files, e.g.
Beta Was this translation helpful? Give feedback.
All reactions