#include <io.h>
#include <delay.h>

void main(void)
{       
    unsigned char counter = 0;    
    unsigned char blinkCnt = 0;

    // Input 
    //DDRC = ~(1 << 3);
    DDRC.3 = 0;
    // Pullup  
    //PORTC |= (1 << 3);
    PORTC.3 = 1;   
    
    DDRA = 0xFF;   
    
    
    while(1)
    {                  
        if(PINC.3 == 0)
        {          
            while(PINC.3 == 0)
            {                 
                // do nothing
            }   
                 
            for(blinkCnt = 0;blinkCnt < 3;blinkCnt++)
            {   
                PORTA = 0xFF;
                delay_ms(500);
                PORTA = 0x00;
                delay_ms(500);    
            }                                         
        }                
    }
}
   