/* start the main program */ void main() { UART_Init(9600); UART_TxString("\n\rTest menu Utra x51 v1.1\r\n 1:GPIO Blink\r\n 2:LCD \n\r 3:7-Segment\n\r 4:RTC\n\r 5:EEPROM\n\r 6:ADC\n\r 7:Keypad \n\r Enter option:"); UART_TxString("\n\rReset the board after test is done"); mm_option = UART_RxChar(); while(1) { switch(mm_option) { case '1': gpio_test(); break; case '2': LCD_test(); break; case '3': seg_test(); break; case '4': rtc_test(); break; case '5': eeprom_test(); break; //eeprom case '6': adc_test(); break; case '7': keypad_test();break; default:break; } } }
/* start the main program */ void main() { UART_Init(9600); UART_TxString("\n\rPIC Ultra baord menu v2.0\r\n 1:GPIO Blink\r\n 2:LCD 8-bit \n\r 3:LCD 4-bit\n\r 4:7-Segment\n\r 5:RTC\n\r 6:EEPROM\n\r 7:ADC\n\r 8:Keypad \n\r Enter option:"); UART_TxString("\n\rReset the board after test is done"); mm_option = UART_RxChar(); while(1) { switch(mm_option) { case '1': gpio_test(); break; case '2': LCD_8bit_test(); break; case '3': LCD_4bit_test(); break; case '4': seg_test(); break; case '5': rtc_test(); break; case '6': eeprom_test(); break; //eeprom case '7': adc_test(); break; case '8': keypad_test();break; default:break; } } }