//This program reads JA.4 to JA.7 and writes to User LEDs (LD1 to LD4) //Connect the switches to JA.4 to JA.7 (the lower pins of JA in the socket) //The program is in AVR assembly. Make the hex file using AVR Studio IDE. //For more information see www.microdigitaled.com and digilentinc.com #include int main () { DDRA = 0x00; //JA as input DDRE = 0xF0; //JC as output PORTA = 0xFF; //make pull-up resistors active while (1) { PORTE = PINA & 0xF0; //send the high nibble of JA to the LEDs } }