From d689430e790bfbd40a4fc3139b118aee5576baf7 Mon Sep 17 00:00:00 2001 From: Damien George Date: Sun, 20 Apr 2014 00:16:30 +0100 Subject: stmhal: Add SPI class. Also some updates to compile with latest changes to core py. --- stmhal/modpyb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'stmhal/modpyb.c') diff --git a/stmhal/modpyb.c b/stmhal/modpyb.c index 56a7233cc2..6fb5cdd846 100644 --- a/stmhal/modpyb.c +++ b/stmhal/modpyb.c @@ -18,6 +18,8 @@ #include "usrsw.h" #include "rng.h" #include "rtc.h" +#include "i2c.h" +#include "spi.h" #include "usart.h" #include "adc.h" #include "storage.h" @@ -25,7 +27,6 @@ #include "accel.h" #include "servo.h" #include "dac.h" -#include "i2c.h" #include "usb.h" #include "modpyb.h" #include "ff.h" @@ -290,6 +291,7 @@ STATIC const mp_map_elem_t pyb_module_globals_table[] = { { MP_OBJ_NEW_QSTR(MP_QSTR_LED), (mp_obj_t)&pyb_led_type }, { MP_OBJ_NEW_QSTR(MP_QSTR_I2C), (mp_obj_t)&pyb_i2c_type }, + { MP_OBJ_NEW_QSTR(MP_QSTR_SPI), (mp_obj_t)&pyb_spi_type }, { MP_OBJ_NEW_QSTR(MP_QSTR_USART), (mp_obj_t)&pyb_usart_type }, { MP_OBJ_NEW_QSTR(MP_QSTR_ADC), (mp_obj_t)&pyb_adc_type }, -- cgit v1.2.3