![]() |
發布時間: 2019-1-22 17:25
正文摘要:單片機源碼: #include<reg52.h> #include "intrins.h"//_nop_()延時函數使用 typedef unsigned char uchar; typedef unsigned int uint; extern uchar lowEightBit[2],highEightBit[2];   ... |
新手啊啊啊啊 發表于 2019-1-22 17:28 extern uchar lowEightBit[2],highEightBit[2];//多了extern |
本帖最后由 weidoit 于 2019-1-23 13:09 編輯 //extern uchar lowEightBit[2],highEightBit[2]; /*用于存儲 2 個通道的數據,每個通道兩個字節*/ /*第5行去掉 extern */ uchar lowEightBit[2],highEightBit[2]; /*用于存儲 2 個通道的數據,每個通道兩個字節*/Keil編譯通過,Proteus 仿真如圖。 ![]() 0x 02 00>>2 = 0x80= 128(DEC) 0x0200%0x04=0 0/4=0 0x 02 05>>2 = 0x81= 129 (DEC) 0x0205%0x04=1 1/4=0.25 129+0.25=129.25 |
8處警告。。全是loweightbit 和 higheightbit ,到底是定義數組出了問題還是下面引用出了問題呢? 上面是整個程序,是用兩個6675芯片實現測溫,然后把數據傳到串口的功能,有大佬幫忙看看哪里有問題嗎? |
有8處警告。。全是loweightbit higheightbit,到底是定義數組出了問題還是下面引用出了問題呢? |