a500kbd
diff src/defs.h @ 2:a4fd9c5a6655
first working version
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Tue, 17 Oct 2017 15:25:33 +0300 |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/defs.h Tue Oct 17 15:25:33 2017 +0300 1.3 @@ -0,0 +1,29 @@ 1.4 +#ifndef DEFS_H_ 1.5 +#define DEFS_H_ 1.6 + 1.7 +#include <avr/io.h> 1.8 + 1.9 +/* pin assignments: 1.10 + * D2 PS/2 clock (INT0) 1.11 + * D3 amikbd clock (INT1) 1.12 + * D4 PS/2 data 1.13 + * D5 amikbd data 1.14 + * D6 amiga reset 1.15 + * D7 amiga drvled in 1.16 + */ 1.17 + 1.18 +#define PCLK 2 1.19 +#define ACLK 3 1.20 +#define PDATA 4 1.21 +#define ADATA 5 1.22 +#define ARST 6 1.23 +#define ADRVLED 7 1.24 + 1.25 +#define PCLK_BIT (1 << PCLK) 1.26 +#define ACLK_BIT (1 << ACLK) 1.27 +#define PDATA_BIT (1 << PDATA) 1.28 +#define ADATA_BIT (1 << ADATA) 1.29 +#define ARST_BIT (1 << ARST) 1.30 +#define ADRVLED_BIT (1 << ADRVLED) 1.31 + 1.32 +#endif /* DEFS_H_ */