projects
/
my-code
/
arm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
forgot to add the pwm code
[my-code/arm.git]
/
betty
/
uart.c
diff --git
a/betty/uart.c
b/betty/uart.c
index
5760e3b
..
da9a3fa
100644
(file)
--- a/
betty/uart.c
+++ b/
betty/uart.c
@@
-13,9
+13,6
@@
void uart0_init(void) {
void uart0_init(void) {
- /* select pins 0.0 and 0.1 as tx and rx */
- PINSEL0=(PINSEL0&~(0xf))|0x05;
-
/* configure uart 0 */
UART0_FCR=0x07; // enable fifo
UART0_LCR=0x83; // set dlab + word length
/* configure uart 0 */
UART0_FCR=0x07; // enable fifo
UART0_LCR=0x83; // set dlab + word length
@@
-38,14
+35,6
@@
void uart0_send_string(char *txbuf) {
continue;
}
continue;
}
- /* flush if \n and \r do not fit in the tx buffer */
- if(i>14)
- while(!(UART0_LSR&(1<<6)))
- continue;
-
- UART0_THR='\n';
- UART0_THR='\r';
-
/* flush uart0 anyways */
while(!(UART0_LSR&(1<<6)))
continue;
/* flush uart0 anyways */
while(!(UART0_LSR&(1<<6)))
continue;