2
13
673
高级会员
so*** 发表于 2024-8-4 21:15 先用位移法看一下能不能正常,P6=~(0x01
使用道具 举报 送花
8
318
1835
金牌会员
39
2010
6859
论坛元老
u8 code ledNum[]={0x01,0x02,0x04,0x08,0x10,0x20,0x40,0x80}; while(1) { P6 = ~ledNum[ledIndex]; //输出低驱动 ledIndex++; if(ledIndex > 7) { ledIndex = 0; } delay_ms(250); delay_ms(250); }复制代码
4
344
1642
23
296
1168
19
37
236
中级会员
乘风飞扬 发表于 2024-8-5 08:59 实验箱例程包里面的跑马灯例子就是用数组,直接用例子试试。测试正常后再进行修改或者移植。 ...
本版积分规则 发表回复 回帖后跳转到最后一页
|手机版|小黑屋|深圳国芯人工智能有限公司 ( 粤ICP备2022108929号-2 )
GMT+8, 2025-5-7 14:14 , Processed in 0.121608 second(s), 109 queries .
Powered by Discuz! X3.5
© 2001-2025 Discuz! Team.