機(jī)電之家資源網(wǎng)
單片機(jī)首頁(yè)|單片機(jī)基礎(chǔ)|單片機(jī)應(yīng)用|單片機(jī)開(kāi)發(fā)|單片機(jī)文案|軟件資料下載|音響制作|電路圖下載 |嵌入式開(kāi)發(fā)
培訓(xùn)信息
贊助商
stc單片機(jī)下載協(xié)議研究
stc單片機(jī)下載協(xié)議研究
 更新時(shí)間:2009-10-30 15:01:56  點(diǎn)擊數(shù):0
【字體: 字體顏色

眾所周知stc單片機(jī)是用串口下載的,他的下載協(xié)議我們一直不得而知,于是我用一個(gè)軟件截取了串行口的數(shù)據(jù)并進(jìn)行了簡(jiǎn)單的分析,(左邊為16進(jìn)制的數(shù)據(jù),右邊為文本顯示)哪位51hei的大俠,按照這個(gè)給寫(xiě)個(gè)下載程序出來(lái),共享給大家啊,

下面的內(nèi)容是串口截取的數(shù)據(jù)

讀:

Port opened

Baud rate set to 9600

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
68 00 1C 00 29 FA 29 FE 29 FA 29 FA 29 FA 29 FA h...)ú)t)ú)ú)ú)ú
29 FE 29 FA 32 43 FD F1 08 82 91 16 )t)ú2Cy?.??.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 68 00 0C 8F FF FA 00 0C 28 80 B0 16 F1h..??ú..(?°.
Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 68 00 0B 8E FF FA 00 0C 17 1D 16 46 B9 68 F1h..??ú.....F1h
00 06 80 EE 16 46 B9 68 00 06 80 EE 16 46 B9 68 ..??.F1h..??.F1h
00 06 80 EE 16 46 B9 68 00 06 80 EE 16 46 B9 68 ..??.F1h..??.F1h
00 06 80 EE 16 ..??.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 68 00 06 80 EE 16 46 B9 68 00 07 80 00 EF F1h..??.F1h..?.?
16 46 B9 68 00 07 80 A1 90 16 46 B9 68 00 07 80 .F1h..???.F1h..?
00 EF 16 46 B9 68 00 07 80 00 EF 16 46 B9 68 00 .?.F1h..?.?.F1h.
07 80 00 EF 16 46 B9 68 00 06 80 EE 16 .?.?.F1h..??.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed


寫(xiě):

Port opened

Baud rate set to 9600

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 7F 
7F 7F 7F 7F 7F 7F 
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 6A 00 0C 8F FF FA 00 0C 28 80 B2 16 F1j..??ú..(?2.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8

Port closed

Port opened

Baud rate set to 1200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 6A 00 0B 8E FF FA 00 0C 17 1F 16 F1j..??ú.....
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 6A 00 06 80 F0 16 46 B9 6A 00 06 80 F0 16 F1j..?e.F1j..?e.
46 B9 6A 00 06 80 F0 16 46 B9 6A 00 06 80 F0 16 F1j..?e.F1j..?e.
46 B9 6A 00 06 80 F0 16 F1j..?e.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 6A 00 0D 84 01 33 33 33 33 33 33 2E 16 46 F1j..?.333333..F
B9 6A 00 8C 00 00 00 02 00 00 80 00 00 00 00 00 1j.?......?.....
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 78 16 46 B9 6A ...........x.F1j
00 8C 00 00 00 00 00 00 80 02 00 03 78 7F E4 F6 .?......?...x??
D8 FD 75 81 07 02 00 0F 75 A0 55 80 FE 00 00 00 ?yu?....u U?t...
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 17 16 46 B9 6A 00 8C ...........F1j.?
00 00 00 00 80 00 80 00 00 00 00 00 00 00 00 00 ....?.?.........
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 F6 16 46 B9 6A 00 8C 00 00 .......?.F1j.?..
00 01 00 00 80 00 00 00 00 00 00 00 00 00 00 00 ....?...........
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 77 16 46 B9 6A 00 8C 00 00 00 01 .....w.F1j.?....
80 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 ?.?.............
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
00 00 00 F7 16 46 B9 6A 00 06 82 F2 16 46 B9 6A ...÷.F1j..?ò.F1j
00 08 52 02 00 C6 16 ..R..?.
Port closed

Port opened

Baud rate set to 115200

StopBits: 1 stop bit, Parity: No parity, WordLength: 8
46 B9 6A 00 06 82 F2 16 46 B9 6A 00 08 52 02 00 F1j..?ò.F1j..R..
C6 16 ?.
Port closed


1.上:發(fā)送 7F 下載命令
2.下:
回應(yīng):
68 00 1C 00 29 FA 29 FA 29 FA 29 FA 29 FA 29 FA 29 FA 29 FE 32 43 FD F1 08 82 8D 16
3.上:
46 B9 6A 00 0C 8F FF FA 00 0C 28 80 B2 16

  • 上一篇: 單片機(jī)一鍵多功能按鍵識(shí)別技術(shù)
  • 下一篇: 沒(méi)有了
  • 發(fā)表評(píng)論   告訴好友   打印此文  收藏此頁(yè)  關(guān)閉窗口  返回頂部
    熱點(diǎn)文章
     
    推薦文章
     
    相關(guān)文章
    網(wǎng)友評(píng)論:(只顯示最新5條。)
    關(guān)于我們 | 聯(lián)系我們 | 廣告合作 | 付款方式 | 使用幫助 | 機(jī)電之家 | 會(huì)員助手 | 免費(fèi)鏈接

    點(diǎn)擊這里給我發(fā)消息66821730(技術(shù)支持)點(diǎn)擊這里給我發(fā)消息66821730(廣告投放) 點(diǎn)擊這里給我發(fā)消息41031197(編輯) 點(diǎn)擊這里給我發(fā)消息58733127(審核)
    本站提供的機(jī)電設(shè)備,機(jī)電供求等信息由機(jī)電企業(yè)自行提供,該企業(yè)負(fù)責(zé)信息內(nèi)容的真實(shí)性、準(zhǔn)確性和合法性。
    機(jī)電之家對(duì)此不承擔(dān)任何保證責(zé)任,有侵犯您利益的地方請(qǐng)聯(lián)系機(jī)電之家,機(jī)電之家將及時(shí)作出處理。
    Copyright 2007 機(jī)電之家 Inc All Rights Reserved.機(jī)電之家-由機(jī)電一體化網(wǎng)更名-聲明
    電話:0571-87774297 傳真:0571-87774298
    杭州濱興科技有限公司提供技術(shù)支持

    主辦:杭州市高新區(qū)(濱江)機(jī)電一體化學(xué)會(huì)
    中國(guó)行業(yè)電子商務(wù)100強(qiáng)網(wǎng)站

    網(wǎng)站經(jīng)營(yíng)許可證:浙B2-20080178-1