How to send new inputs on Pack net_fdm Packet for FlightGear?

조회 수: 14 (최근 30일)
First, I would like to thank MathWorks for providing Aerospace Blockset™ software and for providing ways to interface with FlightGear Simulator.
I am currently developing an aircraft that features several rotors (8 lifters + 1 pusher) and control surfaces (1 rudder, 2 elevators, 2 ailerons), so the various input options available in Pack net_fdm Packet for FlightGear block are insufficient to perform the animation of the aircraft model.
I wonder if there is a means in which we can specify our own inputs from the Pack net_fdm Packet for FlightGear.
In a thwarted attempt I searched the saerofgpacknetfdm code in order to add new inputs to the message to be sent to FlightGear Simulator, however it is already compiled in mexw64 format, which made it impossible to add any form of new inputs.
Could you indicate any possible means of modifying or creating our own pack net_fdm via MATLAB/Simulink?

채택된 답변

Gabriel Henrique Costa e Silva
Gabriel Henrique Costa e Silva 2023년 1월 12일
편집: Gabriel Henrique Costa e Silva 2023년 1월 12일
Through the article published by Marco Sagliano whose title is "Open-Source Visualization of Reusable Rockets Motion: Approaching Simulink - FlightGear Co-simulation" is presented how to send, via Simulink to FlightGear, 20 states (signals). These signals can be specified according to the users need creating a xml configuration file (generic protocol). In the article, which is public available, the necessary codes for implementation and explanations are presented.
For the Mathworks team: it might be interesting to add in simulink's Aerospace Blockset library a block that implements what was indicated in the article, at least for me it was very interesting to have a component that allows the freedom for sending signals that can be structured "in the FlightGear side" via generic protocol.

추가 답변 (1개)

Shivam Malviya
Shivam Malviya 2023년 1월 10일
Hi Gabriel,
I understand you wish to visualize the aircraft simulation in FlightGear using the "Pack net_fdm Packet for FlightGear" block, and you need more input ports in the "Pack net_fdm Packet for FlightGear" block to be able to do that.
The "Pack net_fdm Packet for FlightGear" block accepts all signals supported by the FlightGear net_fdm data packet. These signals are divided into six groups:
  • Position/attitude inputs
  • Velocity/acceleration inputs
  • Control surface position inputs
  • Engine/fuel inputs
  • Landing gear inputs
  • Environment inputs
To enable the inputs for these groups, select the associated block parameter. The block input ports change depending on the requested signal groups. Refer to the following image for a better understanding.
Execute the following commands to open the example model, which uses all the input ports of the "Pack net_fdm Packet for FlightGear" block.
asbhl20
open_system("asbhl20/Viewer and Feedback/FlightGear/Pack net_fdm Packet for FlightGear")
Refer to the following links for a better understanding
Hope this helps!
Regards,
Shivam Malviya
  댓글 수: 1
Gabriel Henrique Costa e Silva
Gabriel Henrique Costa e Silva 2023년 1월 12일
편집: Gabriel Henrique Costa e Silva 2023년 1월 12일
Hi Shivam,
I would like to thank you for your attention and detailed response.
However, even when enabling the other signals by the "Pack net_fdm Packet for FlightGear" the block doesn't present the specific signals for my application (I need several inputs for signals for the multiple rotors due to the unusual configuration of the aircraft I am studying).
I'll detail in a new answer how I was able to get what I needed.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Flight Simulator Interfaces에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by