【西门子】用SCL语言设计的功能块,一键启停
01设计要求:设计一个具有一键启停功能的功能块,具有以下功能:a. 一键启停,模拟一个按钮,按一下启动,再按一下停止。b. 同时具有一个按钮启动的功能,按一下启动,再按不会停止。c. 具有定时停机的功能,按照设定好的时间自动停机。d. 具有复位功能。
02添加FB块,建立变量。如下图:
http://p1.pstatp.com/large/pgc-image/024dd7e93f814036ba132d727f3e37a1
http://p1.pstatp.com/large/pgc-image/4d9916b251444e6bb13c811bc7509658
03编写程序。如下图:
http://p1.pstatp.com/large/pgc-image/d4ee0ded108047e6afa13f98c13f574c
http://p1.pstatp.com/large/pgc-image/4d9916b251444e6bb13c811bc7509658
04调用并监控。如下图:
http://p9.pstatp.com/large/pgc-image/b033a1ba8ad046919fd1062e45c155d7
http://p1.pstatp.com/large/pgc-image/4d9916b251444e6bb13c811bc7509658
http://p1.pstatp.com/large/pgc-image/c4660994243940ae9f08f9a9d79d394c
http://p1.pstatp.com/large/pgc-image/4d9916b251444e6bb13c811bc7509658
以上数据块定义了功能块的管脚全局变量。
无私奉献,好工控人,32个赞送给你!! 谢谢楼主 强烈支持楼主ing…… 我只是路过打酱油的。
#在这里快速回复#无私奉献,好工控人,32个赞送给你!! 哈哈哈哈笑不活,楼主这脑洞绝了! 学到干货了,感谢分享,已火速收藏 说得对!狠狠赞同,没毛病~ 楼主辛苦啦,期待下一篇分享
页:
[1]
2