最近在學習Arduino,買了一塊Arduino UNO R3的開發板,也買了兩片Arduino 328p的芯片。
02 板子.jpg (1.2 MB, 下載次數: 27)
下載附件
2024-5-19 23:38 上傳
04 ATmega328P.jpg (152.21 KB, 下載次數: 31)
下載附件
2024-5-19 23:38 上傳
按網上的方法,將開發板改造成Arduino ISP 編程器。
08 將UNO板改造成ISP下載器.jpg (100.93 KB, 下載次數: 27)
下載附件
2024-5-19 23:39 上傳
09 設置開發板.jpg (94.6 KB, 下載次數: 24)
下載附件
2024-5-19 23:39 上傳
10 將ISP程序下載到開發板.jpg (89.15 KB, 下載次數: 28)
下載附件
2024-5-19 23:40 上傳
然后,再用Arduino 328p 的芯片制作了一個最小系統。
05 轉接板.jpg (151.82 KB, 下載次數: 35)
下載附件
2024-5-19 23:40 上傳
06 最小系統.jpg (251.19 KB, 下載次數: 43)
下載附件
2024-5-19 23:40 上傳
將開發板與自己制作的最小系統相連:
16 開發板與最小系統連接方法.jpg (65.93 KB, 下載次數: 32)
下載附件
2024-5-19 23:41 上傳
14 開發板與最小系統.jpg (208.5 KB, 下載次數: 28)
下載附件
2024-5-19 23:41 上傳
先將引導程序通過開發板下載到最小系統,成功了。
11 燒錄引導程序到最小系統.jpg (91.25 KB, 下載次數: 33)
下載附件
2024-5-19 23:42 上傳
寫了一個簡單的LED閃爍的程序,通過開發板下載到最小系統板,也成功了。
12 利用開發板下載程序到最小系統.jpg (78.84 KB, 下載次數: 32)
下載附件
2024-5-19 23:42 上傳
本來用開發板制作的ISP編程器下載軟件也是可以的,但我想自己用CH340制作一個。
現在的問題是,通過CH340C制作的編程器下載程序到最小系統,始終不成功。
電路原理圖如下:
15 CH340C與Arduino.jpg (322.86 KB, 下載次數: 26)
下載附件
2024-5-19 23:43 上傳
下載時顯示如下錯誤信息:
*****************************
Arduino:1.8.19 (Windows 7), 開發板:"Arduino Uno"
項目使用了 934 字節,占用了 (2%) 程序存儲空間。最大為 32256 字節。全局變量使用了9字節,(0%)的動態內存,余留2039字節局部變量。最大為2048字節。
avrdude: stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 1 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 2 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 3 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 4 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 5 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 6 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 7 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 8 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 9 of 10: not in sync: resp=0xd1avrdude:
stk500_recv(): programmer is not respondingavrdude:
stk500_getsync() attempt 10 of 10: not in sync: resp=0xd1Problem
uploading to board. See hc/en-us/sections/360003198300 for suggestions.
*****************************
意思是:“程序員沒有回應avrdude:”
也試過左邊CH340C部分,給STC單片機下載程序是沒有問題的,無非是在下載程序時要“冷啟動”一下STC的單片機。
在給Arduino最小系統下載程序時,也按過復位開關,也不行。
分析了Arduino UNO開發板的電路,它也是用CH340C的下載電路,本來CH340C可以不用外接晶振的,但它接了。
我也在自制的CH340C電路中加上了晶振部分,但還是不行。
請懂的朋友幫幫我,謝謝了。
|