当前位置:网站首页>倍福PLC--C#ADS通信以通知的方式读取变量
倍福PLC--C#ADS通信以通知的方式读取变量
2022-07-23 05:58:00 【黄昏和星空】
在C#和倍福PLC通信时候,需要将变量读取,但频繁刷新可能导致空数据的传输,所以可以以通知的方式读取,即PLC中检测到变量发生改变时候,才将变量的值传给C#。本文介绍其实现方式。
- 操作流程
1.1. PLC程序设计
1.2. C#程序设计
首先需要创建变量的通知句柄,其作用是根据变量的类型在C#程序中做出相应的处理或赋值,如下所示
开启通知按钮,即在窗体中创建按钮,按下之后启用通知的服务,如下所示


通知关闭按钮,则关闭通知句柄,如下所示

实际程序运行如下:

边栏推荐
- 雷达导论PART VII.2 成像方法
- redis分布式锁实践
- Static route configuration instance learning record
- Common CMD commands to quickly open programs
- 信號完整性(SI)電源完整性(PI)學習筆記(三十二)電源分配網路(四)
- SFTP deployment configuration
- 信号完整性(SI)电源完整性(PI)学习笔记(三十二)电源分配网路(四)
- 方法区、永久代、元空间的关系
- FTP configuration instance learning record
- 【NOI模拟赛】不知是哪一道CF的论文题(概率期望,鞅的停时定理)
猜你喜欢
随机推荐
Three layer switching configuration example learning record
How to prevent repeated payment of orders?
HCIA----02
Rip configuration instance learning record
ZABBIX monitoring detailed installation to deployment
Make local apt source offline installation
CAN控制器的位同步过程
Step on the electric render process renderer to solve the problem of require is not defined
Single arm routing configuration instance learning record
【JZOF】09用两个栈实现队列
Li Kou 729. My schedule I
软件测试岗位饱和了?自动化测试是新一代‘offer’技能
ACL access control experiment
Machine learning: Li Hang - statistical learning method (II) perceptron + code implementation (primitive + dual form)
Plug ins used by Jenkins
Ronge answer script production (latest in 2020)
OpenCV 视频操作
How does redis implement persistence? Explain in detail the three triggering mechanisms of RDB and their advantages and disadvantages, and take you to quickly master RDB
用户与组的管理、文件的权限
HCIA----05 RIP









