Open technorior opened 7 years ago
I have this problem too in Python 3.5.3 and dronekit 2.9.1, without the No IO Thread Heartbeat
part.
In [3]: v = connect('/dev/ttyACM0')
Device /dev/ttyACM0 is dead
>>> EKF2 IMU1 initial yaw alignment complete
>>> EKF2 IMU0 initial yaw alignment complete
>>> GPS 0: detected as u-blox at 38400 baud
>>> EKF2 IMU0 tilt alignment complete
>>> EKF2 IMU1 tilt alignment complete
>>> GPS 0: detected as u-blox at 115200 baud
>>> u-blox 0 HW: 00080000 SW: ROM CORE 3.01 (107888)
It prints out information about the IMU and GPS but never returns to the interactive session.
I have the same problem of @technorior with a Pixhawk Falcon, running the latest PX4 firmware, connected to a Raspberry Pi 3 Model B via serial port..
@Evidlo What interactive session? dronekit-python doesn't do those naturally.
@technorior Try using /dev/serial/by-id/<YOURDEVICENAME>
instead of /dev/ttyACM0
- you're more likely to be able to reconnect to that if the device reboots.
@technorior The "No IO Thread Heartbeat" is probably because you don't have an SD card inserted.
I fixed this problem by patching pymavlink.
I no longer have a Pixhawk, so I can't confirm. It doesn't happen when connecting to the simulator.
@peterbarker All I meant was that connect()
blocks forever.
Should be fixed in master.
I think this issue can be closed after the latest fixes in the Python 3 support.
I found same problem on ArduPilot Copter 3.6.3, Python 3.7.1, Windows 10, and dronekit (latest github repo master).
Device com3 is dead
Exception in MAVLink input loop
Traceback (most recent call last):
File "C:\Users\otsuka\AppData\Local\Programs\Python\Python37-32\lib\site-packages\dronekit\mavlink.py", line 210, in mavlink_thread_in
fn(self)
File "C:\Users\otsuka\AppData\Local\Programs\Python\Python37-32\lib\site-packages\dronekit\__init__.py", line 1370, in listener
self._heartbeat_error)
dronekit.APIException: No heartbeat in 30 seconds, aborting.
APM: Copter v3.5.3 when I use:
vehicle = connect("/dev/ttyACM0", boud=ANY)
in python 2 work great, but in python 3 I have message:and then