Trích:
Nguyên văn bởi tdm
int a,i=0x00;//gán i=0x00 ngay tại đầu ct sẽ hết lỗi (1)
lỗi (2):
viết lại như sau:
while(bit_test(PORTB,4))
{
}
delay_ms(10);//chong nay phim
while(bit_test(PORTB,5))
{
}
delay_ms(10);//chong nay phim
while(bit_test(PORTB,6))
{
}
delay_ms(10);//chong nay phim
while(bit_test(PORTB,7))
{
}
delay_ms(10);//chong nay phim
chèn thêm lệnh delay_ms(10) sau mỗi lần thoát khỏi while
|
oh yeah! cám ơn anh tdm rất nhìu, bít thêm chút ít nữa. Cám ơn anh đã chỉ giáo