fork download
  1. #include <avr/io.h>
  2. // ### CBI ### Clear Pin Of A Port
  3. #define ASM_CBI(port, pin) asm volatile ("cbi %0, %1" :: "I" (_SFR_IO_ADDR(port)), "I" (pin))
  4.  
  5. int main(void){
  6. unsigned char bitmasks[2] = {0b00000001, 0b00000010};
  7. /* turn of some pin on port C: */
  8. ASM_CBI(PORTC, 0b00000001);//<< this works
  9. ASM_CBI(PORTC, bitmasks[1]);//<< this does not work
  10. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.c:1:20: fatal error: avr/io.h: No such file or directory
compilation terminated.
stdout
Standard output is empty