CAX{}@P7FPO$`{JW~WWIUSY.png (20.92 KB, 下載次數: 46)
7.24 KB, 下載次數: 3
啤酒瓶子老大 發表于 2021-3-15 23:31
可以用一個數組。LED[]={0X01,......}
FOR
{然后P2=LED[];}
yzwzfyz 發表于 2021-3-15 22:33
不要用直接用:P2.0-7
先設8個燈為:L1-L8,將你需的顯示的形式一一列出:
如
mengzhixinheng 發表于 2021-3-17 13:55
uchar tab[]={0,0x80,0xc0,0xe0,0xf0,0xf8,0xfc,0xfe};
for(j=8;j>0;j--)
for{k=0;k
mengzhixinheng 發表于 2021-3-17 13:55
uchar tab[]={0,0x80,0xc0,0xe0,0xf0,0xf8,0xfc,0xfe};
for(j=8;j>0;j--)
for{k=0;k
mengzhixinheng 發表于 2021-3-17 13:55
uchar tab[]={0,0x80,0xc0,0xe0,0xf0,0xf8,0xfc,0xfe};
for(j=8;j>0;j--)
for{k=0;k
1045964948 發表于 2021-3-17 22:33
但是流到第八位沒辦法常亮,我再思考思考,謝謝
光說不練 發表于 2021-3-16 17:51
8乘8等于64種花樣,即64個數據,每次讀出延時一下就能實現。
mengzhixinheng 發表于 2021-3-17 13:55
uchar tab[]={0,0x80,0xc0,0xe0,0xf0,0xf8,0xfc,0xfe};
for(j=8;j>0;j--)
for{k=0;k
| 歡迎光臨 (http://m.raoushi.com/bbs/) | Powered by Discuz! X3.1 |