楼主最近还看过
但没反应,是连接 对吗
主站程序为TITLE=³ÌÐò×¢ÊÍ
Network 1 // ͨÐŲÎÊýÉèÖÃ
// ²¨ÌØÂÊΪ9600£»ÆæУÑ飻Modbusģʽ
LD SM0.0
= L60.0
LD SM0.0
= L63.7
LD L60.0
CALL SBR1, L63.7, 9600, 1, 1, M0.0, MB1
Network 2 // Ïò´ÓÕ¾·¢ËÍÊý¾Ý
// ÏòÕ¾µØַΪ10´ÓÕ¾µÄVB2000ÆðµÄ¼Ä´æÆ÷·¢ËÍÒ»¸ö×Ö½ÚµÄÊý¾Ý
LD SM0.0
= L60.0
LD SM0.5
EU
= L63.7
LD L60.0
CALL SBR2, L63.7, 10, 1, 40001, 1, &VB2000, M0.1, MB2
Network 3 // ·¢ËÍ¿ØÖÆÐźÅ
// ½«ÆôÍ£ÐÅÏ¢´æ´¢ÔÚV2000.0ÖÐ
LD I0.0
O V2000.0
AN I0.1
= V2000.0
从站程序为TITLE=³ÌÐò×¢ÊÍ
Network 1 // ³õʼ»¯
// Modbusģʽ£»±¾Õ¾µØַΪ10£»²¨ÌØÂÊΪ9600£»½ÓÊÕÊý¾ÝµÄÆðʼµØַΪVB2000
LD SM0.1
CALL SBR1, 1, 10, 9600, 1, 0, 128, 32, 1000, &VB2000, M0.0, VB501
Network 2
LD SM0.0
CALL SBR2, M0.1, VB500
Network 3 // ½ÓÊÕÐÅÏ¢
// ½ÓÊÕ¿ØÖÆÐÅÏ¢£¬²¢ÆôÍ£µç»ú
LD V2000.0
= Q0.0
但 Q0.0不会动作