1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2024-11-24 00:26:13 +01:00
CommandStation-EX/FSH.h

18 lines
336 B
C
Raw Normal View History

#ifndef FSH_h
#define FSH_h
#include <Arduino.h>
#ifdef ARDUINO_ARCH_MEGAAVR
#ifdef F
#undef F
#define F(str) (str)
#endif
typedef char FSH;
2021-01-03 10:11:11 +01:00
#define GETFLASH(addr) (*(const unsigned char *)(addr))
#define FLASH
#else
typedef __FlashStringHelper FSH;
2021-01-03 10:11:11 +01:00
#define GETFLASH(addr) pgm_read_byte_near(addr)
#define FLASH PROGMEM
#endif
#endif