I am using the ATMEL AVR Studio ver 5 platform and I can’t find any language reference for the c language, this would help…
I can access PORT pins by using statements such as PORTB=0b11110101;
or unsigned char i;
i=(i & 0x7F);
i=(I | 128);
PORTB=i; //this works
or I can use:
PORTB = (1<<PB7)|(0<<PB6)|(0<<PB5)|(1<<PB4)|(1<<PB3)|(1<<PB2)|(1<<PB1)|(1<<PB0); //this works
I would like to know how to access the PORT pins individually, if I attempt to use: PB7=0; //Error!
the compiler generates an error. How can I have access to individual pins without the above overhead of
making portwide statements?