From 061b371ff1fb677f866ff329f972fd546434a9ca Mon Sep 17 00:00:00 2001 From: Lephe Date: Fri, 10 Jan 2025 12:24:28 +0100 Subject: [PATCH] keysc: add MPU module description for KEYSC --- include/gint/mpu/keysc.h | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 include/gint/mpu/keysc.h diff --git a/include/gint/mpu/keysc.h b/include/gint/mpu/keysc.h new file mode 100644 index 0000000..ed6d932 --- /dev/null +++ b/include/gint/mpu/keysc.h @@ -0,0 +1,34 @@ +//--- +// gint:mpu:keysc - Key Scan Controller +//--- + +#ifndef GINT_MPU_KEYSC +#define GINT_MPU_KEYSC + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#include + +typedef volatile struct { + uint16_t KIUDATA[6]; + uint16_t KIUCNTREG; + uint16_t KIAUTOFIXREG; + uint16_t KIUMODEREG; + uint16_t KIUSTATEREG; + uint16_t KIUINTREG; + uint16_t KIUWSETREG; + uint16_t KIUINTERVALREG; + uint16_t KOUTPINSET; + uint16_t KINPINSET; +} GPACKED(4) sh7305_keysc_t; + +#define SH7305_KEYSC (*(sh7305_keysc_t *)0xa44b0000) + +#ifdef __cplusplus +} +#endif + +#endif /* GINT_MPU_KEYSC */