主要内容

本页翻译不是最新的。点击此处可查看最新英文版本。

建模

R2026a
为硬件连接准备模型,添加模块以支持硬件协议

准备 Simulink® 模型以进行硬件连接,添加模块以支持硬件协议,提供各种应用情形的参考示例。

模块

Digital Output blockDigital OutputSet the logical value of a digital output pin
Digital Input blockDigital InputRead the logical value of a digital input pin
RGB LED blockRGB LED将 RGB LED 设置为所需颜色
Serial Receive blockSerial ReceiveReceive an [Nx1] array of byte data on the UART
Serial Transmit blockSerial TransmitSend an [MxN] array of data to the UART
Analog Output blockAnalog Output向 PTE30 引脚发送模拟输出信号
Analog Input blockAnalog InputMeasure the voltage of an analog input pin
Servo Write blockServo WriteDrive the servo motor to the specified angle
Line Scan Camera blockLine Scan CameraRead the data from a line scan camera
Momentary Switch blockMomentary SwitchRead the state of a momentary switch
DIP Switch blockDIP SwitchRead the state of a DIP switch
DC Motor blockDC MotorDrive a DC motor in either direction
Potentiometer blockPotentiometer读取电位计的状态
Battery Read blockBattery ReadRead the battery voltage of a battery connected to the TFC Shield
Battery Indicator blockBattery IndicatorDisplay the battery voltage level with LEDs on the TFC shield
I2C Controller Read blockI2C Controller ReadRead data from I2C peripheral device or I2C peripheral device register
I2C Controller Write blockI2C Controller WriteWrite data to I2C peripheral device or I2C peripheral device register
PWM Output blockPWM OutputGenerate square wave on the specified output pin

主题