Dronekit: Failed To Connect To /dev/tty.usbmodem1411 : 'serial' Object Has No Attribute 'setbaudrate'
Solution 1:
Fin, it looks like pySerial 3.0 was released in the past week which changes its API. pymavlink (used by DroneKit-Python) requires pySerial 2.0. I've filed an issue and will work to resolve it.
In the meantime, try pip install "pySerial>=2.0,<=2.9999"
and see if this resolves your problem.
Solution 2:
In the new python setBaudrate() looks removed from class SerialBase
. Please refer a similar issue of mavlink.
Solution 3:
Shot in the dark here, so apologies if this doesn't fix your problem, but I've suspicions that it will.
You need to install FTDI Drivers (https://learn.sparkfun.com/tutorials/how-to-install-ftdi-drivers/mac)
I had similar issues creating a serial connection over USB, using python, between my Arduino and my Mac running Mavericks and subsequently El Capitan. (Worked out of the box on Ubuntu, if you're afraid to mess with your fancy Mac) Expect this to break after an OSX upgrade. (Thanks Apple) It will also only work on the USB port that you specified during this process. So choose wisely ;)
Hope this helps. I lost days to this issue.
Post a Comment for "Dronekit: Failed To Connect To /dev/tty.usbmodem1411 : 'serial' Object Has No Attribute 'setbaudrate'"