US Orion GN&C System Development - Model-Based Development Practice 2

US Orion GN&C System Development - Model-Based Development Practice 2

Fourth, the development of PDR to CDR

In the post-PDR phase, the GN&C and FSW teams went from the handwritten algorithm prototype to the MBD process, which created the initial version of the GN&C CSU in Simulink. In this process, the following work was mainly done: RAMSES GN&C packaging development in Simulink, empty box architecture (EBA) development providing interface between CSUs, translation of GN&C algorithms from prototype C code into Simulink module block diagram, and integration of CSU Into the framework model.

Figure 5 Typical GN&C CSU block diagram

Figure 5 shows the Simulink block diagram of a typical GN&C CSU junction box. The orange module is the CSU containing the algorithm. Its interface includes four Simulink Bus corresponding structure data types. The input and parameters Bus enter the CSU from the left, and the output and telemetry. Bus is on the right. The output signal is utilized by the downstream CSU while telemetry data is primarily used to analyze system behavior. In automatic code generation, the orange module generates a class that uses the structure data parameters corresponding to the four Bus objects.

To the left of the orange CSU is the Junction Boxes, which accept the data from the upstream CSU and other data to divide them into inputs and parameters. The orange CSU is a model reference module, which means that this is a function-independent model file, which is very important for configuration management, because the modification of this module only affects related files.

In the early days of the Simulink design process, the method of providing parameters to the Simulink model reference block was an important design decision. In this context, the input is a time varying signal that the CSU uses to generate an output. The parameters are used to configure the CSU and remain unchanged for most execution calls. This data may change when using an asynchronous event-based software pattern, but remains fixed in other cases. The control gain can be used as an example of a parameter, and the control error can be an example of an input signal. The Orion GN&C team chose to pass parameters to each CSU in the form of the parameter bus discussed above. This method has the following advantages:

1. In the block diagram, the parameter interface definition is very clear and intuitive;

2. The data type of the parameter is clearly defined using SimulinkBus;

3, the generated parameter in the parameter interface is relatively clear, as a structure body pointer is used to generate C++ code calls.

However, the main disadvantage of this is that the parameters must be placed inside the CSU like a signal. This means that many of Simulink's basic modules are not directly usable. The gain module in Figure 6 is an example. The model is the input u multiplied by the gain K to get the output y. Since the gain K is a member of the parameter Bus structure, it must enter the model as a "signal line", as shown in the figure. 6 is shown below. The addition of the harness reduces readability. In Orion, the gain module uses the hidden From module, which allows the designer to use the gain in a similar way to the diagram, but it is best to use the Simulink language as much as possible. Other ways to define parameters are allowed in the Simulink version, which is worth considering in future projects.

Figure 6 Comparison of gain parameters

Figure 7 shows a classic collection of CSUs or "domains". Each orange CSU module contains the Junction Boxes and CSU algorithms in Figure 5. This example is where the CM control field contains three CSUs for commanding the CM's reaction force propulsion device to control the CM. Each CSU receives an input from the upstream CSU.

Figure 7 contains a typical domain of the CSU module

Each domain also includes mode logic to activate or freeze the CSU based on commands received from the GN&C algorithm. During flight in the outer atmosphere and during navigation, the RCS Control is activated to provide rate conversion commands to the propulsion logic. Once in the landing phase, the RCS Control is frozen and the Touchdown Roll Control is activated to convert the CM to a downwind splash on the sea.

In the Orion project, the orange CSU is automatically generated and integrated into the GN&C as a separate functional module, so from the domain level, the Simulink block diagram does not directly generate the final flight software, but instead provides permission in Simulink. CSU development and integration interfaces and modes for closed-loop simulation in the environment.

All CSU executions in the same domain use the same rate, here 40Hz. One lesson in developing the Orion domain framework model is that categorizing similarly-rate CSUs can simplify modeling problems due to rate delays and interactions. Early domain versions include all relevant functions without considering execution rates.

All modules of similar speed are connected by wires and classified at high and low rates, as shown in Figure 8. These rate modules and other modules in the figure form the final form of the EFT-1 RAMSESSimulink development environment. Input, output and analysis data is provided by the IOP module, which is similar to the input and output ports in the flight software for providing simulation. The interface also has GN&C interfaces, including C&DH, Timeline Manager (TMG) and VehicleManager (VMG) for configuration and task segment information for the GN&C provider.

Figure 8 RAMSES Simulink environment encapsulating GN&C and FSW

In a typical MBD process, a company or organization may have an existing GN&C module algorithm library that can be directly dragged. In the Orion project, since most of the algorithm prototypes are made in C, the C algorithm needs to be translated into the Simulink model. Entering the flight phase with the most mature algorithms, so this part of the algorithm translation and integration into RAMSES is the first to do, this pathfinder plays a very important role, but also has important lessons, which puts a lot of important for MathWorks Some of the suggestions have been improved in later versions.

