contiki-os / contiki

The official git repository for Contiki, the open source OS for the Internet of Things
http://www.contiki-os.org/
Other
3.72k stars 2.58k forks source link

jn516x: enable both UARTs while console is on UART1 makes bus exception #1314

Closed mmajchrzycki closed 9 years ago

mmajchrzycki commented 9 years ago

I tried to enable both UARTs on JN5168 chip and redirect printf output to UART1. I changed the putc function in: https://github.com/contiki-os/contiki/blob/master/platform/jn516x/lib/slip.c#L442 to use uart1_writeb. I also enabled the UART1 in: https://github.com/contiki-os/contiki/blob/master/platform/jn516x/Makefile.jn516x#L74 and added the uart1_init in contiki-jn516x-main.c. However the Contiki makes a BUS EXCEPTION during boot, because of that line: https://github.com/contiki-os/contiki/blob/master/platform/jn516x/dev/uart-driver.c#L164 The printf should be changed to DBG_vPrintf

simonduq commented 9 years ago

Thanks for the bug report, now addressed in https://github.com/contiki-os/contiki/pull/1315