From d98e6c5d0d6c048c99aeda810da10e6a6a130325 Mon Sep 17 00:00:00 2001 From: Joel Bodenmann Date: Sun, 21 Jul 2013 17:42:25 +0200 Subject: cleaned up board file mess --- drivers/ginput/touch/ADS7843/ginput_lld_mouse.c | 12 +--- .../touch/ADS7843/ginput_lld_mouse_board_example.h | 75 ---------------------- .../ADS7843/ginput_lld_mouse_board_template.h | 71 ++++++++++++++++++++ drivers/ginput/touch/ADS7843/readme.txt | 8 --- 4 files changed, 72 insertions(+), 94 deletions(-) delete mode 100644 drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_example.h create mode 100644 drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_template.h delete mode 100644 drivers/ginput/touch/ADS7843/readme.txt (limited to 'drivers/ginput/touch/ADS7843') diff --git a/drivers/ginput/touch/ADS7843/ginput_lld_mouse.c b/drivers/ginput/touch/ADS7843/ginput_lld_mouse.c index a25e6bac..f9ebe56d 100644 --- a/drivers/ginput/touch/ADS7843/ginput_lld_mouse.c +++ b/drivers/ginput/touch/ADS7843/ginput_lld_mouse.c @@ -20,17 +20,7 @@ #include "ginput/lld/mouse.h" -#if defined(GINPUT_MOUSE_USE_CUSTOM_BOARD) && GINPUT_MOUSE_USE_CUSTOM_BOARD - #include "ginput_lld_mouse_board.h" -#elif defined(BOARD_FIREBULL_STM32_F103) - #include "ginput_lld_mouse_board_firebull_stm32f103.h" -#elif defined(BOARD_OLIMEX_STM32_E407) - #include "ginput_lld_mouse_board_olimex_stm32_e407.h" -#elif defined(BOARD_ST_STM32F4_DISCOVERY) - #include "ginput_lld_mouse_board_st_stm32f4_discovery.h" -#else - #include "ginput_lld_mouse_board_example.h" -#endif +#include "ginput_lld_mouse_board.h" #if defined(GINPUT_MOUSE_YX_INVERTED) && GINPUT_MOUSE_YX_INVERTED #define CMD_X 0x91 diff --git a/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_example.h b/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_example.h deleted file mode 100644 index 61f2ee50..00000000 --- a/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_example.h +++ /dev/null @@ -1,75 +0,0 @@ -/* - * This file is subject to the terms of the GFX License. If a copy of - * the license was not distributed with this file, you can obtain one at: - * - * http://chibios-gfx.com/license.html - */ - -/** - * @file drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_example.h - * @brief GINPUT Touch low level driver source for the ADS7843 on the example board. - * - * @defgroup Mouse Mouse - * @ingroup GINPUT - * @{ - */ - -#ifndef _GINPUT_LLD_MOUSE_BOARD_H -#define _GINPUT_LLD_MOUSE_BOARD_H - -/** - * @brief Initialise the board for the touch. - * - * @notapi - */ -static inline void init_board(void) { - /* Code here */ - #error "ginputADS7843: You must supply a definition for init_board for your board" -} - -/** - * @brief Check whether the surface is currently touched - * @return TRUE if the surface is currently touched - * - * @notapi - */ -static inline bool_t getpin_pressed(void) { - /* Code here */ - #error "ginputADS7843: You must supply a definition for getpin_pressed for your board" -} - -/** - * @brief Aquire the bus ready for readings - * - * @notapi - */ -static inline void aquire_bus(void) { - /* Code here */ - #error "ginputADS7843: You must supply a definition for aquire_bus for your board" -} - -/** - * @brief Release the bus after readings - * - * @notapi - */ -static inline void release_bus(void) { - /* Code here */ - #error "ginputADS7843: You must supply a definition for release_bus for your board" -} - -/** - * @brief Read a value from touch controller - * @return The value read from the controller - * - * params[in] port The controller port to read. - * - * @notapi - */ -static inline uint16_t read_value(uint16_t port) { - /* Code here */ - #error "ginputADS7843: You must supply a definition for read_value for your board" -} - -#endif /* _GINPUT_LLD_MOUSE_BOARD_H */ -/** @} */ diff --git a/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_template.h b/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_template.h new file mode 100644 index 00000000..8808d24d --- /dev/null +++ b/drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_template.h @@ -0,0 +1,71 @@ +/* + * This file is subject to the terms of the GFX License. If a copy of + * the license was not distributed with this file, you can obtain one at: + * + * http://chibios-gfx.com/license.html + */ + +/** + * @file drivers/ginput/touch/ADS7843/ginput_lld_mouse_board_template.h + * @brief GINPUT Touch low level driver source for the ADS7843 on the example board. + * + * @defgroup Mouse Mouse + * @ingroup GINPUT + * @{ + */ + +#ifndef _GINPUT_LLD_MOUSE_BOARD_H +#define _GINPUT_LLD_MOUSE_BOARD_H + +/** + * @brief Initialise the board for the touch. + * + * @notapi + */ +static inline void init_board(void) { + +} + +/** + * @brief Check whether the surface is currently touched + * @return TRUE if the surface is currently touched + * + * @notapi + */ +static inline bool_t getpin_pressed(void) { + +} + +/** + * @brief Aquire the bus ready for readings + * + * @notapi + */ +static inline void aquire_bus(void) { + +} + +/** + * @brief Release the bus after readings + * + * @notapi + */ +static inline void release_bus(void) { + +} + +/** + * @brief Read a value from touch controller + * @return The value read from the controller + * + * params[in] port The controller port to read. + * + * @notapi + */ +static inline uint16_t read_value(uint16_t port) { + +} + +#endif /* _GINPUT_LLD_MOUSE_BOARD_H */ +/** @} */ + diff --git a/drivers/ginput/touch/ADS7843/readme.txt b/drivers/ginput/touch/ADS7843/readme.txt deleted file mode 100644 index abc4b0e9..00000000 --- a/drivers/ginput/touch/ADS7843/readme.txt +++ /dev/null @@ -1,8 +0,0 @@ -To use this driver: - -1. Add in your gfxconf.h: - a) #define GFX_USE_GINPUT TRUE - b) #define GINPUT_NEED_MOUSE TRUE - -2. To your makefile add the following lines: - include $(GFXLIB)/drivers/ginput/touch/ADS7843/ginput_lld.mk -- cgit v1.2.3