Unreal Engine, Anyways of connecting the 3 axis to a PID controller? #959
-
I'm relatively new to this plugin and I've been exploring it a bit, I was wondering, if is it possible to connect the 3-axis to a PID controller. |
Beta Was this translation helpful? Give feedback.
Answered by
gallonmate
Sep 17, 2023
Replies: 2 comments 1 reply
-
@galleon, @AlbanBERGERET-Epic, @demonixis any hints to provide to @Yaman-dot ? |
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Yaman-dot
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes anything is possible. More specific details would be useful to answer your question.
Where in Unreal do you want to create the pid controller?
If you want to use Blueprints. Then take a look at the reference project's BP_Airliner. In the main graph there is the Tick event, which then goes to Aileron, Elevator and Rudder Inputs. Those inputs are then being applied in the section right below those nodes. The node "Set members in FlightControlCommands" when then goes to set the Commands struct of the JSBSimMovementComponent. You can connect you pid output in the same way. Everytime the engine ticks, it takes the entire Commmands struct and applys those commands directly to JSBSim.
If yo…