Code:
void main() {
unsigned char tensCounter , onesCounter ;
TRISB = 0 ; PORTB = 0 ;
TRISC = 0 ; PORTC = 0 ;
while(1)
{
for(tensCounter = 0 ; tensCounter <= 9 ; tensCounter++)
{
PORTB = tensCounter ;
for(onesCounter = 0 ; onesCounter <= 9 ; onesCounter++)
{
PORTC = onesCounter ;
Delay_ms(500) ;
}
}
}
}
No comments:
Post a Comment