Use BOARD_SW[23]_GPIO{_PIN} macros wherever possible.

This commit is contained in:
László Monda
2016-02-27 12:51:38 +01:00
parent 00c9659c16
commit d429980975
3 changed files with 7 additions and 4 deletions
+2 -1
View File
@@ -1,3 +1,4 @@
#include "include/board/board.h"
#include "fsl_gpio.h"
#include "usb_device_config.h"
#include "usb.h"
@@ -15,7 +16,7 @@ static usb_device_hid_keyboard_struct_t UsbKeyboardDevice;
static usb_status_t UsbKeyboardAction(void)
{
UsbKeyboardDevice.buffer[2] = 0x00U;
if (!GPIO_ReadPinInput(GPIOB, 17U)) {
if (!GPIO_ReadPinInput(BOARD_SW3_GPIO, BOARD_SW3_GPIO_PIN)) {
UsbKeyboardDevice.buffer[2] = KEY_A;
}
return USB_DeviceHidSend(UsbCompositeDevice.keyboardHandle, USB_KEYBOARD_ENDPOINT_ID,