主要内容

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

建模

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

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

模块

全部展开

Digital Read blockDigital Read读取数字输入引脚的逻辑状态
Digital Write blockDigital Write设置数字输出引脚的逻辑状态
Analog Input blockAnalog InputMeasure voltage of analog input pin
PWM Output blockPWM Output在指定输出引脚上生成方波
I2C Controller Read blockI2C Master Read从 I2C 外围设备或 I2C 外围设备寄存器读取数据
I2C Controller Write blockI2C Master Write向 I2C 外围设备或 I2C 外围设备寄存器写入数据
SPI Register Read blockSPI Register Read从 SPI 外围设备寄存器读取数据
SPI Register Write blockSPI Register Write向 SPI 外围设备寄存器写入数据
SPI Controller Transfer blockSPI Master Transfer向 SPI 外围设备写入数据并从其读取数据
SCI Read blockSCI Read在 UART 上读取 N×1 数据数组
SCI Write blockSCI Write将 N×1 数据数组发送到 UART
MMA8652FC 3-Axis Accelerometer blockMMA8652FC 3-Axis AccelerometerGet measurement of linear acceleration along the X, Y, and Z axes of the MMA8652FC 3-Axis chip
Accelerometer X-Y-Z blockAccelerometer X-Y-ZGet measurement of linear acceleration along the X, Y, and Z axes of the Accelerometer (自 R2023b 起)
MAG3110 3-Axis Magnetometer blockMAG3110 3-Axis MagnetometerGet measurement of magnetic field along the X, Y, and Z axes of the MAG3110 3-Axis chip
Magnetometer X-Y-Z blockMagnetometer X-Y-ZGet measurement of magnetic field along the X, Y, and Z axes of the Magnetometer (自 R2023b 起)
5x5 LED Matrix block5x5 LED MatrixOutput 5x5 LED image on board
LED Text Scroll blockLED Text ScrollCreate scrolling text for BBC micro:bit
Radio Receive blockRadio ReceiveReceive data from micro:bit devices via radio
Radio Transmit blockRadio Transmit通过无线电向 micro:bit 设备传输数据
Note Generator blockNote GeneratorGenerate frequency corresponding to a musical note
Play Note blockPlay NotePlay musical note on specified pin on BBC micro:bit

主题