设备驱动模块
创建设备驱动模块以访问硬件板的特定功能
设备驱动模块是一种专用形式的 MATLAB System 模块,当部署到 Intel® SoC 设备时,它会生成自定义 C/C++ 代码。设备驱动模块使用户能够轻松访问硬件板的功能,如通信协议或硬件库,而这些功能在 Embedded Coder® Support Package for Intel SoC 设备 中没有提供。
本指南介绍了开发设备驱动模块的完整过程,包括从使用 System object 模板开始创建到与其他用户共享完成的模块。
主题
- 前提条件
了解为基于 ARM® Cortex®-A 的硬件板开发设备驱动模块的系统要求和推荐技能。
- Structure of Device Driver System Object
Understand the concepts and operation of device driver blocks implemented using System object™.
- Simulation with Device Driver Blocks
Choose and implement a data simulation mode for device driver blocks.
- Sharing Device Driver Blocks with Other Users
Package and distribute your device driver blocks.
- 创建 Digital Write 模块
使用 System object 创建 Digital Write 模块。
- 创建 Digital Read 模块
使用一个 System object 创建 Digital Read 模块。
- Block Mask
Create block masks for your device driver blocks.
- 步骤 1: Add Description for Users
- 步骤 2: Add Pin Number Property
- 步骤 3: Add Push Button to View Pin Map