Scaleability

Orion's MBD tools require sufficient customizability to scale to the size of the project. The final Orion GN&C program will generate over 100,000 lines of auto-generated code. Orion's experience is that for programs of this size, Simulink products do not provide sufficient development capabilities that are immediately available. The Orion project team found that the compilation and execution rate of the RAMSES-M/A development environment declined as the CSU's scale capacity increased. As a result, Mathworks must continually develop custom tools that increase the standards and technologies required for iterations, allowing product development cycles and times to be within acceptable limits. Many of these tools, standards, and other lessons are very useful for similar projects. Since EFT-1 has scaled down the entire application, and many similar tools and technologies are already available and team members have a deeper understanding of it, future project development will be more efficient, but due to the updated Orion program, In order to isolate the flight phase or function during development, a compromise solution is still needed.

Configuration Management

Selecting the MBD process will have different configuration management requirements than handwritten code. In particular, MBD tools need to consider two aspects: separation of graphics modules and merge model changes. Earlier versions of Simulink put all the functionality in one model file (.mdl), which is not practical for large projects, because even if only a single subsystem in the model is modified, all developers should Operate with the same object. Therefore, the Orion project uses Simulink's Model Reference Block (MRB) so that a separate model file can be used to describe a subsystem by simply referencing it in the upper model. This approach has a large impact on the development phase, and it is now possible to parameterize and automate code generation for MRB. Because MRB is more necessary from the perspective of configuration management.

The merger of model changes is another important consideration in the MBD development process. These changes need to be combined when different developers make multiple changes to the same file at the same time. The text merge tool is very effective for handwritten application code, but the graphical merge tool for MBD model changes is more expensive and less efficient than text merge. The Orion project purchased a license for the graphical merge tool from a third-party vendor and found it to be useful enough, but not as efficient as a text merge tool. For development teams, the limited allocation and training of these tools limits the number of people who develop in parallel to complete the project. This is not a big problem at the CSU level, but CSU developers often make changes at the domain level, so you have to wait for other developers to complete domain-level changes or use the graphical merge tool for parallel modifications. Since the domain level changes are often in terms of interfaces, as described above and shown in Figures 5 and 7, the number of graphics merge tools can be reduced by combining the junction box with the CSU in another MRB. Also, the CSU standard requires avoiding parallel changes to the CSU. As the EFT-1 algorithm is more mature, parallel development is reduced and the need for consolidation is diminished. However, the Orion team believes that graphics consolidation capabilities remain an important requirement during the remaining flight development phases and are therefore still looking for viable solutions.

Complexity of mixed tool development

The development environment of RAMSES and its interface and simulation of handwritten code have been successfully applied in the development of Orion EFT-1. However, in the early stages of development, the use of hybrid simulation/FSW development environments was not recommended for projects where handwritten code simulation was not inherited. The Orion development environment requires a fairly complex set of scripts to start simulation and FSW processes, load simulation and FSW configuration information, and manage environment variables and other initialization projects. The environment also requires familiarity with several tools, including C code, the JSC "Trick" simulation environment, a scripting suite, and all Simulink tool suites and custom scripts. This means that new employees of the project need to start with important training before they can develop. The team is currently looking for suitable options for future flight development, including simplified scripting and configuration management tools and simplified fidelity Simulink simulation for early algorithm development.

Logging and Debugging

The Orion team's extensive customization work is done in two areas: data logging and graphical process debugging. The Simulink development tool provides options for writing data to files and MATLAB workspaces in the form of output modules. However, these choices are not data configurable, which is necessary for highly complex applications; in addition, these methods are not compatible with arrayed structure types. For the above reasons, the Orion team developed a data logging subsystem - RAMSES-M Record - to allow the user to select output parameters for subsequent analysis and debugging. Although the tool will help future Orion development, there is still a strong need to provide a common logging capability that is part of Simulink and does not require changes to the model block diagram when changing parameter configurations.

In addition, debugging in the Simulink local environment is generally more difficult. Simulink provides three independent debugging tools for Simulink, Embedded MATLAB and Stateflow. The three tools are different and each tool requires training and familiarity. The most commonly used developer is the Embedded MATLAB debugger because it provides intuitive graphical insertion breakpoints, "hover" display variables and parameter values, and more. In fact, due to the ease of eML debugging, some developers have designed the initial algorithms as large eML modules, which are then split into graphical elements that have smaller eML functions and are included in lower-level modules. The team also developed a custom eML debug module that allows execution control and observation data in the Bus between Simulink subsystem modules.

Hair Styling Products

Hair Styling Products,Quick Styling Gel,Short Hair Styling Gel,Natural Styling Gel

Guangzhou Berfly Cosmetic Co., Ltd , https://www.berflycosmetic.com