Rename up_buttons() to board_buttons()

This commit is contained in:
Gregory Nutt
2014-01-24 13:59:24 -06:00
parent e5bfdcf36c
commit f4d84ecd7e
39 changed files with 216 additions and 216 deletions
+5 -5
View File
@@ -110,7 +110,7 @@ static xcpt_t up_irqbuttonx(int irq, xcpt_t irqhandler)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -123,18 +123,18 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be * After board_button_initialize() has been called, board_buttons() may be
* called to collect the state of all buttons. up_buttons() returns an * called to collect the state of all buttons. board_buttons() returns an
* 8-bit bit set with each bit associated with a button. See the BUTTON* * 8-bit bit set with each bit associated with a button. See the BUTTON*
* definitions in the board.h header file for the meaning of each bit in * definitions in the board.h header file for the meaning of each bit in
* the returned value. * the returned value.
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t retval; uint8_t retval;
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/cloudctrl/src/up_buttons.c * configs/cloudctrl/src/board_buttons.c
* *
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -137,12 +137,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be * After board_button_initialize() has been called, board_buttons() may be
* called to collect the state of all buttons. up_buttons() returns an * called to collect the state of all buttons. board_buttons() returns an
* 8-bit bit set with each bit associated with a button. See the * 8-bit bit set with each bit associated with a button. See the
* BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning * BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning
* of each bit. * of each bit.
+2 -2
View File
@@ -73,10 +73,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return 0; return 0;
} }
+2 -2
View File
@@ -73,10 +73,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return 0; return 0;
} }
+2 -2
View File
@@ -73,10 +73,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return 0; return 0;
} }
+2 -2
View File
@@ -164,10 +164,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return inp(EZ80_PB_DDR) & 7; return inp(EZ80_PB_DDR) & 7;
} }
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/fire-stm32v2/src/up_buttons.c * configs/fire-stm32v2/src/board_buttons.c
* *
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -69,7 +69,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -86,10 +86,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@@ -113,12 +113,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of all * After that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be * After board_button_initialize() has been called, board_buttons() may be
* called to collect the state of all buttons. up_buttons() returns an * called to collect the state of all buttons. board_buttons() returns an
* 8-bit bit set with each bit associated with a button. See the * 8-bit bit set with each bit associated with a button. See the
* BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning * BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning
* of each bit. * of each bit.
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/hymini-stm32v/src/up_buttons.c * configs/hymini-stm32v/src/board_buttons.c
* *
* Copyright (C) 2009, 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2009, 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -61,7 +61,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -74,10 +74,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
bool pinValue; bool pinValue;
@@ -107,12 +107,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be * After board_button_initialize() has been called, board_buttons() may be
* called to collect the state of all buttons. up_buttons() returns an * called to collect the state of all buttons. board_buttons() returns an
* 8-bit bit set with each bit associated with a button. See the * 8-bit bit set with each bit associated with a button. See the
* BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning * BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning
* of each bit. * of each bit.
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/kwikstik-k40/src/up_buttons.c * configs/kwikstik-k40/src/board_buttons.c
* *
* Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -69,7 +69,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -81,10 +81,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
/* The KwikStik-K40 board has no standard GPIO contact buttons */ /* The KwikStik-K40 board has no standard GPIO contact buttons */
@@ -96,12 +96,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. * board_button_initialize() must be called to initialize button resources.
* After that, up_buttons() may be called to collect the current state of * After that, board_buttons() may be called to collect the current state of
* all buttons or up_irqbutton() may be called to register button interrupt * all buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be * After board_button_initialize() has been called, board_buttons() may be
* called to collect the state of all buttons. up_buttons() returns an * called to collect the state of all buttons. board_buttons() returns an
* 8-bit bit set with each bit associated with a button. See the * 8-bit bit set with each bit associated with a button. See the
* BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning * BUTTON_*_BIT and JOYSTICK_*_BIT definitions in board.h for the meaning
* of each bit. * of each bit.
+6 -6
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/lincoln60/src/up_buttons.c * configs/lincoln60/src/board_buttons.c
* *
* Copyright (C) 2012-2013 Gregory Nutt. All rights reserved. * Copyright (C) 2012-2013 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -98,7 +98,7 @@ static uint8_t g_buttonirq[BOARD_NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -117,14 +117,14 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons. * buttons.
* *
* up_buttons() may be called at any time to harvest the state of every * board_buttons() may be called at any time to harvest the state of every
* button. The state of the buttons is returned as a bitset with one * button. The state of the buttons is returned as a bitset with one
* bit corresponding to each button: If the bit is set, then the button * bit corresponding to each button: If the bit is set, then the button
* is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT * is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT
@@ -132,7 +132,7 @@ void board_button_initialize(void)
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
+6 -6
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/lpc4330-xplorer/src/up_buttons.c * configs/lpc4330-xplorer/src/board_buttons.c
* *
* Copyright (C) 2012 Gregory Nutt. All rights reserved. * Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -97,7 +97,7 @@ static uint8_t g_buttonirq[BOARD_NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -116,14 +116,14 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons. * buttons.
* *
* up_buttons() may be called at any time to harvest the state of every * board_buttons() may be called at any time to harvest the state of every
* button. The state of the buttons is returned as a bitset with one * button. The state of the buttons is returned as a bitset with one
* bit corresponding to each button: If the bit is set, then the button * bit corresponding to each button: If the bit is set, then the button
* is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT * is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT
@@ -131,7 +131,7 @@ void board_button_initialize(void)
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
+3 -3
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/ne64badge/src/up_buttons.c * configs/ne64badge/src/board_buttons.c
* *
* Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -109,10 +109,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
+6 -6
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/olimex-lpc1766stk/src/up_buttons.c * configs/olimex-lpc1766stk/src/board_buttons.c
* *
* Copyright (C) 2011 Gregory Nutt. All rights reserved. * Copyright (C) 2011 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -101,7 +101,7 @@ static uint8_t g_buttonirq[BOARD_NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -120,14 +120,14 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons. * buttons.
* *
* up_buttons() may be called at any time to harvest the state of every * board_buttons() may be called at any time to harvest the state of every
* button. The state of the buttons is returned as a bitset with one * button. The state of the buttons is returned as a bitset with one
* bit corresponding to each button: If the bit is set, then the button * bit corresponding to each button: If the bit is set, then the button
* is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT * is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT
@@ -135,7 +135,7 @@ void board_button_initialize(void)
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/olimex-stm32-p207/src/up_buttons.c * configs/olimex-stm32-p207/src/board_buttons.c
* *
* Copyright (C) 2011-2012 Gregory Nutt. All rights reserved. * Copyright (C) 2011-2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -84,7 +84,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -105,10 +105,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@@ -157,12 +157,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+2 -2
View File
@@ -108,10 +108,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
+5 -5
View File
@@ -119,7 +119,7 @@ static uint8_t g_buttonirq[BOARD_NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -138,14 +138,14 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons. * buttons.
* *
* up_buttons() may be called at any time to harvest the state of every * board_buttons() may be called at any time to harvest the state of every
* button. The state of the buttons is returned as a bitset with one * button. The state of the buttons is returned as a bitset with one
* bit corresponding to each button: If the bit is set, then the button * bit corresponding to each button: If the bit is set, then the button
* is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT * is pressed. See the BOARD_BUTTON_*_BIT and BOARD_JOYSTICK_*_BIT
@@ -153,7 +153,7 @@ void board_button_initialize(void)
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
+5 -5
View File
@@ -76,7 +76,7 @@ static xcpt_t g_irqbutton[BOARD_NBUTTONS];
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -88,17 +88,17 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON* definitions * with each bit associated with a button. See the BUTTON* definitions
* above for the meaning of each bit in the returned value. * above for the meaning of each bit in the returned value.
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
# warning Missing logic # warning Missing logic
} }
+5 -5
View File
@@ -116,7 +116,7 @@ static xcpt_t up_irqbuttonx(int irq, xcpt_t irqhandler, xcpt_t *store)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -129,17 +129,17 @@ void board_button_initialize(void)
} }
/************************************************************************************ /************************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be called to collect * After board_button_initialize() has been called, board_buttons() may be called to collect
* the state of all buttons. up_buttons() returns an 8-bit bit set with each bit * the state of all buttons. board_buttons() returns an 8-bit bit set with each bit
* associated with a button. See the BUTTON* definitions above for the meaning of * associated with a button. See the BUTTON* definitions above for the meaning of
* each bit in the returned value. * each bit in the returned value.
* *
************************************************************************************/ ************************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t retval; uint8_t retval;
+5 -5
View File
@@ -77,7 +77,7 @@ static xcpt_t g_irqsw0;
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -89,17 +89,17 @@ void board_button_initialize(void)
} }
/************************************************************************************ /************************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be called to collect * After board_button_initialize() has been called, board_buttons() may be called to collect
* the state of all buttons. up_buttons() returns an 8-bit bit set with each bit * the state of all buttons. board_buttons() returns an 8-bit bit set with each bit
* associated with a button. See the BUTTON* definitions above for the meaning of * associated with a button. See the BUTTON* definitions above for the meaning of
* each bit in the returned value. * each bit in the returned value.
* *
************************************************************************************/ ************************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return sam_gpioread(GPIO_SW0) ? 0 : BUTTON_SW0_BIT; return sam_gpioread(GPIO_SW0) ? 0 : BUTTON_SW0_BIT;
} }
+5 -5
View File
@@ -75,7 +75,7 @@ static xcpt_t g_irqbp2;
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -87,17 +87,17 @@ void board_button_initialize(void)
} }
/************************************************************************************ /************************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be called to collect * After board_button_initialize() has been called, board_buttons() may be called to collect
* the state of all buttons. up_buttons() returns an 8-bit bit set with each bit * the state of all buttons. board_buttons() returns an 8-bit bit set with each bit
* associated with a button. See the BUTTON* definitions above for the meaning of * associated with a button. See the BUTTON* definitions above for the meaning of
* each bit in the returned value. * each bit in the returned value.
* *
************************************************************************************/ ************************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return sam_gpioread(GPIO_BP2) ? 0 : BUTTON_BP2_BIT; return sam_gpioread(GPIO_BP2) ? 0 : BUTTON_BP2_BIT;
} }
+5 -5
View File
@@ -92,7 +92,7 @@ static xcpt_t g_irquser1;
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -104,17 +104,17 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* Description: * Description:
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON* definitions * with each bit associated with a button. See the BUTTON* definitions
* above for the meaning of each bit in the returned value. * above for the meaning of each bit in the returned value.
* *
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return sam_pioread(PIO_USER1) ? 0 : BUTTON_USER1_BIT; return sam_pioread(PIO_USER1) ? 0 : BUTTON_USER1_BIT;
} }
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/shenzhou/src/up_buttons.c * configs/shenzhou/src/board_buttons.c
* *
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -77,7 +77,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -98,10 +98,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -136,12 +136,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+3 -3
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/skp16c26/src/up_buttons.c * configs/skp16c26/src/board_buttons.c
* *
* Copyright (C) 2009 Gregory Nutt. All rights reserved. * Copyright (C) 2009 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -83,10 +83,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t swset = 0; uint8_t swset = 0;
uint8_t regval = getreg8(M16C_P8); uint8_t regval = getreg8(M16C_P8);
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/spark/src/up_buttons.c * configs/spark/src/board_buttons.c
* *
* Copyright (C) 2011-2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011-2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -69,7 +69,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -85,12 +85,12 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
* *
* N.B The return state in true logic, the button polarity is dealt here in * N.B The return state in true logic, the button polarity is dealt here in
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return stm32_gpioread(GPIO_BTN)==0 ? BUTTON_USER_BIT : 0; return stm32_gpioread(GPIO_BTN)==0 ? BUTTON_USER_BIT : 0;
} }
@@ -100,12 +100,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm3210e-eval/src/up_buttons.c * configs/stm3210e-eval/src/board_buttons.c
* *
* Copyright (C) 2009, 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2009, 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -137,12 +137,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm3220g-eval/src/up_buttons.c * configs/stm3220g-eval/src/board_buttons.c
* *
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -137,12 +137,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm3240g-eval/src/up_buttons.c * configs/stm3240g-eval/src/board_buttons.c
* *
* Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -137,12 +137,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm32f100rc_generic/src/up_buttons.c * configs/stm32f100rc_generic/src/board_buttons.c
* *
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -58,7 +58,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -70,10 +70,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@@ -87,12 +87,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm32f3discovery/src/up_buttons.c * configs/stm32f3discovery/src/board_buttons.c
* *
* Copyright (C) 2013 Gregory Nutt. All rights reserved. * Copyright (C) 2013 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -132,12 +132,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm32f429i-disco/src/up_buttons.c * configs/stm32f429i-disco/src/board_buttons.c
* *
* Copyright (C) 2011-2012, 2-14 Gregory Nutt. All rights reserved. * Copyright (C) 2011-2012, 2-14 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -132,12 +132,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm32f4discovery/src/up_buttons.c * configs/stm32f4discovery/src/board_buttons.c
* *
* Copyright (C) 2011-2012, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011-2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -132,12 +132,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/stm32ldiscovery/src/up_buttons.c * configs/stm32ldiscovery/src/board_buttons.c
* *
* Copyright (C) 2013-2014 Gregory Nutt. All rights reserved. * Copyright (C) 2013-2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -78,7 +78,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -99,10 +99,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -132,12 +132,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+6 -6
View File
@@ -58,7 +58,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -70,10 +70,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@@ -87,12 +87,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+6 -6
View File
@@ -129,7 +129,7 @@ static const uint8_t g_buttoncn[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -152,10 +152,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int id; int id;
@@ -178,12 +178,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/twr-k60n512/src/up_buttons.c * configs/twr-k60n512/src/board_buttons.c
* *
* Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved. * Copyright (C) 2011, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -74,7 +74,7 @@
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -89,10 +89,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@@ -114,12 +114,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+7 -7
View File
@@ -1,5 +1,5 @@
/**************************************************************************** /****************************************************************************
* configs/ubw32/src/up_buttons.c * configs/ubw32/src/board_buttons.c
* *
* Copyright (C) 2012 Gregory Nutt. All rights reserved. * Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -108,7 +108,7 @@ static const uint8_t g_buttoncn[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -127,10 +127,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int id; int id;
@@ -153,12 +153,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT definitions in * with each bit associated with a button. See the BUTTON_*_BIT definitions in
* board.h for the meaning of each bit. * board.h for the meaning of each bit.
* *
@@ -77,7 +77,7 @@ static const uint16_t g_buttons[NUM_BUTTONS] =
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -98,10 +98,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
int i; int i;
@@ -132,12 +132,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *
+1 -1
View File
@@ -82,7 +82,7 @@ void board_button_initialize(void)
} }
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
return stm32_gpioread(GPIO_PUSHBUTTON); return stm32_gpioread(GPIO_PUSHBUTTON);
} }
+9 -9
View File
@@ -1,11 +1,11 @@
/**************************************************************************** /****************************************************************************
* configs/zkit-arm-1769/src/up_buttons.c * configs/zkit-arm-1769/src/board_buttons.c
* arch/arm/src/board/up_buttons.c * arch/arm/src/board/board_buttons.c
* *
* Copyright (C) 2011 Zilogic Systems. All rights reserved. * Copyright (C) 2011 Zilogic Systems. All rights reserved.
* Author: Kannan <code@zilogic.com> * Author: Kannan <code@zilogic.com>
* *
* Based on configs/stm3210e-eval/src/up_buttons.c * Based on configs/stm3210e-eval/src/board_buttons.c
* *
* Copyright (C) 2009, 2011 Gregory Nutt. All rights reserved. * Copyright (C) 2009, 2011 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
@@ -87,7 +87,7 @@ static xcpt_t g_oldhandler;
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
@@ -108,10 +108,10 @@ void board_button_initialize(void)
} }
/**************************************************************************** /****************************************************************************
* Name: up_buttons * Name: board_buttons
****************************************************************************/ ****************************************************************************/
uint8_t up_buttons(void) uint8_t board_buttons(void)
{ {
uint8_t ret = 0; uint8_t ret = 0;
bool released; bool released;
@@ -139,12 +139,12 @@ uint8_t up_buttons(void)
* *
* Description: * Description:
* board_button_initialize() must be called to initialize button resources. After * board_button_initialize() must be called to initialize button resources. After
* that, up_buttons() may be called to collect the current state of all * that, board_buttons() may be called to collect the current state of all
* buttons or up_irqbutton() may be called to register button interrupt * buttons or up_irqbutton() may be called to register button interrupt
* handlers. * handlers.
* *
* After board_button_initialize() has been called, up_buttons() may be called to * After board_button_initialize() has been called, board_buttons() may be called to
* collect the state of all buttons. up_buttons() returns an 8-bit bit set * collect the state of all buttons. board_buttons() returns an 8-bit bit set
* with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT * with each bit associated with a button. See the BUTTON_*_BIT and JOYSTICK_*_BIT
* definitions in board.h for the meaning of each bit. * definitions in board.h for the meaning of each bit.
* *