aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ginput/toggle/Pal
diff options
context:
space:
mode:
authorJoel Bodenmann <joel@unormal.org>2013-02-11 09:25:26 +0100
committerJoel Bodenmann <joel@unormal.org>2013-02-11 09:25:26 +0100
commit885b3d53b3a491c62fb0634b78cb9857723ac15d (patch)
tree4b825dc642cb6eb9a060e54bf8d69288fbee4904 /drivers/ginput/toggle/Pal
parent851e5fb09bdc086d734647128fd3051c3a8528e2 (diff)
downloaduGFX-885b3d53b3a491c62fb0634b78cb9857723ac15d.tar.gz
uGFX-885b3d53b3a491c62fb0634b78cb9857723ac15d.tar.bz2
uGFX-885b3d53b3a491c62fb0634b78cb9857723ac15d.zip
removed GDISP_LLD() macro
Diffstat (limited to 'drivers/ginput/toggle/Pal')
-rw-r--r--drivers/ginput/toggle/Pal/ginput_lld.mk5
-rw-r--r--drivers/ginput/toggle/Pal/ginput_lld_toggle.c63
-rw-r--r--drivers/ginput/toggle/Pal/ginput_lld_toggle_board_example.h61
-rw-r--r--drivers/ginput/toggle/Pal/ginput_lld_toggle_board_olimexsam7ex256.h57
-rw-r--r--drivers/ginput/toggle/Pal/ginput_lld_toggle_config.h48
-rw-r--r--drivers/ginput/toggle/Pal/readme.txt13
6 files changed, 0 insertions, 247 deletions
diff --git a/drivers/ginput/toggle/Pal/ginput_lld.mk b/drivers/ginput/toggle/Pal/ginput_lld.mk
deleted file mode 100644
index d398da9d..00000000
--- a/drivers/ginput/toggle/Pal/ginput_lld.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# List the required driver.
-GFXSRC += $(GFXLIB)/drivers/ginput/toggle/Pal/ginput_lld_toggle.c
-
-# Required include directories
-GFXINC += $(GFXLIB)/drivers/ginput/toggle/Pal
diff --git a/drivers/ginput/toggle/Pal/ginput_lld_toggle.c b/drivers/ginput/toggle/Pal/ginput_lld_toggle.c
deleted file mode 100644
index e2ecc116..00000000
--- a/drivers/ginput/toggle/Pal/ginput_lld_toggle.c
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- ChibiOS/GFX - Copyright (C) 2012
- Joel Bodenmann aka Tectu <joel@unormal.org>
-
- This file is part of ChibiOS/GFX.
-
- ChibiOS/GFX is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- ChibiOS/GFX is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-/**
- * @file drivers/ginput/toggle/Pal/ginput_lld_toggle.c
- * @brief GINPUT Toggle low level driver source for the ChibiOS PAL hardware.
- *
- * @defgroup Toggle Toggle
- * @ingroup GINPUT
- * @{
- */
-
-#include "ch.h"
-#include "hal.h"
-#include "gfx.h"
-
-#if (GFX_USE_GINPUT && GINPUT_NEED_TOGGLE) /*|| defined(__DOXYGEN__)*/
-
-#include "ginput/lld/toggle.h"
-
-GINPUT_TOGGLE_DECLARE_STRUCTURE();
-
-/**
- * @brief Initialise the port.
- *
- * @param[in] ptc A pointer to one of the entries in GInputToggleConfigTable
- *
- * @notapi
- */
-void ginput_lld_toggle_init(const GToggleConfig *ptc) {
- palSetGroupMode(((IOBus *)ptc->id)->portid, ptc->mask, 0, ptc->mode);
-}
-
-/**
- * @brief Get the bits from the port.
- *
- * @param[in] ptc A pointer to one of the entries in GInputToggleConfigTable
- *
- * @notapi
- */
-unsigned ginput_lld_toggle_getbits(const GToggleConfig *ptc) {
- return palReadBus((IOBus *)ptc->id);
-}
-
-#endif /* GFX_USE_GINPUT && GINPUT_NEED_TOGGLE */
-/** @} */
diff --git a/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_example.h b/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_example.h
deleted file mode 100644
index 20fc44b5..00000000
--- a/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_example.h
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- ChibiOS/GFX - Copyright (C) 2012
- Joel Bodenmann aka Tectu <joel@unormal.org>
-
- This file is part of ChibiOS/GFX.
-
- ChibiOS/GFX is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- ChibiOS/GFX is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-/**
- * @file drivers/ginput/toggle/Pal/ginput_lld_toggle_board_example.h
- * @brief GINPUT Toggle low level driver source for the ChibiOS PAL hardware on the example board.
- *
- * @defgroup Toggle Toggle
- * @ingroup GINPUT
- * @{
- */
-
-#ifndef _GDISP_LLD_TOGGLE_BOARD_H
-#define _GDISP_LLD_TOGGLE_BOARD_H
-
-#error "GINPUT Toggle Pal Driver: You need to define your board definitions"
-
-// The below are example values
-
-#define GINPUT_TOGGLE_NUM_PORTS 7 // The total number of toggle inputs
-#define GINPUT_TOGGLE_CONFIG_ENTRIES 2 // The total number of GToggleConfig entries
-
-#define GINPUT_TOGGLE_SW1 0 // Switch 1
-#define GINPUT_TOGGLE_SW2 1 // Switch 2
-#define GINPUT_TOGGLE_UP 2 // Joystick Up
-#define GINPUT_TOGGLE_DOWN 3 // Joystick Down
-#define GINPUT_TOGGLE_LEFT 4 // Joystick Left
-#define GINPUT_TOGGLE_RIGHT 5 // Joystick Right
-#define GINPUT_TOGGLE_CENTER 6 // Joystick Center
-
-#define GINPUT_TOGGLE_DECLARE_STRUCTURE() \
- const GToggleConfig GInputToggleConfigTable[GINPUT_TOGGLE_CONFIG_ENTRIES] = { \
- {AT91C_BASE_PIOB, /* Switch 1 and Switch 2 */ \
- PIOB_SW1_MASK|PIOB_SW2_MASK, \
- PIOB_SW1_MASK|PIOB_SW2_MASK, \
- PAL_MODE_INPUT}, \
- {AT91C_BASE_PIOA, /* B1..4 Joystick */ \
- PIOA_B1_MASK|PIOA_B2_MASK|PIOA_B3_MASK|PIOA_B4_MASK|PIOA_B5_MASK, \
- PIOA_B1_MASK|PIOA_B2_MASK|PIOA_B3_MASK|PIOA_B4_MASK|PIOA_B5_MASK, \
- PAL_MODE_INPUT}, \
- }
-
-#endif /* _GDISP_LLD_TOGGLE_BOARD_H */
-/** @} */
diff --git a/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_olimexsam7ex256.h b/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_olimexsam7ex256.h
deleted file mode 100644
index 4f3d6800..00000000
--- a/drivers/ginput/toggle/Pal/ginput_lld_toggle_board_olimexsam7ex256.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- ChibiOS/GFX - Copyright (C) 2012
- Joel Bodenmann aka Tectu <joel@unormal.org>
-
- This file is part of ChibiOS/GFX.
-
- ChibiOS/GFX is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- ChibiOS/GFX is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-/**
- * @file drivers/ginput/toggle/Pal/ginput_lld_toggle_board_olimexsam7ex256.h
- * @brief GINPUT Toggle low level driver source for the ChibiOS PAL hardware on the Olimex SAM7EX256 board.
- *
- * @defgroup Toggle Toggle
- * @ingroup GINPUT
- * @{
- */
-
-#ifndef _GDISP_LLD_TOGGLE_BOARD_H
-#define _GDISP_LLD_TOGGLE_BOARD_H
-
-#define GINPUT_TOGGLE_NUM_PORTS 7 // The total number of toggle inputs
-#define GINPUT_TOGGLE_CONFIG_ENTRIES 2 // The total number of GToggleConfig entries
-
-#define GINPUT_TOGGLE_SW1 0 // Switch 1
-#define GINPUT_TOGGLE_SW2 1 // Switch 2
-#define GINPUT_TOGGLE_UP 2 // Joystick Up
-#define GINPUT_TOGGLE_DOWN 3 // Joystick Down
-#define GINPUT_TOGGLE_LEFT 4 // Joystick Left
-#define GINPUT_TOGGLE_RIGHT 5 // Joystick Right
-#define GINPUT_TOGGLE_CENTER 6 // Joystick Center
-
-#define GINPUT_TOGGLE_DECLARE_STRUCTURE() \
- const GToggleConfig GInputToggleConfigTable[GINPUT_TOGGLE_CONFIG_ENTRIES] = { \
- {AT91C_BASE_PIOB, /* Switch 1 and Switch 2 */ \
- PIOB_SW1_MASK|PIOB_SW2_MASK, \
- PIOB_SW1_MASK|PIOB_SW2_MASK, \
- PAL_MODE_INPUT}, \
- {AT91C_BASE_PIOA, /* B1..4 Joystick */ \
- PIOA_B1_MASK|PIOA_B2_MASK|PIOA_B3_MASK|PIOA_B4_MASK|PIOA_B5_MASK, \
- PIOA_B1_MASK|PIOA_B2_MASK|PIOA_B3_MASK|PIOA_B4_MASK|PIOA_B5_MASK, \
- PAL_MODE_INPUT}, \
- }
-
-#endif /* _GDISP_LLD_TOGGLE_BOARD_H */
-/** @} */
diff --git a/drivers/ginput/toggle/Pal/ginput_lld_toggle_config.h b/drivers/ginput/toggle/Pal/ginput_lld_toggle_config.h
deleted file mode 100644
index 162d35df..00000000
--- a/drivers/ginput/toggle/Pal/ginput_lld_toggle_config.h
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- ChibiOS/GFX - Copyright (C) 2012
- Joel Bodenmann aka Tectu <joel@unormal.org>
-
- This file is part of ChibiOS/GFX.
-
- ChibiOS/GFX is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- ChibiOS/GFX is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-/**
- * @file drivers/ginput/toggle/Pal/ginput_lld_toggle_config.h
- * @brief GINPUT Toggle Driver configuration header.
- *
- * @defgroup Toggle Toggle
- * @ingroup GINPUT
- * @{
- */
-
-#ifndef _GINPUT_LLD_TOGGLE_CONFIG_H
-#define _GINPUT_LLD_TOGGLE_CONFIG_H
-
-#if GFX_USE_GINPUT && GINPUT_NEED_TOGGLE
-
-#if GINPUT_TOGGLE_USE_CUSTOM_BOARD
- /* Include the user supplied board definitions */
- #include "ginput_lld_toggle_board.h"
-#elif defined(BOARD_OLIMEX_SAM7_EX256)
- #include "ginput_lld_toggle_board_olimexsam7ex256.h"
-#else
- /* Include the user supplied board definitions */
- #include "ginput_lld_toggle_board.h"
-#endif
-
-#endif /* GFX_USE_GDISP && GINPUT_NEED_TOGGLE */
-
-#endif /* _GINPUT_LLD_TOGGLE_CONFIG_H */
-/** @} */
diff --git a/drivers/ginput/toggle/Pal/readme.txt b/drivers/ginput/toggle/Pal/readme.txt
deleted file mode 100644
index e6976f7d..00000000
--- a/drivers/ginput/toggle/Pal/readme.txt
+++ /dev/null
@@ -1,13 +0,0 @@
-To use this driver:
-
-1. Add in your halconf.h:
- a) #define GFX_USE_GINPUT TRUE
- #define GINPUT_NEED_TOGGLE TRUE
- d) If you are not using a known board then create a ginput_lld_toggle_board.h file
- and ensure it is on your include path.
- Use the ginput_lld_toggle_board_example.h file as a basis.
- Currently known boards are:
- Olimex SAM7-EX256
-
-2. To your makefile add the following lines:
- include $(GFXLIB)/drivers/ginput/togglePal/ginput_lld.mk