Browse Source

SITL: added pgm_read_byte_far()

mission-4.1.18
Andrew Tridgell 13 years ago
parent
commit
b337441ec5
  1. 1
      libraries/Desktop/include/avr/pgmspace.h

1
libraries/Desktop/include/avr/pgmspace.h

@ -36,6 +36,7 @@ extern char *strncpy_P(char *dest, PGM_P src, size_t n);
extern void *memcpy_P(void *dest, PGM_P src, size_t n); extern void *memcpy_P(void *dest, PGM_P src, size_t n);
static inline uint8_t pgm_read_byte(PGM_P s) { return (uint8_t)*s; } static inline uint8_t pgm_read_byte(PGM_P s) { return (uint8_t)*s; }
static inline uint8_t pgm_read_byte_far(const void *s) { return *(const uint8_t *)s; }
static inline uint16_t pgm_read_word(const void *s) { return *(const uint16_t *)s; } static inline uint16_t pgm_read_word(const void *s) { return *(const uint16_t *)s; }
#define GETBYTE(flag, mask, pnt) ({ \ #define GETBYTE(flag, mask, pnt) ({ \

Loading…
Cancel
Save