projects
/
bertos.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use demo as default app.
[bertos.git]
/
mware
/
pgm.h
diff --git
a/mware/pgm.h
b/mware/pgm.h
index 673b143dca7fca89db86ac27833b7cd4c448897d..5f10d002ea5a6c153048467cd1746da88a79a20b 100755
(executable)
--- a/
mware/pgm.h
+++ b/
mware/pgm.h
@@
-1,4
+1,4
@@
-/*
!
+/*
*
* \file
* <!--
* Copyright 2005 Develer S.r.l. (http://www.develer.com/)
* \file
* <!--
* Copyright 2005 Develer S.r.l. (http://www.develer.com/)
@@
-150,6
+150,9
@@
#ifndef PSTR
#define PSTR(s) ({ static const char __c[] PROGMEM = (s); &__c[0]; })
#endif
#ifndef PSTR
#define PSTR(s) ({ static const char __c[] PROGMEM = (s); &__c[0]; })
#endif
+ #ifndef PFUNC
+ #define PFUNC(x) x ## _P
+ #endif
#elif CPU_HARVARD
#error Missing CPU support
#elif CPU_HARVARD
#error Missing CPU support
@@
-159,11
+162,15
@@
#define PSTR /* nothing */
#endif
#define PSTR /* nothing */
#endif
+#ifndef PFUNC
+#define PFUNC(x) x
+#endif
+
#ifndef PROGMEM
#define PROGMEM /* nothing */
#endif
#ifndef PROGMEM
#define PROGMEM /* nothing */
#endif
-/*
!
+/*
*
* \name Types for variables stored in program memory (harvard processors).
* \{
*/
* \name Types for variables stored in program memory (harvard processors).
* \{
*/
@@
-176,7
+183,7
@@
typedef PROGMEM int32_t pgm_int32_t;
typedef PROGMEM uint32_t pgm_uint32_t;
/*\}*/
typedef PROGMEM uint32_t pgm_uint32_t;
/*\}*/
-/*
!
+/*
*
* \name PGM support macros.
*
* These macros enable dual compilation of code for both program
* \name PGM support macros.
*
* These macros enable dual compilation of code for both program
@@
-209,13
+216,13
@@
typedef PROGMEM uint32_t pgm_uint32_t;
*/
#ifdef _PROGMEM
#define PGM_READ_CHAR(s) pgm_read_char(s)
*/
#ifdef _PROGMEM
#define PGM_READ_CHAR(s) pgm_read_char(s)
- #define PGM_FUNC(x)
x ## _P
- #define PGM_STR(x) PSTR(x)
+ #define PGM_FUNC(x)
PFUNC(x)
+ #define PGM_STR(x) PSTR(x)
#define PGM_ATTR PROGMEM
#else
#define PGM_READ_CHAR(s) (*(s))
#define PGM_FUNC(x) x
#define PGM_ATTR PROGMEM
#else
#define PGM_READ_CHAR(s) (*(s))
#define PGM_FUNC(x) x
- #define PGM_STR(x) x
+ #define PGM_STR(x) x
#define PGM_ATTR /* nothing */
#endif
/* \} */
#define PGM_ATTR /* nothing */
#endif
/* \} */