Skip to content

Commit 384f7bd

Browse files
committed
Travis fixes
1 parent 358bf78 commit 384f7bd

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

PyPortal_Smart_Switch/code.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
import gc
33
import board
44
import busio
5-
import adafruit_esp32spi
6-
import adafruit_esp32spi.adafruit_esp32spi_socket as socket
7-
from adafruit_esp32spi import adafruit_esp32spi
5+
from import adafruit_esp32spi import adafruit_esp32spi_socket as socket
6+
#import adafruit_esp32spi.adafruit_esp32spi_socket as socket
7+
from adafruit_esp32spi import adafruit_esp32spi, adafruit_esp32spi_wifimanager
88
import adafruit_requests as requests
99
import digitalio
1010
import analogio
@@ -15,7 +15,6 @@
1515
from adafruit_display_text import label
1616
import adafruit_touchscreen
1717

18-
from adafruit_esp32spi import adafruit_esp32spi_wifimanager
1918
from adafruit_minimqtt import MQTT
2019

2120
DISPLAY_COLOR = 0x4444FF
@@ -85,7 +84,7 @@
8584
time_font = bitmap_font.load_font("/fonts/RobotoMono-72.bdf")
8685
time_font.load_glyphs(b'0123456789:')
8786

88-
def get_local_timestamp(self, location=None):
87+
def get_local_timestamp(location=None):
8988
# pylint: disable=line-too-long
9089
"""Fetch and "set" the local time of this microcontroller to the local time at the location, using an internet time API.
9190
:param str location: Your city and country, e.g. ``"New York, US"``.
@@ -221,7 +220,7 @@ def tick(self, now):
221220
if self.current_time.tm_hour >= 12:
222221
ampm_string = "PM"
223222
self.text_areas[1].text = ampm_string
224-
self.text_areas[2].text = (months[int(self.current_time.tm_mon - 1)] +
223+
self.text_areas[2].text = (months[int(self.current_time.tm_mon - 1)] +
225224
" " + str(self.current_time.tm_mday))
226225
board.DISPLAY.refresh_soon()
227226
board.DISPLAY.wait_for_frame()

0 commit comments

Comments
 (0)