Loading...
Searching...
No Matches
board.h File Reference

Board specific configuration for the BBC micro:bit v2. More...

Detailed Description

Board specific configuration for the BBC micro:bit v2.

Author
Alexandre Abadie alexa.nosp@m.ndre.nosp@m..abad.nosp@m.ie@i.nosp@m.nria..nosp@m.fr

Definition in file board.h.

#include "board_common.h"
+ Include dependency graph for board.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

LED matrix pin configuration

#define MICROBIT_LED_COL1   GPIO_PIN(0, 28)
 
#define MICROBIT_LED_COL2   GPIO_PIN(0, 11)
 
#define MICROBIT_LED_COL3   GPIO_PIN(0, 31)
 
#define MICROBIT_LED_COL4   GPIO_PIN(1, 5)
 
#define MICROBIT_LED_COL5   GPIO_PIN(0, 30)
 
#define MICROBIT_LED_ROW1   GPIO_PIN(0, 21)
 
#define MICROBIT_LED_ROW2   GPIO_PIN(0, 22)
 
#define MICROBIT_LED_ROW3   GPIO_PIN(0, 15)
 
#define MICROBIT_LED_ROW4   GPIO_PIN(0, 24)
 
#define MICROBIT_LED_ROW5   GPIO_PIN(0, 19)
 

Button configuration

#define BTN0_PIN   GPIO_PIN(0, 14)
 
#define BTN0_MODE   GPIO_IN
 
#define BTN1_PIN   GPIO_PIN(0, 23)
 
#define BTN1_MODE   GPIO_IN
 
#define BTN2_PIN   GPIO_PIN(1, 4)
 
#define BTN2_MODE   GPIO_IN
 
#define BTN3_PIN   GPIO_PIN(0, 2)
 
#define BTN3_MODE   GPIO_IN
 
#define BTN4_PIN   GPIO_PIN(0, 3)
 
#define BTN4_MODE   GPIO_IN
 
#define BTN5_PIN   GPIO_PIN(0, 4)
 
#define BTN5_MODE   GPIO_IN
 

Microphone

#define RUN_MIC_PIN   GPIO_PIN(0, 20)
 
#define MIC_IN_PIN   GPIO_PIN(0, 5)
 

Speaker

#define SPEAKER_PIN   GPIO_PIN(0, 0)
 

LSM303AGR accelerometer/magnetometer

#define LSM303AGR_PARAM_ACC_ADDR   0x19
 
#define LSM303AGR_PARAM_MAG_ADDR   0x1E
 

Macro Definition Documentation

◆ BTN0_MODE

#define BTN0_MODE   GPIO_IN

Definition at line 49 of file board.h.

◆ BTN0_PIN

#define BTN0_PIN   GPIO_PIN(0, 14)

Definition at line 48 of file board.h.

◆ BTN1_MODE

#define BTN1_MODE   GPIO_IN

Definition at line 51 of file board.h.

◆ BTN1_PIN

#define BTN1_PIN   GPIO_PIN(0, 23)

Definition at line 50 of file board.h.

◆ BTN2_MODE

#define BTN2_MODE   GPIO_IN

Definition at line 54 of file board.h.

◆ BTN2_PIN

#define BTN2_PIN   GPIO_PIN(1, 4)

Definition at line 53 of file board.h.

◆ BTN3_MODE

#define BTN3_MODE   GPIO_IN

Definition at line 57 of file board.h.

◆ BTN3_PIN

#define BTN3_PIN   GPIO_PIN(0, 2)

Definition at line 56 of file board.h.

◆ BTN4_MODE

#define BTN4_MODE   GPIO_IN

Definition at line 60 of file board.h.

◆ BTN4_PIN

#define BTN4_PIN   GPIO_PIN(0, 3)

Definition at line 59 of file board.h.

◆ BTN5_MODE

#define BTN5_MODE   GPIO_IN

Definition at line 63 of file board.h.

◆ BTN5_PIN

#define BTN5_PIN   GPIO_PIN(0, 4)

Definition at line 62 of file board.h.

◆ LSM303AGR_PARAM_ACC_ADDR

#define LSM303AGR_PARAM_ACC_ADDR   0x19

Definition at line 85 of file board.h.

◆ LSM303AGR_PARAM_MAG_ADDR

#define LSM303AGR_PARAM_MAG_ADDR   0x1E

Definition at line 86 of file board.h.

◆ MIC_IN_PIN

#define MIC_IN_PIN   GPIO_PIN(0, 5)

Definition at line 71 of file board.h.

◆ MICROBIT_LED_COL1

#define MICROBIT_LED_COL1   GPIO_PIN(0, 28)

Definition at line 32 of file board.h.

◆ MICROBIT_LED_COL2

#define MICROBIT_LED_COL2   GPIO_PIN(0, 11)

Definition at line 33 of file board.h.

◆ MICROBIT_LED_COL3

#define MICROBIT_LED_COL3   GPIO_PIN(0, 31)

Definition at line 34 of file board.h.

◆ MICROBIT_LED_COL4

#define MICROBIT_LED_COL4   GPIO_PIN(1, 5)

Definition at line 35 of file board.h.

◆ MICROBIT_LED_COL5

#define MICROBIT_LED_COL5   GPIO_PIN(0, 30)

Definition at line 36 of file board.h.

◆ MICROBIT_LED_ROW1

#define MICROBIT_LED_ROW1   GPIO_PIN(0, 21)

Definition at line 37 of file board.h.

◆ MICROBIT_LED_ROW2

#define MICROBIT_LED_ROW2   GPIO_PIN(0, 22)

Definition at line 38 of file board.h.

◆ MICROBIT_LED_ROW3

#define MICROBIT_LED_ROW3   GPIO_PIN(0, 15)

Definition at line 39 of file board.h.

◆ MICROBIT_LED_ROW4

#define MICROBIT_LED_ROW4   GPIO_PIN(0, 24)

Definition at line 40 of file board.h.

◆ MICROBIT_LED_ROW5

#define MICROBIT_LED_ROW5   GPIO_PIN(0, 19)

Definition at line 41 of file board.h.

◆ RUN_MIC_PIN

#define RUN_MIC_PIN   GPIO_PIN(0, 20)

Definition at line 70 of file board.h.

◆ SPEAKER_PIN

#define SPEAKER_PIN   GPIO_PIN(0, 0)

Definition at line 78 of file board.h.