Unable to follow beginner recommendations

Discussions about all things Bitcraze
Post Reply
schmelle2
Beginner
Posts: 3
Joined: Sun Nov 15, 2020 7:09 pm
Contact:

Unable to follow beginner recommendations

Post by schmelle2 »

Hi, I'm new to Crazyflie and this forum.

I tried to follow your beginner suggestions with the bitcrazeVM from the website.
Unfortunately, after updating the project with the script, the CF Client didn't work anymore. He died with an error message.
I think ok. This can happen because the VM is very old. I started Eclipse and saw that there are a few updates for the installed addons available (c/c++). During the update, I received an error message and yeah, no further updates are working.

Ok. I installed a fresh Ubuntu 20.04 Desktop environment within Virtualbox to start from the beginning.
I installed the CF-Client, as suggested, with snap.

Code: Select all

snap install --edge cfclient
snap connect cfclient:raw-usb    # Required to access the Crazyradio
snap connect cfclient:joystick   # Required to access gamepads
What should I say? The client din't work and died with a long error message.....

Code: Select all

INFO:__main__:Disabling STL printouts
INFO:cfclient.utils.input.inputreaders:Input readers: ['linuxjsdev', 'pysdl2']
INFO:cfclient.utils.input.inputreaders:Successfully initialized [linuxjsdev]
INFO:cfclient.utils.input.inputreaders:Could not initialize [pysdl2]: No SDL2 support on Linux
INFO:cfclient.utils.input.inputinterfaces:Found interfaces: ['leapmotion', 'wiimote', 'zmqpull']
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [leapmotion]: Leap Motion library probably not installed (No module named 'leapsdk')
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [wiimote]: Missing cwiid (wiimote) driver No module named 'cwiid'
INFO:cfclient.utils.config:Dist config read from /snap/cfclient/69/lib/python3.6/site-packages/cfclient/configs/config.json
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
INFO:cfclient.utils.zmq_led_driver:ZMQ led disabled in config file
INFO:cfclient.utils.zmq_param:ZMQ param disabled in config file
INFO:cfclient.utils.input:Using device blacklist [(VirtualBox|VMware)]
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.crtp.prrtdriver:Initialized PRRT driver.
WARNING: could not determine DPI
WARNING:vispy:could not determine DPI
WARNING: Although PyQt5 is already imported, the PyQt5 backend could not
be used ("cannot import name 'QtOpenGL'"). 
Note that running multiple GUI toolkits simultaneously can cause side effects.
WARNING:vispy:Although PyQt5 is already imported, the PyQt5 backend could not
be used ("cannot import name 'QtOpenGL'"). 
Note that running multiple GUI toolkits simultaneously can cause side effects.
libEGL warning: DRI2: failed to authenticate
===== 2020.11.15 20:11:57 =====
Traceback (most recent call last):
  File "/snap/cfclient/69/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/snap/cfclient/69/usr/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/snap/cfclient/69/lib/python3.6/site-packages/cfclient/gui.py", line 197, in <module>
    main()
  File "/snap/cfclient/69/lib/python3.6/site-packages/cfclient/gui.py", line 189, in main
    main_window = MainUI()
  File "/snap/cfclient/69/lib/python3.6/site-packages/cfclient/ui/main.py", line 266, in __init__
    tab = tabClass(self.tabs, cfclient.ui.pluginhelper)
  File "/snap/cfclient/69/lib/python3.6/site-packages/cfclient/ui/tabs/locopositioning_tab.py", line 469, in __init__
    self._set_up_plots()
  File "/snap/cfclient/69/lib/python3.6/site-packages/cfclient/ui/tabs/locopositioning_tab.py", line 500, in _set_up_plots
    self._plot_3d.native.setSizePolicy(sizePolicy)
AttributeError: 'CanvasBackend' object has no attribute 'setSizePolicy'
Hmmm, frustrating.

I think ok, this can't be so difficult. I tried to install the recommended toolchain (yeah, ! read that's for Ubuntu 16.04 & 18.04):

Code: Select all

sudo add-apt-repository ppa:team-gcc-arm-embedded/ppa
sudo apt-get update
sudo apt install gcc-arm-embedded
You already suspect it, or?

Code: Select all

Get:10 http://de.archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 DEP-11 Metadata [2.468 B]       
Reading package lists... Done                                                                          
E: The repository 'http://ppa.launchpad.net/team-gcc-arm-embedded/ppa/ubuntu focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
Other steps I tried:
Updating the bitcrazeVM to Ubuntu 18.04 didn't help, too.

At the moment I have electronic scrap here for over 400€. Actually, I wanted to solve a simple task to occupy a parking lot with a drone as proof of concept. But at the moment I am just frustrated because nothing works.

Please help me, maybe with a simple manual, what I need to successfully program my Crazyflie (except Eclipse and Visual Studio code).


Thanks a lot!
schmelle2
schmelle2
Beginner
Posts: 3
Joined: Sun Nov 15, 2020 7:09 pm
Contact:

Re: Unable to follow beginner recommendations

Post by schmelle2 »

Further investigation:
I setup an Ubuntu 18.04 Desktop environment VM yesterday evening and installed the CF-Client as suggested with snap.
Same error message as in my previous message on Ubuntu 20.04. :(

Thanks for your help!

Best
schmelle2
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: Unable to follow beginner recommendations

Post by arnaud »

Hi,

Sorry for the frustration, things are a little bit in flux at the moment and the snap is currently broken (hence it being only published in the edge channel). Once I fix it I will publish a beta and update the Readme.

I started a new fresh Ubuntu 20.04 VM to go through the install step again and fix what needed to be fixed. Using the followind docs I could get the client running was able to build and debug the Crazyflie firmware from the VM:

Installing the client from source as described in the readme works: https://github.com/bitcraze/crazyflie-c ... md#linux-1. I updated it a bit to add the required package to install to a fresh Ubuntu install (git and python3-pip).

Note that, as written at the end of the readme, udev rules file need to be installed as well: https://github.com/bitcraze/crazyflie-lib-python#linux. My plan it to add this as a warning in the client if an access right problem is detected.

As for the development side, this page is up to date for installing the compiler and configuring vscode for debugging, I just updated gdb configuration to work with 20.04: https://github.com/bitcraze/crazyflie-f ... bugging.md.

Do not hesitate if you have further questions.
schmelle2
Beginner
Posts: 3
Joined: Sun Nov 15, 2020 7:09 pm
Contact:

[SOLVED] Re: Unable to follow beginner recommendations

Post by schmelle2 »

Hi Arnaud,
I didn't think I would get an answer, because I violated several forum rules. But I have to say to my excuse that I was really frustrated and helpless last night. I thank you very much for your great answer and I am waiting for the new VM and the other things.
I'll try the suggestions, you mentioned.

Once again, thank you very much!

Many greetings
schmelle2 8-)
Post Reply