spc_cll
級別: 略有小成
精華主題: 0
發(fā)帖數(shù)量: 103 個
工控威望: 323 點(diǎn)
下載積分: 923 分
在線時間: 32(小時)
注冊時間: 2007-08-08
最后登錄: 2020-09-10
查看spc_cll的 主題 / 回貼
樓主  發(fā)表于: 2010-04-18 09:07
艾默生EC10通訊協(xié)議格式跟蹤記錄1
==================================================================================================================================
原上載密碼為空,設(shè)置上載密碼為:11111111
SND=01 11 57 FF 08 00 00 00 00 00 00 00 00 31 31 31 31 31 31 31 31 9C B2 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04
錯誤輸入時:
SND=01 11 57 FF 08 33 33 33 33 33 33 33 33 31 31 31 31 31 31 31 31 1D 78 04
RCV=01 00 06 FF B4 56 04
    01 00 34 FF D7 A1 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 34 FF D7 A1 04
    01 00 34 FF D7 A1 04

原上載密碼為:11111111
設(shè)置上載密碼為:22222222
SND=01 11 57 FF 08 31 31 31 31 31 31 31 31 32 32 32 32 32 32 32 32 45 01 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04

原上載密碼為:22222222
設(shè)置上載密碼為空:
SND=01 11 57 FF 08 32 32 32 32 32 32 32 32 00 00 00 00 00 00 00 00 EE 96 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04
======================================================================
原下載密碼為空:
設(shè)置下載密碼為:11111111
SND=01 11 59 FF 08 00 00 00 00 00 00 00 00 31 31 31 31 31 31 31 31 E8 8C 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04

原下載密碼為:11111111
設(shè)置下載密碼為:22222222
SND=01 11 59 FF 08 31 31 31 31 31 31 31 31 32 32 32 32 32 32 32 32 31 3F 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04

原下載密碼為:22222222
設(shè)置下載密碼為空:
SND=01 11 59 FF 08 32 32 32 32 32 32 32 32 00 00 00 00 00 00 00 00 9A A8 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04
===========================================================================
原監(jiān)視密碼為空:
設(shè)置監(jiān)視密碼為:11111111
SND=01 11 5B FF 08 00 00 00 00 00 00 00 00 31 31 31 31 31 31 31 31 44 93 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04

原監(jiān)視密碼為:11111111
設(shè)置監(jiān)視密碼為:22222222
SND=01 11 5B FF 08 31 31 31 31 31 31 31 31 32 32 32 32 32 32 32 32 9D 20 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04

原監(jiān)視密碼為:22222222
設(shè)置監(jiān)視密碼為空:
SND=01 11 5B FF 08 32 32 32 32 32 32 32 32 00 00 00 00 00 00 00 00 36 B7 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 34 FF D7 A1 04
===========================================================================
上載密碼為空時,上載程序
SND=01 08 58 FF 00 00 00 00 00 00 00 00 82 74 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
===========================================================================
設(shè)置PLC運(yùn)行
SND=01 00 54 FF DC 8B 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 33 FF 4E 36 04

設(shè)置PLC停止
SND=01 00 55 FF EF BA 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 33 FF 4E 36 04

設(shè)置PLC復(fù)位
SND=01 00 56 FF BA E9 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
SND=01 00 06 FF B4 56 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
    01 00 33 FF 4E 36 04

/////////////////////////////
發(fā)送的錯誤數(shù)據(jù)格式時
RCV=01 00 15 FF E2 76 04

/////////////////////////
獲取PLC信息
SND=01 00 74 FF DA 6D 04
RCV=01 00 06 FF B4 56 04    
01 00 06 FF B4 56 04    
    01 38 74 FF 00 0A-00 6B 00-0C  -00 00 00 00 00 00 00-01-00 00 00-12          -00 01       -00 00 00 00  -18    -10    -00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 22 00 00 00 00 00 00 00 00 92 3E 04
    01 38 74 FF-00 0A-00 6B 00-0C  -00 00 00 00 00 00 00-01-00 00 00-03          -00 01       -00 00 00-00  -18    -10    -00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 22 00 00 00 00 00 00 00 00 FE 76 04
    01 38 74 FF-00 0A-00 6B 00-0C  -00 00 00 00 00 00 00-00 00 00 00-00          -00 00       -00 00 00-01  -18    -10    -00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 22 00 00 00 00 00 00 00 00 86 95 04
               -型號 -版本 -  -容量                                 -最大掃描時間-當(dāng)前掃描時間         -停止-輸入點(diǎn)-輸出點(diǎn)-  
SND=01 00 06 FF B4 56 04

//////////////////
無密碼時:01 00 06 FF B4 56 04 01 38 74 FF 00 0A 00 6B 00 0C 00 00 00 00 00 00 00 01 00 00 00 03 00 01 00 00 00 00 18 10 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 22 00 00 00 00 00 00 00 00 FE 76 04
有密碼時:01 00 06 FF B4 56 04 01 38 74 FF 00 0A 00 6B 00 0C 00 00 00 00 00 00 00 01 00 00 00 12 00 01 00 00 00 00 18 10 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 22 00 00 00 00 00 00 00 00 92 3E 04

===========================================================
清除PLC錯誤信息
SND=01 00 84 FF C9 AC 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
===========================================================
清除PLC數(shù)據(jù)塊
SND=01 00 52 FF 76 2D 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04
===========================================================
上載密碼為11111111時,用空密碼建立上載通訊:
SND=01 08 58 FF 00 00 00 00 00 00 00 00 82 74 04
RCV=01 00 06 FF B4 56 04
    01 00 34 FF D7 A1 04(返回命令cmd=34,錯誤)
==輸入正確密碼11111111后:
SND=01 08 58 FF 31 31 31 31 31 31 31 31 16 1A 04
RCV=01 00 06 FF B4 56 04
    01 00 33 FF 4E 36 04(返回命令cmd=33,正確)
SND=01 00 06 FF B4 56 04 01 00 63 00 5E 79 04(開始讀PLC程序)
===總結(jié)====================================================
EC10 PLC協(xié)議格式:

起始字符01+數(shù)據(jù)長度n+CMD  +數(shù)據(jù)+校驗字符+終止字符04
01        +00       +74 FF+    +DA 6D   +04
例如:
SND=01+00+06FF+B456+04
RCV=01+38+74FF+000A006B000C0000000000000000000000000000000000011810000000000000000000000000000000000000000001220000000000000000+8695+04

/////////////////////////////////
設(shè)置上載密碼命令cmd=57
建立上載通訊命令cmd=58
設(shè)置下載密碼命令cmd=59
建立下載通訊命令cmd=5A
設(shè)置監(jiān)視密碼命令cmd=5B
建立監(jiān)視通訊命令cmd=5C
===問題=====================================================
校驗字符的計算公式是什么?
本帖最近評分記錄:
  • 下載積分:+10(wsir123) 優(yōu)秀文章