<meter id="pryje"><nav id="pryje"><delect id="pryje"></delect></nav></meter>
          <label id="pryje"></label>

          新聞中心

          EEPW首頁 > 嵌入式系統(tǒng) > 設(shè)計(jì)應(yīng)用 > 嵌入式學(xué)習(xí)筆記19——AVR單片機(jī)之C51向ICCAVR的移植

          嵌入式學(xué)習(xí)筆記19——AVR單片機(jī)之C51向ICCAVR的移植

          作者: 時(shí)間:2016-11-19 來源:網(wǎng)絡(luò) 收藏
          1.頭文件,把reg51.h,reg52.h替換成相應(yīng)的AVR頭文件,如iom16v.h等。

          2.對(duì)C51中的bit,sbit的數(shù)據(jù)類型進(jìn)行處理,因?yàn)?strong>ICCAVR不支持bit和sbit數(shù)據(jù)類型,可以用位運(yùn)算和BIT來處理。分別定義置1和清零的宏,使用BIT需加“#include”。

          本文引用地址:http://www.ex-cimer.com/article/201611/318412.htm

          3.IO的操作。

          4.中斷系統(tǒng),定時(shí)器等與單片機(jī)結(jié)構(gòu)密切相關(guān)的代碼,需要重新修改。

          5.和延時(shí)、定時(shí)相關(guān)的函數(shù)需要進(jìn)行一些改變,因?yàn)锳VR的運(yùn)算速度比51單片機(jī)要快得多。

          6.其余與CPU體系結(jié)構(gòu)無關(guān)的代碼,可以直接使用。



          評(píng)論


          技術(shù)專區(qū)

          關(guān)閉
          看屁屁www成人影院,亚洲人妻成人图片,亚洲精品成人午夜在线,日韩在线 欧美成人 (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })();