2022-09-06 10:49:49 -03:00

30 lines
465 B
Python

from machine import ADC, I2C, Pin, PWM
import time
import hall_sensor
import pressure_sensor
from display import Display
from states import StateMachine
def setup():
Display()
hall_sensor.start_hall_sensor()
def loop():
StateMachine().start_task_loop()
def handle_error():
Display.print('Exception')
if __name__ == "__main__":
setup()
try:
while(True):
loop()
except:
handle_error()
raise