Skip to content

Commit

Permalink
Only disable once
Browse files Browse the repository at this point in the history
  • Loading branch information
misko committed Mar 13, 2024
1 parent 4a74bf9 commit 2351aac
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions spf/mavlink/mavlink_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -742,8 +742,9 @@ def handle_RC_CHANNELS(self, msg):
self.reboot()
sys.exit(1)
elif msg.chan12_raw > 1000:
logging.info("DISABLE ULTRASONIC")
self.disable_distance_finder = True
if not self.disable_distance_finder:
logging.info("DISABLE ULTRASONIC")
self.disable_distance_finder = True

def handle_SERVO_OUTPUT_RAW(self, msg):
if msg.servo1_raw == 1500 and msg.servo3_raw == 1500:
Expand Down

0 comments on commit 2351aac

Please sign in to comment.