summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--drivers/display/ssd1306.py1
-rw-r--r--drivers/nrf24l01/nrf24l01.py1
-rw-r--r--drivers/sdcard/sdcard.py1
-rw-r--r--esp8266/modules/ds18x20.py2
-rw-r--r--esp8266/modules/onewire.py1
-rw-r--r--stmhal/boards/STM32F4DISC/staccel.py1
6 files changed, 7 insertions, 0 deletions
diff --git a/drivers/display/ssd1306.py b/drivers/display/ssd1306.py
index 34dca769e9..ad57725e74 100644
--- a/drivers/display/ssd1306.py
+++ b/drivers/display/ssd1306.py
@@ -1,5 +1,6 @@
# MicroPython SSD1306 OLED driver, I2C and SPI interfaces
+from micropython import const
import time
import framebuf
diff --git a/drivers/nrf24l01/nrf24l01.py b/drivers/nrf24l01/nrf24l01.py
index a244b0b25d..3c79650bf0 100644
--- a/drivers/nrf24l01/nrf24l01.py
+++ b/drivers/nrf24l01/nrf24l01.py
@@ -1,6 +1,7 @@
"""NRF24L01 driver for Micro Python
"""
+from micropython import const
import pyb
# nRF24L01+ registers
diff --git a/drivers/sdcard/sdcard.py b/drivers/sdcard/sdcard.py
index fc7a8af7c5..191630aebd 100644
--- a/drivers/sdcard/sdcard.py
+++ b/drivers/sdcard/sdcard.py
@@ -21,6 +21,7 @@ Example usage on ESP8266:
"""
+from micropython import const
import time
diff --git a/esp8266/modules/ds18x20.py b/esp8266/modules/ds18x20.py
index fc53048f8e..bf06094835 100644
--- a/esp8266/modules/ds18x20.py
+++ b/esp8266/modules/ds18x20.py
@@ -1,6 +1,8 @@
# DS18x20 temperature sensor driver for MicroPython.
# MIT license; Copyright (c) 2016 Damien P. George
+from micropython import const
+
_CONVERT = const(0x44)
_RD_SCRATCH = const(0xbe)
_WR_SCRATCH = const(0x4e)
diff --git a/esp8266/modules/onewire.py b/esp8266/modules/onewire.py
index 06b216a57a..83318d1a47 100644
--- a/esp8266/modules/onewire.py
+++ b/esp8266/modules/onewire.py
@@ -1,6 +1,7 @@
# 1-Wire driver for MicroPython on ESP8266
# MIT license; Copyright (c) 2016 Damien P. George
+from micropython import const
import _onewire as _ow
class OneWireError(Exception):
diff --git a/stmhal/boards/STM32F4DISC/staccel.py b/stmhal/boards/STM32F4DISC/staccel.py
index 7296662cac..2f2561d1cb 100644
--- a/stmhal/boards/STM32F4DISC/staccel.py
+++ b/stmhal/boards/STM32F4DISC/staccel.py
@@ -14,6 +14,7 @@ See:
STM32Cube_FW_F4_V1.1.0/Projects/STM32F4-Discovery/Demonstrations/Src/main.c
"""
+from micropython import const
from pyb import Pin
from pyb import SPI