fix
This commit is contained in:
parent
d07a616462
commit
96f187910b
@ -48,7 +48,7 @@ class TrafficLight:
|
||||
# therefore it sleeps on the end of the loop and first status is immediately sent to msg broker
|
||||
self.current_color = TrafficLight.Color((self._starting_color.value - 1) % num_colors)
|
||||
while self.running:
|
||||
self.current_color = self.Color((self.current_color.value + 1) % num_colors)
|
||||
self.current_color = TrafficLight.Color((self.current_color.value + 1) % num_colors)
|
||||
self.last_switch = datetime.now()
|
||||
self.send_status_update()
|
||||
time.sleep(self.switching_time / SCALING)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user