Skip to content

Commit c933e70

Browse files
committed
appease the linter
1 parent 2142041 commit c933e70

File tree

5 files changed

+59
-212
lines changed

5 files changed

+59
-212
lines changed

config.json

Lines changed: 0 additions & 89 deletions
This file was deleted.

src/flight-software/boot.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# from busio import _spi_init
22
# import os
33
# from lib.pysquared.nvm.counter import Counter
4-
import os
54

65
# import board
76
# import sdcardio
@@ -11,13 +10,11 @@
1110
# This is the correct method for CircuitPython 9+
1211
storage.disable_usb_drive() # disable CIRCUITPY
1312
try:
14-
with open('/sd/leaderboard.json', 'r') as file:
13+
with open("/sd/leaderboard.json", "r") as file:
1514
pass # File exists
1615
except OSError:
17-
with open('/sd/leaderboard.json', 'w') as file:
18-
file.write('{}')
19-
20-
16+
with open("/sd/leaderboard.json", "w") as file:
17+
file.write("{}")
2118

2219

2320
# After the USB drive is disabled, we can remount the /sd filesystem

src/flight-software/main.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import gc
2-
import json
31
import os
42
import time
53

@@ -22,8 +20,8 @@
2220
from lib.pysquared.rtc.manager.microcontroller import MicrocontrollerManager
2321
from lib.pysquared.sleep_helper import SleepHelper
2422
from lib.pysquared.watchdog import Watchdog
23+
from utils import listener_nominal_power_loop
2524
from version import __version__
26-
from utils import nominal_power_loop, listener_nominal_power_loop
2725

2826
boot_time: float = time.time()
2927

@@ -139,7 +137,7 @@
139137
while True:
140138
# TODO(nateinaction): Modify behavior based on power state
141139
listener_nominal_power_loop(logger, uhf_packet_manager, sleep_helper)
142-
#nominal_power_loop(logger, uhf_packet_manager, sleep_helper, cube_ids=["Listener1", "Listener2", "Listener3"])
140+
# nominal_power_loop(logger, uhf_packet_manager, sleep_helper, cube_ids=["Listener1", "Listener2", "Listener3"])
143141

144142
except Exception as e:
145143
logger.critical("Critical in Main Loop", e)

src/flight-software/repl.py

Lines changed: 6 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,13 @@
33

44
import board
55
import digitalio
6-
7-
from lib.adafruit_tca9548a import TCA9548A # This is Hacky V5a Devel Stuff###
8-
9-
import storage
10-
116
import microcontroller
7+
import storage
8+
from lib.adafruit_mcp230xx.mcp23017 import (
9+
MCP23017, # This is Hacky V5a Devel Stuff###
10+
)
11+
from lib.adafruit_tca9548a import TCA9548A # This is Hacky V5a Devel Stuff###
1212

13-
#hard reboot = microcontroller.reset()
14-
# do an on boot file later
15-
#need to call this to write new code to the board, otherwise the baord will not appear!
16-
def erase_system():
17-
storage.erase_filesystem()
18-
19-
def hard_reboot():
20-
microcontroller.reset()
2113
# from lib.pysquared.Big_Data import AllFaces ### This is Hacky V5a Devel Stuff##
2214
from lib.pysquared.beacon import Beacon
2315
from lib.pysquared.cdh import CommandDataHandler
@@ -40,15 +32,6 @@ def hard_reboot():
4032

4133
# Local imports
4234
from version import __version__
43-
from utils import (
44-
nominal_power_loop,
45-
listener_nominal_power_loop,
46-
test_sd,
47-
update_leaderboard,
48-
display_leaderboard,
49-
send_leaderboard,
50-
send_leaderboard_power_loop,
51-
)
5235

5336

5437
def erase_system():
@@ -64,7 +47,7 @@ def hard_reboot():
6447
def get_temp(sensor):
6548
"""
6649
Get temperature readings from a sensor for testing purposes.
67-
50+
6851
Args:
6952
sensor: Temperature sensor object
7053
"""
@@ -231,8 +214,6 @@ def all_faces_on():
231214
FACE4_ENABLE.value = True
232215

233216

234-
235-
236217
## Face Sensor Stuff ##
237218

238219
# This is the TCA9548A I2C Multiplexer
@@ -274,4 +255,3 @@ def all_faces_on():
274255
antenna_deployment = BurnwireManager(
275256
logger, burnwire_heater_enable, burnwire1_fire, enable_logic=True
276257
)
277-

0 commit comments

Comments
 (0)