#include void secDelay(int count){ int i; for(;count>0;count--){ for(i=1000; i>0;i--){ i--; } } } int main(){ DDRB = 0xFF; PORTB = 0x00; // wait delay secDelay(100); PORTB = 0xFF; // press delay secDelay(10); return 0; }