diff --git a/qiboot/src/serial.c b/qiboot/src/serial.c index 23d6747..c617a73 100644 --- a/qiboot/src/serial.c +++ b/qiboot/src/serial.c @@ -30,9 +30,6 @@ void serial_init (const int ubrdiv_val,const int uart) case UART0: rULCON0 = 0x3; rUCON0 = 0x245; - rGPHCON = rGPHCON & ~(3 << 16); - delay(1); - rGPHCON = rGPHCON & ~(3 << 16)|(1 << 17); rUFCON0 = 0x0; rUMCON0 = 0x0; rUBRDIV0 = ubrdiv_val; @@ -47,10 +44,7 @@ void serial_init (const int ubrdiv_val,const int uart) case UART2: rULCON2 = 0x3; rUCON2 = 0x245; - rGPHCON = rGPHCON & ~(3 << 16); - delay(1); - rGPHCON = rGPHCON & ~(3 << 16)|(1 << 17); - rUFCON2 = 0x0; + rUFCON2 = 0x1; rUBRDIV2 = ubrdiv_val; break; default: diff --git a/qiboot/src/start.S b/qiboot/src/start.S index b92ccc7..b2b0596 100644 --- a/qiboot/src/start.S +++ b/qiboot/src/start.S @@ -89,8 +89,8 @@ start_code: # define UPLLCON 0x4c000008 # define MPLLCON_val ((142 << 12) + (7 << 4) + 1) # define UPLLCON_val (( 88 << 12) + (8 << 4) + 2) -/*# define MPLLCON_val ((0x7d << 12) + (0x2 << 4) + 0x1) -# define UPLLCON_val ((0x38 << 12) + (0x2 << 4) + 0x2)*/ +/* # define MPLLCON_val ((0x7d << 12) + (0x2 << 4) + 0x1) +# define UPLLCON_val ((0x38 << 12) + (0x2 << 4) + 0x2) */ ldr r0, =UPLLCON ldr r1, =UPLLCON_val diff --git a/qiboot/src/start_kboot.c b/qiboot/src/start_kboot.c index 7d41e9f..70ece03 100644 --- a/qiboot/src/start_kboot.c +++ b/qiboot/src/start_kboot.c @@ -40,9 +40,9 @@ unsigned char buf[2*1024]; int start_kboot(void) { port_init(); - serial_init(0x7,UART0); + serial_init(0x11,UART2); while(1){ - serial_putc (UART0,'0'); + serial_putc (UART2,'2'); blue_on(1); }