avr-game

annotate dotmatrix.h @ 2:363acf3e61d4

wha?
author John Tsiombikas <nuclear@member.fsf.org>
date Fri, 20 Mar 2015 21:03:38 +0200
parents
children
rev   line source
nuclear@0 1 #ifndef DOTMATRIX_H_
nuclear@0 2 #define DOTMATRIX_H_
nuclear@0 3
nuclear@0 4 #include <avr/io.h>
nuclear@0 5
nuclear@0 6 /* change these port/pin assignments to match the circuit */
nuclear@0 7 #define DM_PORT PORTB
nuclear@0 8 #define DM_DDR DDRB
nuclear@0 9 #define DM_PIN_CLK 5 /* sck */
nuclear@0 10 #define DM_PIN_DIN 3 /* mosi */
nuclear@0 11 #define DM_PIN_DC 1
nuclear@0 12 #define DM_PIN_CE 2
nuclear@0 13 #define DM_PIN_RST 0
nuclear@0 14 /* end of config block, don't touch anything below */
nuclear@0 15
nuclear@0 16 #define DM_WIDTH 48
nuclear@0 17 #define DM_HEIGHT 84
nuclear@0 18
nuclear@0 19 int dm_init(void);
nuclear@0 20 void dm_test(void);
nuclear@0 21
nuclear@0 22 void dm_invert(void);
nuclear@0 23
nuclear@0 24 void dm_clear(unsigned char val);
nuclear@0 25 void dm_copy(int x, int y, const unsigned char *fb, int bytes);
nuclear@0 26
nuclear@0 27 #endif /* DOTMATRIX_H_ */