发布于 2009-05-04 13:05:35
0楼
“Depending on the network you are working with, the Program Editor
either generates the UC instruction or the CC instruction during
conversion from the Ladder Logic programming language to the statement List programming language. You should attempt to use the
CALL instruction instead to avoid errors occurring in your programs.”
上面这段话引自STEP7帮助,大致的意思是说在做LAD到STL转换的时候,软件可能会生成UC或者CC指令,但这个调用调用的可能是一个FB块,就需要使用CALL指令去替换掉UC或才CC指令。
我在PLC上测试了一下,OB1中指令如下:
uc fb1//FB1定义时就没有参数。
用UC调用FB块,编译没问题,下载后也没有问题。
但如果FB1有一个参数,则下载后报错。