Logo white

zhang / BootLoader

Sign in
  • Sign in
  • Project
  • Files
  • Commits
  • Network
  • Graphs
  • Milestones
  • Issues 0
  • Merge Requests 0
  • Labels
  • Wiki
  • BootLoader
  • SYSTEM
  • usart
  • debug.c
  • modfly the driver
    0e00ed59
    NightIsDark authored
    2019-06-26 18:07:23 +0800  
    Browse Code »
debug.c 381 Bytes
Edit Raw Blame History
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
#include "stdio.h"
#include "usart1.h"	
#include "uart5.h"	 
#if 1
#pragma import(__use_no_semihosting)                              
struct __FILE 
{ 
	int handle; 
}; 

FILE __stdout;         
void _sys_exit(int x) 
{ 
	x = x; 
} 

#endif

int fputc(int ch, FILE *f)		//ÖØ¶¨Òåfputcº¯Êý 
{ 	     
	usart1_send_byte((uint8_t) ch);
	uart5_send_byte((uint8_t) ch);   	
	return ch;
}