Composite Signals
使用综合信号(例如总线)进行分组信号并降低模型复杂性
为了简化模型外观,使用这些技术将单个信号组合为复合信号:
Virtual buses
Nonvirtual buses
MUX信号
Concatenated signals
For a detailed comparison of composite signals, see复合信号的类型.
虚拟巴士符合大多数建模要求,将信号组合到复合信号中,并为您提供组合不同类型的信号的灵活性。
块
Functions
工具
公交编辑 | 创造, modify, and manage bus objects |
Model Explorer | View, modify, and add elements of万博1manbetxmodels,Stateflowcharts, and workspace variables |
Topics
Composite Signal Basics
Visually Group Lines
- 小组信号线进入虚拟巴士
Combine signals into virtual buses, which only affect visual appearance. - Simplify Subsystem and Model Interfaces with Buses
Use In Bus Element and Out Bus Element blocks for bus inputs and outputs. - Display Bus Information
Display information about buses, such as signal hierarchy and whether the bus is virtual or nonvirtual. - 确定自动巴士转换
Recognize modeling patterns that cause hiddenBus To Vector和信号转换块。
修改和配置总线
- Modify Bus Hierarchy
更改嵌套公共汽车及其元素的顺序和层次结构。 - Assign Signal Values to Bus Elements
Use aBus Assignmentblock to replace signals assigned to bus elements. - Specify Initial Conditions for Bus Elements
将总线元素值指定为总线的初始条件。 - Share and Reuse Bus-Routing Blocks
共享使用子系统参考或自定义库来创建或与总线交互的块。
Define Bus Object Data Types
- Specify Bus Properties with Simulink.Bus Object Data Types
理解Simulink.Bus
object uses and implementation. - 创造Bus Objects Programmatically
使用功能和类定义Bus
对象和总线元素,从块创建总线对象或创建Bus
objects from MATLAB®data.
Functionally Group Lines
- 创造Nonvirtual Buses
创造buses that appear in generated code and support modeling constructs such as arrays of buses. - Modify Sample Times for Nonvirtual Buses
Make the sample time of signals the same so that you can group them in a nonvirtual bus. - Generate Code for Nonvirtual Buses
Use a structure in code generation to represent a nonvirtual bus. Control data types of initial condition structure fields. - Inspect Generated Code for Nonvirtual Buses
在生成的代码中找到一个简单模型的代码中的非虚拟总线。
简化迭代处理
- 在公共汽车阵列中的集体非虚拟巴士
Streamline a model by combining nonvirtual buses that have the same data type into an array. - Work with Arrays of Buses
Set up your model to use an array of buses to select signals, assign values to a signal, perform iterative processing, log and load signals, and initialize signals. - 挂rt Models to Use Arrays of Buses
挂rt an existing model that does not use arrays of buses to use arrays of buses.