OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [orpsocv2/] [sw/] [lib/] [include/] [printf.h] - Blame information for rev 393

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 349 julius
#ifndef _PRINTF_H_
2
#define _PRINTF_H_
3
 
4
#define PRINTFBUFFER_SIZE 512
5
extern char PRINTFBUFFER[PRINTFBUFFER_SIZE]; // Declare a global printf buffer
6
//int vfnprintf ( char *stream, size_t n, const char *format, va_list arg);
7
 
8
 
9
int printf_to_uart(const char *fmt, ...);
10
int printf_to_sim(const char *fmt, ...);
11
 
12
int putchar_to_uart(int c);
13
int putchar_to_sim(int c);
14
 
15
int puts_to_uart(const char *str);
16
int puts_to_sim(const char *str);
17
 
18
// for now...
19
 
20
#ifdef _UART_H_
21
#define printf printf_to_uart
22
#define putchar putchar_to_uart
23
#define puts puts_to_uart
24
#else
25
#define printf printf_to_sim
26
#define putchar putchar_to_sim
27
#define puts puts_to_sim
28
#endif
29
 
30
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.