feat: made walle targets thread safer

This commit is contained in:
2020-08-28 13:43:30 +02:00
parent 44cb97b44e
commit 02fa0c3ee6

View File

@@ -52,7 +52,8 @@ class WallE:
def tick(self):
remove = {}
for channel, target in self.servo_targets.items():
targets = list(self.servo_targets.items())
for channel, target in targets:
current_value = self.servo_positions[channel]
if target == current_value:
remove[channel] = target