在线看毛片网站电影-亚洲国产欧美日韩精品一区二区三区,国产欧美乱夫不卡无乱码,国产精品欧美久久久天天影视,精品一区二区三区视频在线观看,亚洲国产精品人成乱码天天看,日韩久久久一区,91精品国产91免费

<menu id="6qfwx"><li id="6qfwx"></li></menu>
    1. <menu id="6qfwx"><dl id="6qfwx"></dl></menu>

      <label id="6qfwx"><ol id="6qfwx"></ol></label><menu id="6qfwx"></menu><object id="6qfwx"><strike id="6qfwx"><noscript id="6qfwx"></noscript></strike></object>
        1. <center id="6qfwx"><dl id="6qfwx"></dl></center>

            新聞中心

            EEPW首頁(yè) > 嵌入式系統(tǒng) > 設(shè)計(jì)應(yīng)用 > 使用IAR如何修改STM8S庫(kù)(一)

            使用IAR如何修改STM8S庫(kù)(一)

            作者: 時(shí)間:2016-11-24 來(lái)源:網(wǎng)絡(luò) 收藏
            注意:以下修改在IAR for STM8 1.10 SP3下驗(yàn)證,庫(kù)文件為IAR自帶的1.1.1

            1、選擇CPU類型(支持STM8S系列設(shè)備)

            本文引用地址:http://www.biyoush.com/article/201611/320848.htm

            stm8s.h

            ...

            /* Uncomment the line below according to the target STM8S device used in your

            application.

            Tip: To avoid modifying this file each time you need to switch between these

            devices, you can define the device in your toolchain compiler preprocessor. */

            #if !defined (STM8S208) && !defined (STM8S207) && !defined (STM8S105) && !defined (STM8S103) && !defined (STM8S903)

            #define STM8S208

            /* #define STM8S207 */

            /* #define STM8S105 */

            /* #define STM8S103 */

            /* #define STM8S903 */

            #endif

            根據(jù)你的CPU類型選擇宏定義,比如我這里用的是105系列,則修改為:

            /* #define STM8S208 */

            /* #define STM8S207 */

            #define STM8S105

            /* #define STM8S103 */

            /* #define STM8S903 */

            選擇好CPU類型后,還需查看選擇的類型中哪些外設(shè)是包含的哪些外設(shè)沒(méi)有包含,將沒(méi)有包含的外設(shè)驅(qū)動(dòng)c文件在工程中去掉

            如105系列沒(méi)有adc2、can、uart1、uart3

            2、修改stm8s_conf.h文件

            選擇好CPU類型后,接下來(lái)就是選擇要使用的外設(shè)了,stm8s_conf.h就是外設(shè)驅(qū)動(dòng)選擇開(kāi)關(guān),在用戶函數(shù)中,只需包含此頭文件即可。

            比如程序中需要使用到SPI外設(shè),則將此文件的

            /************************************* SPI ************************************/
            /* #define _SPI (1) */

            修改為:

            /************************************* SPI ************************************/
            #define _SPI (1)



            關(guān)鍵詞: IARSTM8S

            評(píng)論


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

            關(guān)閉