Crazyflie 2.0, MAC OS X, Python3 Diagnostics Request

Post here to get support
Post Reply
silku62 smitha
Beginner
Posts: 1
Joined: Sun Sep 13, 2015 5:44 am

Crazyflie 2.0, MAC OS X, Python3 Diagnostics Request

Post by silku62 smitha »

I am using MAC OS X yosmite version and python 3.4.3

when I start the python3 bin/cflient, I see the window pop-up and able to see the control panel. But these are error messages on terminal being printed. In addition, I am able to connect over USB - but I cant tell whether I am talking to the crazyflie (one blue, one read is blinking and 1 LED is solid blue).

3 questions:
1) how can I tell I am talking to the copter over USB - the following messages appear on the terminal. (looking for devices never stops).
2) when I connect the radio, I am not sure it is connecting. what is wrong with radio? or how can I diagnose whether it is a setup problem or radio problem? or copter problem.
3) Is there a command to say "Spin motor blade 1, 2, 3, 4" - so I can see the visual effect of running a command and confirm that the USB connection is working or may be radio link is also working.

also, when I physically lift the copter by hand the "Flight Data" area is reflecting that I am moving the copter and changes the pitch/roll/yaw fields also. But at the bottom of the screen it says, "No input-device found, insert one to fly" - See the attached image.

Please advice. Thanks. (See screen shot of control Panel also)

Silku62

+++++
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cflib.crazyflie:Callback->Connection initialized[usb://0]
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cflib.crazyflie:We are connected[usb://0], request connection setup
INFO:cflib.crazyflie:Callback->Connected to [usb://0]
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cflib.crazyflie.toc:TOC for port [5] found in cache
INFO:cflib.crazyflie:Log TOC finished updating
INFO:cflib.crazyflie.mem:Requesting number of memories
INFO:cflib.crazyflie.mem:1 memories found
INFO:cflib.crazyflie.mem:Requesting first id
INFO:cflib.crazyflie.mem:Done getting all the memories, start reading the OWs
INFO:cflib.crazyflie:Memories finished updating
INFO:cflib.crazyflie.toc:TOC for port [2] found in cache
INFO:cflib.crazyflie:Param TOC finished updating
INFO:cflib.crazyflie:Callback->Connection setup finished [usb://0]
INFO:cfclient.utils.logconfigreader:Parsing [stabilizer.json]
===== 2015.09.12 22:09:20 =====
Traceback (most recent call last):
File "/Users/vatsan/crazyflie/py3/crazyflie-clients-python/lib/cfclient/ui/main.py", line 539, in _connected
mem = self.cf.mem.get_mems(MemoryElement.TYPE_DRIVER_LED)[0]
IndexError: tuple index out of range
INFO:cflib.crazyflie.mem:Updating content of memory 0
INFO:cflib.crazyflie.mem:Requesting new chunk of 16bytes at 0x0
===== 2015.09.12 22:09:20 =====
Traceback (most recent call last):
File "/Users/vatsan/crazyflie/py3/crazyflie-clients-python/lib/cfclient/ui/tabs/LEDTab.py", line 146, in _connected
MemoryElement.TYPE_DRIVER_LED)[0]
IndexError: tuple index out of range
INFO:cflib.crazyflie.log:Have successfully started logging for id=14
INFO:cflib.crazyflie.mem:READ: Mem=0, addr=0x0, status=0x0, data=(48, 120, 66, 67, 0, 80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 125)
INFO:cflib.crazyflie.mem:READING: We are still interested in request for mem 0
INFO:cflib.crazyflie.mem:Got new data: bytearray(b'0xBC\x00P\x00\x00\x00\x00\x00\x00\x00\x00\x00}')
INFO:cflib.crazyflie.log:Have successfully started logging for id=16
INFO:cfclient.ui.tabs.FlightTab:[imu_sensors.MS5611]: 1
INFO:cfclient.ui.tabs.FlightTab:[imu_sensors.HMC5883L]: 1
INFO:cflib.crazyflie.log:Have successfully started logging for id=17
INFO:cfclient.ui.tabs.FlightTab:Changed effect to 0
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Found 0 devices
INFO:cfclient.utils.input.inputreaders.pysdl2:Looking for devices
Attachments
CrzyFlie2.0_Panel.png
chad
Expert
Posts: 555
Joined: Sun Sep 28, 2014 12:54 am
Location: New York, USA
Contact:

Re: Crazyflie 2.0, MAC OS X, Python3 Diagnostics Request

Post by chad »

Those messages you see reflect that the python client is looking for a controller. That is, to use the python GUI client, it expects you also have a PS3, PS4, Xbox, or other similar controller plugged in. If you are seeing flight data coming in and the artificial horizon on the GUI is matching your motions, then the Crazyflie is communicating with the GUI client.

As far as "commands" to spin the rotors, please have a look at the files in crazyflie-clients-python/bin. Specifically the ramp.py example. That contains what your are looking for. They do not use the GUI however, they are simply python script examples to operate the Crazyflie.

Hope this helps!
Crazyflier - my CF journal...
4x Crazyflie Nano (1.0) 10-DOF + NeoPixel Ring mod.
3x Crazyflie 2.0 + Qi Charger and LED Decks.
Raspberry Pi Ground Control.
Mac OS X Dev Environment.
Walkera Devo7e, ESky ET6I, PS3 and iOS Controllers.
Post Reply