disconnect
断开与服务器模块的连接
说明
示例
断开活动 XCP 连接
使用 CAN 模块创建一个 XCP 通道,连接该通道,然后断开它与指定服务器模块的连接。
链接 A2L 文件
a2l = xcpA2L('XCPSIM.a2l')
使用 Vector CAN 模块虚拟通道创建一个 XCP 通道。检查通道是否已连接。
xcpch = xcpChannel(a2lfile,'CAN','Vector','Virtual 1',1);
连接通道并验证其连接。
connect(xcpch) isConnected(xcpch)
ans = 1
断开通道连接并检查连接是否处于活动状态。
disconnect(xcpch) isConnected(xcpch)
ans = 0
输入参数
xcpch
— XCP 通道
XCP 通道对象
XCP 通道,指定为使用 xcpChannel
创建的 XCP 通道对象。随后,该 XCP 通道对象可以与 A2L 文件定义的指定服务器模块通信。
版本历史记录
在 R2013a 中推出
另请参阅
xcpA2L
| xcpChannel
| connect
| isConnected
MATLAB 命令
您点击的链接对应于以下 MATLAB 命令:
请在 MATLAB 命令行窗口中直接输入以执行命令。Web 浏览器不支持 MATLAB 命令。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)