您现在所在的是:

西门子SIEMENS

回帖:1个,阅读:901 [上一页] [1] [下一页]
* 帖子主题:

通道诊断程序求助

1099
zdh1911
文章数:56
年度积分:50
历史总积分:1099
注册时间:2007/12/28
发站内信
发表于:2008/12/23 15:13:00
#0楼
SET                               // Initialization of channel fault flag
     R     #TMP_AI_CH_Fault
//Channel Diagnostic

     OPN   "COM_DB_HW_IN_Diag"     // Open analog input diagnostic memory area
     L     P##IN_PIW_Address           // Load input card address
     T     #TMP_PIW_PNT             // Save analog input address into local pointer
     SRD   24                     // Move the variable area type into the ACCU1 LSB
     L     W#16#80                // IF variable area type is a PIW
     <I    
     JC    COFF
     TAK  
     L     W#16#81               // OR variable area type is a IW
     >I    
     JC    COFF                        // THEN the system enables the channel diagnostic
     L     #TMP_PIW_PNT
     L     2                           // Get analog input diagnostic bit address
     /I    
     SRD   3
     LAR1                              // Point to analog input diagnostic bit
     A     DBX [AR1,P#0.0]             //
     =     #TMP_AI_CH_Fault            // Analog input channel fault
COFF: NOP   0

有谁好好帮我分析一下上面的代码 问什么要这么做  偶是初学  刚学plc没有几天!


还有就是
网络中只有这个
SET
SAVE
就上面的语句是什么意思????


希望高手指点!!!
1099
zdh1911
文章数:56
年度积分:50
历史总积分:1099
注册时间:2007/12/28
发站内信
发表于:2008/12/23 15:16:00
#1楼
我一直在等候呀!

关于我们 | 联系我们 | 广告服务 | 本站动态 | 友情链接 | 法律声明 | 非法和不良信息举报

工控网客服热线:0755-86369299
版权所有 工控网 Copyright©2025 Gkong.com, All Rights Reserved

31.2002