我用的SDK5.0.3下面的prox_reporter创建的工程,论坛上现在有个示例使用的SKD5 template.我按照这个在我的工程上修改的,但是我使用的是UART1,我添加driver下面的uart.c 到工程之后出现以下的编译错误,请问怎么解决?谢谢
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol UART_Handler multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol UART_Handler_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_finish_transfers_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_flow_off_func multiply defined (by uart.o and arch_system.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_flow_on_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_init_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_read_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_write_func multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_flow_on multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_init multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_flow_off multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_finish_transfers multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_read multiply defined (by rom_symdef.txt and uart.o).
\ out_580 \ prox_reporter_580。axf:错误:16种200E: Symbol uart_write multiply defined (by rom_symdef.txt and uart.o).
Not enough information to produce a SYMDEFs file.
Thu, 2016-06-30 07:11
#1
how to debug with uart1
Keywords:
Device:
不用添加uart.c文件,因为ROM里已经有了相同名字的函数。直接加在periph_init函数里面添加,就可以了
SetBits16(CLK_PER_REG, UART1_ENABLE, 1);
uart_init(UART_BAUDRATE_115K2, 3);