Skip to content

Commit bebb404

Browse files
committed
alif/boards/OPENMV_AE3: Configure sensor interrupts as GPIO input.
They can wake the device from deepsleep. Signed-off-by: Damien George <damien@micropython.org>
1 parent 1a01f76 commit bebb404

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

ports/alif/boards/OPENMV_AE3/board.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,11 @@ void board_early_init(void) {
167167
MICROPY_BOARD_FATAL_ERROR("se_services_select_pll_source");
168168
}
169169

170+
// Configure the sensor interrupts inputs.
171+
mp_hal_pin_input(pin_IMU_INT1);
172+
mp_hal_pin_input(pin_IMU_INT2);
173+
mp_hal_pin_input(pin_TOF_I2C_INT);
174+
170175
// Configure the user button as an input (it has an external pull-up).
171176
mp_hal_pin_input(pin_SW);
172177
}

ports/alif/boards/OPENMV_AE3/pins.csv

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ LED_RED,P0_0
77
LED_GREEN,P6_3
88
LED_BLUE,P6_0
99

10+
# Sensor interrupts
11+
IMU_INT1,P15_4
12+
IMU_INT2,P15_5
13+
TOF_I2C_INT,P15_6
14+
1015
# User switch
1116
SW,P15_7
1217

0 commit comments

Comments
 (0)