Professional Documents
Culture Documents
MICROCONTROLLER
Code:
#include<avr/io.h>
#include<util/delay.h>
Int main()
/// IF there were 8 zeros then the port A would have been set as input
Pa0,pa1,pa2,..,pa7
#include<avr/io.h>
#include<util/delay.h>
Int main()
DDRA = 0b11111111;
While(1)
PortA= 0b11111111;
-delay-ms(1000);
PortA= 0b00000000;
-delay-ms(1000);
}
Code:
#include<avr/io.h>
#include<util/delay.h>
Int main()
DDRA = 0b11111111;
while(1)
PortA= 0b10101010;
_delay_ms(1000);
PortA= 0b01010101;
_delay_ms(1000);
______________________________________________________________________________