![]() |
發布時間: 2023-5-28 01:05
正文摘要:#include"reg51.h" sbit RS=P3^0; sbit RW=P3^1; sbit E=P3^2; sbit DQ=P3^3; unsigned int readtemp=0; unsigned char str[]={"0123456789"}; unsigned char s[]={"Temperature:"}; void delay_18B20( ... |
LCD1602的數據端口 與 單片機的驅動端口 連接錯誤。 代碼中,顯示驅動端口是P2 實際仿真圖中卻沒有與P2連接。 P2.0 ---D0 P2.1-----D1 .......P2.7 ------ D7 |
1.缺少函數ReadOneChar()2.LCD初始化函數名不符 3.顯示函數中 temp1、temp2沒有賦值 4.顯示固定字符代碼的位置不當 5.仿真中1602數據接口連接與程序不符 ![]()
|