From 187b79fa74e88fdd1aa84d0ff11f004c9d6d2b15 Mon Sep 17 00:00:00 2001 From: dylad Date: Mon, 15 Mar 2021 21:26:50 +0100 Subject: [PATCH] boards: use BTNx_MODE when defined --- boards/calliope-mini/board.c | 4 ++-- boards/microbit-v2/board.c | 4 ++-- boards/microbit/board.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/boards/calliope-mini/board.c b/boards/calliope-mini/board.c index c1460d791d..c8454ed710 100644 --- a/boards/calliope-mini/board.c +++ b/boards/calliope-mini/board.c @@ -27,6 +27,6 @@ void board_init(void) cpu_init(); /* initialize the mini's buttons */ - gpio_init(BTN0_PIN, GPIO_IN); - gpio_init(BTN1_PIN, GPIO_IN); + gpio_init(BTN0_PIN, BTN0_MODE); + gpio_init(BTN1_PIN, BTN1_MODE); } diff --git a/boards/microbit-v2/board.c b/boards/microbit-v2/board.c index 15fd5ecd70..0a130b26a9 100644 --- a/boards/microbit-v2/board.c +++ b/boards/microbit-v2/board.c @@ -27,6 +27,6 @@ void board_init(void) cpu_init(); /* initialize the on board buttons */ - gpio_init(BTN0_PIN, GPIO_IN); - gpio_init(BTN1_PIN, GPIO_IN); + gpio_init(BTN0_PIN, BTN0_MODE); + gpio_init(BTN1_PIN, BTN1_MODE); } diff --git a/boards/microbit/board.c b/boards/microbit/board.c index 355ef33569..d2c7ab8453 100644 --- a/boards/microbit/board.c +++ b/boards/microbit/board.c @@ -27,6 +27,6 @@ void board_init(void) cpu_init(); /* initialize the micro:bit's buttons */ - gpio_init(BTN0_PIN, GPIO_IN); - gpio_init(BTN1_PIN, GPIO_IN); + gpio_init(BTN0_PIN, BTN0_MODE); + gpio_init(BTN1_PIN, BTN1_MODE); }