Firmware: uPD77c25 program download, reset

This commit is contained in:
ikari
2011-06-11 03:33:49 +02:00
parent 56538dc5e1
commit 344fa362be
14 changed files with 176 additions and 15 deletions

View File

@@ -45,7 +45,7 @@ int main(void) {
DBG_UART uart_init();
led_init();
readled(0);
rdyled(0);
rdyled(1);
writeled(0);
/* do this last because the peripheral init()s change PCLK dividers */
clock_init();
@@ -63,9 +63,11 @@ DBG_BL printf("PCONP=%lx\n", LPC_SC->PCONP);
FLASH_RES res = flash_file((uint8_t*)"/sd2snes/firmware.img");
if(res == ERR_FLASHPREP || res == ERR_FLASHERASE || res == ERR_FLASH) {
rdyled(0);
writeled(1);
}
if(res == ERR_FILEHD || res == ERR_FILECHK) {
rdyled(0);
readled(1);
}
DBG_BL printf("flash result = %d\n", res);