blob: 557778c96254af659f3e1e0c7fc433676b78b71a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// Enable or disable the use of a display shield designed for use on
// an Arduino Uno (or compatible) on an Arduino Mega
//
// ** Currently only available for 8bit display shields **
//
// Uncomment the following line to enable this feature
//#define USE_UNO_SHIELD_ON_MEGA 1
//********************************************************************
// *** Hardwarespecific defines ***
#define cbi(reg, bitmask) *reg &= ~bitmask
#define sbi(reg, bitmask) *reg |= bitmask
#define pulse_high(reg, bitmask) sbi(reg, bitmask); cbi(reg, bitmask);
#define pulse_low(reg, bitmask) cbi(reg, bitmask); sbi(reg, bitmask);
#define cport(port, data) port &= data
#define sport(port, data) port |= data
#define swap(type, i, j) {type t = i; i = j; j = t;}
#define fontbyte(x) pgm_read_byte(&cfont.font[x])
#define regtype volatile uint8_t
#define regsize uint8_t
#define bitmapdatatype unsigned int*
|