-
Notifications
You must be signed in to change notification settings - Fork 1
/
hardware.h
57 lines (47 loc) · 1.54 KB
/
hardware.h
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#ifndef HARDWARE_H
#define HARDWARE_H
#ifdef __cplusplus
extern "C" {
#endif
#define KEYPADADRESS 0x20
#define KEYCFG_1 "O,P,Q,A y Space"
#define KEYCFG_2 "Joysktick Kempston"
#define KEYCFG_3 "Joystick Sinclair"
#define KEYCFG_4 "P,L,Z,X y M"
enum SpecKeys
{ SPECKEY_NONE,
SPECKEY_1, SPECKEY_2, SPECKEY_3, SPECKEY_4, SPECKEY_5, SPECKEY_6, SPECKEY_7, SPECKEY_8, SPECKEY_9, SPECKEY_0,
SPECKEY_Q, SPECKEY_W, SPECKEY_E, SPECKEY_R, SPECKEY_T, SPECKEY_Y, SPECKEY_U, SPECKEY_I, SPECKEY_O, SPECKEY_P,
SPECKEY_A, SPECKEY_S, SPECKEY_D, SPECKEY_F, SPECKEY_G, SPECKEY_H, SPECKEY_J, SPECKEY_K, SPECKEY_L, SPECKEY_ENTER,
SPECKEY_SHIFT, SPECKEY_Z, SPECKEY_X, SPECKEY_C, SPECKEY_V, SPECKEY_B, SPECKEY_N, SPECKEY_M, SPECKEY_SYMB, SPECKEY_SPACE,
JOYK_UP, JOYK_DOWN, JOYK_LEFT, JOYK_RIGHT,JOYK_FIRE,
VEGAKEY_MENU
};
typedef struct {
// char romfile[256];
// char snapfile[256];
char tapefile[256];
uint8_t mappingindex=0;
bool sonido=0;
} tipo_emuopt ;
//extern uint8_t border;
extern uint8_t kempston_port;
extern uint8_t ulaport_FF;
extern uint8_t speckey[];
extern int keys[];
extern int oldkeys[];
void leebotones(void);
int mirabotones(void);
void updatekey(uint8_t key, uint8_t state);
void paint_button(int b, int state);
void pf575_write(uint16_t dato);
void keypad_i2c_read(void);
void keypad_i2c_init(void);
//#include "HardwareSerial.h"
//extern HardwareSerial Serial;
#define AS_printf Serial.printf
#define AS_print Serial.print
#ifdef __cplusplus
}
#endif
#endif // #ifdef HARDWARE_H