Skip to content

Commit cf7b5cf

Browse files
authored
follow_me_example: also check home position
Some versions of PX4 fail with this example because GPS checks are passed before a home position is set. The example code tries to arm without home position then, which is rejected.
1 parent 50604c1 commit cf7b5cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/follow_me_example.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ async def fly_drone():
2828

2929
#Checking if Global Position Estimate is ok
3030
async for global_lock in drone.telemetry.health():
31-
if global_lock.is_global_position_ok:
31+
if global_lock.is_global_position_ok and global_lock.is_home_position_ok:
3232
print("-- Global position state is good enough for flying.")
3333
break
3434

0 commit comments

Comments
 (0)