alduxvm / pyMultiWii

MultiWii Serial Protocol (MSP) API to send and receive data from firmware using MSP
GNU General Public License v3.0
154 stars 85 forks source link

Strange Connection Bug with CleanFlight 2.2.0-RC1 #17

Open nik012003 opened 6 years ago

nik012003 commented 6 years ago

Hi guys, I'm trying to get the ATTITUDE of my board with this python code:

from pymultiwii import MultiWii
serialPort = "/dev/tty.SLAB_USBtoUART"
board = MultiWii(serialPort)
while True:
    print board.getData(MultiWii.ATTITUDE)

I always get a series of "None" in my terminal. When I open CF-Configurator and click on connect, on the terminal I start to see all the normal output like: {'timestamp': '1514405918.46', 'elapsed': 0.052, 'angx': 0.0, 'angy': 0.1, 'heading': 181.0} Has anyone faced this issue? EDIT: issue fixed with my PR #18