mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-15 00:02:49 +03:00
add prototypes for ets_vsnprintf and ets_vprintf
fix some compiler warnings
This commit is contained in:
@ -1,14 +1,24 @@
|
||||
#ifndef __PGMSPACE_H_
|
||||
#define __PGMSPACE_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
#include <stdint.h>
|
||||
#include <stdio.h>
|
||||
#include "ets_sys.h"
|
||||
#include "osapi.h"
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#define PROGMEM
|
||||
#define PGM_P const char *
|
||||
#define PSTR(str) (str)
|
||||
|
||||
#define vsnprintf_P(...) vsnprintf( __VA_ARGS__ )
|
||||
#define vsnprintf_P(...) ets_vsnprintf( __VA_ARGS__ )
|
||||
#define snprintf_P(...) snprintf( __VA_ARGS__ )
|
||||
#define printf_P(...) os_printf(__VA_ARGS__)
|
||||
|
||||
#define _SFR_BYTE(n) (n)
|
||||
|
||||
|
@ -7,6 +7,7 @@
|
||||
#define _C_TYPES_H_
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
typedef signed char sint8_t;
|
||||
typedef signed short sint16_t;
|
||||
@ -75,8 +76,8 @@ typedef enum {
|
||||
#ifndef __cplusplus
|
||||
//typedef unsigned char bool;
|
||||
#define BOOL bool
|
||||
#define true (1)
|
||||
#define false (0)
|
||||
//#define true (1)
|
||||
//#define false (0)
|
||||
#define TRUE true
|
||||
#define FALSE false
|
||||
|
||||
|
@ -118,6 +118,7 @@ void ets_isr_unmask(int intr);
|
||||
void ets_isr_attach(int intr, int_handler_t handler, void *arg);
|
||||
void ets_intr_lock();
|
||||
void ets_intr_unlock();
|
||||
|
||||
int ets_vsnprintf(char * s, size_t n, const char * format, va_list arg);
|
||||
int ets_vprintf(const char * format, va_list arg);
|
||||
|
||||
#endif /* _ETS_SYS_H */
|
||||
|
Reference in New Issue
Block a user