|
@@ -650,3 +650,138 @@
|
|
|
* MSETEST2
|
|
|
* MSETEST3
|
|
|
* MSETEST4
|
|
|
+ *
|
|
|
+ */
|
|
|
+
|
|
|
+#define _KBD( x ) _SA1101( ( x ) + __TRACK_INTERFACE )
|
|
|
+#define _MSE( x ) _SA1101( ( x ) + __MOUSE_INTERFACE )
|
|
|
+
|
|
|
+#define _KBDCR _KBD( 0x0000 )
|
|
|
+#define _KBDSTAT _KBD( 0x0400 )
|
|
|
+#define _KBDDATA _KBD( 0x0800 )
|
|
|
+#define _KBDCLKDIV _KBD( 0x0c00 )
|
|
|
+#define _KBDPRECNT _KBD( 0x1000 )
|
|
|
+#define _KBDTEST1 _KBD( 0x2000 )
|
|
|
+#define _KBDTEST2 _KBD( 0x2400 )
|
|
|
+#define _KBDTEST3 _KBD( 0x2800 )
|
|
|
+#define _KBDTEST4 _KBD( 0x2c00 )
|
|
|
+#define _MSECR _MSE( 0x0000 )
|
|
|
+#define _MSESTAT _MSE( 0x0400 )
|
|
|
+#define _MSEDATA _MSE( 0x0800 )
|
|
|
+#define _MSECLKDIV _MSE( 0x0c00 )
|
|
|
+#define _MSEPRECNT _MSE( 0x1000 )
|
|
|
+#define _MSETEST1 _MSE( 0x2000 )
|
|
|
+#define _MSETEST2 _MSE( 0x2400 )
|
|
|
+#define _MSETEST3 _MSE( 0x2800 )
|
|
|
+#define _MSETEST4 _MSE( 0x2c00 )
|
|
|
+
|
|
|
+#if ( LANGUAGE == C )
|
|
|
+
|
|
|
+#define KBDCR (*((volatile Word *) SA1101_p2v (_KBDCR)))
|
|
|
+#define KBDSTAT (*((volatile Word *) SA1101_p2v (_KBDSTAT)))
|
|
|
+#define KBDDATA (*((volatile Word *) SA1101_p2v (_KBDDATA)))
|
|
|
+#define KBDCLKDIV (*((volatile Word *) SA1101_p2v (_KBDCLKDIV)))
|
|
|
+#define KBDPRECNT (*((volatile Word *) SA1101_p2v (_KBDPRECNT)))
|
|
|
+#define KBDTEST1 (*((volatile Word *) SA1101_p2v (_KBDTEST1)))
|
|
|
+#define KBDTEST2 (*((volatile Word *) SA1101_p2v (_KBDTEST2)))
|
|
|
+#define KBDTEST3 (*((volatile Word *) SA1101_p2v (_KBDTEST3)))
|
|
|
+#define KBDTEST4 (*((volatile Word *) SA1101_p2v (_KBDTEST4)))
|
|
|
+#define MSECR (*((volatile Word *) SA1101_p2v (_MSECR)))
|
|
|
+#define MSESTAT (*((volatile Word *) SA1101_p2v (_MSESTAT)))
|
|
|
+#define MSEDATA (*((volatile Word *) SA1101_p2v (_MSEDATA)))
|
|
|
+#define MSECLKDIV (*((volatile Word *) SA1101_p2v (_MSECLKDIV)))
|
|
|
+#define MSEPRECNT (*((volatile Word *) SA1101_p2v (_MSEPRECNT)))
|
|
|
+#define MSETEST1 (*((volatile Word *) SA1101_p2v (_MSETEST1)))
|
|
|
+#define MSETEST2 (*((volatile Word *) SA1101_p2v (_MSETEST2)))
|
|
|
+#define MSETEST3 (*((volatile Word *) SA1101_p2v (_MSETEST3)))
|
|
|
+#define MSETEST4 (*((volatile Word *) SA1101_p2v (_MSETEST4)))
|
|
|
+
|
|
|
+
|
|
|
+#define KBDCR_ENA 0x08
|
|
|
+#define KBDCR_FKD 0x02
|
|
|
+#define KBDCR_FKC 0x01
|
|
|
+
|
|
|
+#define KBDSTAT_TXE 0x80
|
|
|
+#define KBDSTAT_TXB 0x40
|
|
|
+#define KBDSTAT_RXF 0x20
|
|
|
+#define KBDSTAT_RXB 0x10
|
|
|
+#define KBDSTAT_ENA 0x08
|
|
|
+#define KBDSTAT_RXP 0x04
|
|
|
+#define KBDSTAT_KBD 0x02
|
|
|
+#define KBDSTAT_KBC 0x01
|
|
|
+
|
|
|
+#define KBDCLKDIV_DivVal Fld(4,0)
|
|
|
+
|
|
|
+#define MSECR_ENA 0x08
|
|
|
+#define MSECR_FKD 0x02
|
|
|
+#define MSECR_FKC 0x01
|
|
|
+
|
|
|
+#define MSESTAT_TXE 0x80
|
|
|
+#define MSESTAT_TXB 0x40
|
|
|
+#define MSESTAT_RXF 0x20
|
|
|
+#define MSESTAT_RXB 0x10
|
|
|
+#define MSESTAT_ENA 0x08
|
|
|
+#define MSESTAT_RXP 0x04
|
|
|
+#define MSESTAT_MSD 0x02
|
|
|
+#define MSESTAT_MSC 0x01
|
|
|
+
|
|
|
+#define MSECLKDIV_DivVal Fld(4,0)
|
|
|
+
|
|
|
+#define KBDTEST1_CD 0x80
|
|
|
+#define KBDTEST1_RC1 0x40
|
|
|
+#define KBDTEST1_MC 0x20
|
|
|
+#define KBDTEST1_C Fld(2,3)
|
|
|
+#define KBDTEST1_T2 0x40
|
|
|
+#define KBDTEST1_T1 0x20
|
|
|
+#define KBDTEST1_T0 0x10
|
|
|
+#define KBDTEST2_TICBnRES 0x08
|
|
|
+#define KBDTEST2_RKC 0x04
|
|
|
+#define KBDTEST2_RKD 0x02
|
|
|
+#define KBDTEST2_SEL 0x01
|
|
|
+#define KBDTEST3_ms_16 0x80
|
|
|
+#define KBDTEST3_us_64 0x40
|
|
|
+#define KBDTEST3_us_16 0x20
|
|
|
+#define KBDTEST3_DIV8 0x10
|
|
|
+#define KBDTEST3_DIn 0x08
|
|
|
+#define KBDTEST3_CIn 0x04
|
|
|
+#define KBDTEST3_KD 0x02
|
|
|
+#define KBDTEST3_KC 0x01
|
|
|
+#define KBDTEST4_BC12 0x80
|
|
|
+#define KBDTEST4_BC11 0x40
|
|
|
+#define KBDTEST4_TRES 0x20
|
|
|
+#define KBDTEST4_CLKOE 0x10
|
|
|
+#define KBDTEST4_CRES 0x08
|
|
|
+#define KBDTEST4_RXB 0x04
|
|
|
+#define KBDTEST4_TXB 0x02
|
|
|
+#define KBDTEST4_SRX 0x01
|
|
|
+
|
|
|
+#define MSETEST1_CD 0x80
|
|
|
+#define MSETEST1_RC1 0x40
|
|
|
+#define MSETEST1_MC 0x20
|
|
|
+#define MSETEST1_C Fld(2,3)
|
|
|
+#define MSETEST1_T2 0x40
|
|
|
+#define MSETEST1_T1 0x20
|
|
|
+#define MSETEST1_T0 0x10
|
|
|
+#define MSETEST2_TICBnRES 0x08
|
|
|
+#define MSETEST2_RKC 0x04
|
|
|
+#define MSETEST2_RKD 0x02
|
|
|
+#define MSETEST2_SEL 0x01
|
|
|
+#define MSETEST3_ms_16 0x80
|
|
|
+#define MSETEST3_us_64 0x40
|
|
|
+#define MSETEST3_us_16 0x20
|
|
|
+#define MSETEST3_DIV8 0x10
|
|
|
+#define MSETEST3_DIn 0x08
|
|
|
+#define MSETEST3_CIn 0x04
|
|
|
+#define MSETEST3_KD 0x02
|
|
|
+#define MSETEST3_KC 0x01
|
|
|
+#define MSETEST4_BC12 0x80
|
|
|
+#define MSETEST4_BC11 0x40
|
|
|
+#define MSETEST4_TRES 0x20
|
|
|
+#define MSETEST4_CLKOE 0x10
|
|
|
+#define MSETEST4_CRES 0x08
|
|
|
+#define MSETEST4_RXB 0x04
|
|
|
+#define MSETEST4_TXB 0x02
|
|
|
+#define MSETEST4_SRX 0x01
|
|
|
+
|
|
|
+#endif /* LANGUAGE == C */
|
|
|
+
|