Radio Not Connecting

Discussions about all things Bitcraze
Post Reply
zachterrell57
Beginner
Posts: 9
Joined: Mon Oct 14, 2019 5:02 am

Radio Not Connecting

Post by zachterrell57 » Tue Jan 14, 2020 3:54 am

Hi all,

My crazyradio has never been fully functioning, and I am not sure whether or not that is a manufacturer or user error. Until recently, the radio would connect to the drone for about 10 seconds, and then disconnect. I don't think the radio ever connected for more than 20 seconds. By the way, I am running the virtual machine on a macbook pro. As of three days ago, the client will no longer recognize that the radio is even plugged in. When I insert the radio into the usb port, it briefly flashes red, and then turns off. I am then left with these messages in the console:

Code: Select all

INFO:cfclient.gui: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 /home/bitcraze/projects/crazyflie-clients-python/src/cfclient/configs/config.json
INFO:cfclient.utils.config:Config file read from [/home/bitcraze/.config/cfclient/config.json]
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
INFO:cfclient.utils.zmq_param:Biding ZMQ for parameters at tcp://*:1213
INFO:cfclient.utils.zmq_led_driver:Biding ZMQ for LED driverat tcp://*:1214
INFO:cfclient.utils.input:Using device blacklist [(VirtualBox|VMware)]
INFO:cfclient.ui.main:Auto reconnect enabled: True
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cfclient.ui.tabs.QualisysTab:Switching Flight Mode to: FlightModeStates.DISCONNECTED
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.drivers.cfusb:Looking for devices....
Does this have something to do with the firmware? I am not very familiar with Linux so I cannot properly understand what the terminal is telling me. Thanks.



arnaud
Bitcraze
Posts: 2275
Joined: Tue Feb 06, 2007 12:36 pm

Re: Radio Not Connecting

Post by arnaud » Tue Jan 14, 2020 9:17 am

Hi! It seems that there is two problems: the connection instability and the dongle not recognized anymore.

The first thing to check is that you are running the right firmware. You sais that the dongle briefly flashes RED when connected. Are you sure that it is only red or is it both red and green? If it is only red, you do not have the right firmware (you have a Crazyradio firmware flashed in a Crazyradio PA), which will cause radio range problem.

As for the connection to the VM, do you see the Crazyradio in the USB menu on the bottom and is is passed in the VM? I attach what it would look like on my machine:
vbox-usb-crpa.png

zachterrell57
Beginner
Posts: 9
Joined: Mon Oct 14, 2019 5:02 am

Re: Radio Not Connecting

Post by zachterrell57 » Wed Jan 15, 2020 12:20 am

Arnaud,

Thanks for the reply. I was mistaken, it does flash green and red when plugged in. However, the crazyradio is recognized in the VM. Whenever I hit scan in the client, it does not recognize that the radio is plugged in, and displays the message that I provided in the original post. Do you think that this is still a firmware issue?

Thanks

arnaud
Bitcraze
Posts: 2275
Joined: Tue Feb 06, 2007 12:36 pm

Re: Radio Not Connecting

Post by arnaud » Mon Jan 20, 2020 1:00 pm

If both red and green LED lit up upon connection and you see the Crazyradio in the list of VirtualBox device and manage to click it to enable it in virtualbox, then it is very likely that the radio firmware is going well.

What you are seeing in the console indicates that the client does not see the radio though, which is odd. When the radio is detected by the client it should show:

Code: Select all

INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.crtp.radiodriver:v0.53 dongle with serial N/A found
Can you type "lsusb -d 1915:7777" in the console in the VM and look at the output. If the radio is detected you should see one device:

Code: Select all

Bus 001 Device 107: ID 1915:7777 Nordic Semiconductor ASA USB Billboard
If you see the device, there might be access right problems with it. You can try to run the client as root with "sudo cfclient".

zachterrell57
Beginner
Posts: 9
Joined: Mon Oct 14, 2019 5:02 am

Re: Radio Not Connecting

Post by zachterrell57 » Tue Jan 21, 2020 12:59 am

I decided to restart the VM as opposed to saving the state when I close the app and it now detects the USB. However, when i tried to launch the client as the root user it gave me a "command not found" message. Even though it connects to the drone, it is back to connecting for around 5 seconds before the flight data freezes and the console gives me this message:

Code: Select all

INFO:cfclient.gui: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 /home/bitcraze/projects/crazyflie-clients-python/src/cfclient/configs/config.json
INFO:cfclient.utils.config:Config file read from [/home/bitcraze/.config/cfclient/config.json]
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
INFO:cfclient.utils.zmq_param:Biding ZMQ for parameters at tcp://*:1213
INFO:cfclient.utils.zmq_led_driver:Biding ZMQ for LED driverat tcp://*:1214
INFO:cfclient.utils.input:Using device blacklist [(VirtualBox|VMware)]
INFO:cfclient.ui.main:Auto reconnect enabled: True
INFO:cflib.crtp.radiodriver:v0.53 dongle with serial N/A found
INFO:cfclient.ui.tabs.QualisysTab:Switching Flight Mode to: FlightModeStates.DISCONNECTED
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.crazyflie:Callback->Connection initialized[radio://0/75/2M]
INFO:cflib.crazyflie:We are connected[radio://0/75/2M], request connection setup
INFO:cflib.crazyflie:Callback->Connected to [radio://0/75/2M]
INFO:cflib.crazyflie.platformservice:Procotol version: 4
INFO:cflib.crazyflie.toc:TOC for port [5] found in cache
INFO:cflib.crazyflie:Log TOC finished updating
INFO:cflib.crazyflie.mem:9 memories found
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 [radio://0/75/2M]
INFO:cfclient.utils.logconfigreader:Parsing [stabilizer.json]
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
INFO:cfclient.ui.tabs.LEDTab:Memory: id=1, type=LED driver, size=24
INFO:cfclient.ui.main:LED write done callback
INFO:cfclient.ui.tabs.FlightTab:[imu_sensors.BMP388]: 0
INFO:cfclient.ui.tabs.locopositioning_tab:Crazyflie connected to radio://0/75/2M
INFO:cfclient.ui.tabs.locopositioning_tab:Requesting loco deck parameter
INFO:cflib.crazyflie.log:Have successfully started logging for id=1
INFO:cflib.crazyflie.log:Have successfully started logging for id=3
INFO:cflib.crazyflie.log:Have successfully started logging for id=4
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
QObject::connect: Cannot queue arguments of type 'QList<QPersistentModelIndex>'
(Make sure 'QList<QPersistentModelIndex>' is registered using qRegisterMetaType().)
INFO:cfclient.ui.tabs.FlightTab:[imu_sensors.HMC5883L]: 1
INFO:cflib.crazyflie.log:Have successfully started logging for id=5
INFO:cfclient.ui.tabs.FlightTab:[imu_sensors.MS5611]: 1
INFO:cfclient.ui.tabs.locopositioning_tab:No Loco deck installed
QObject::connect: Cannot queue arguments of type 'QVector<int>'
(Make sure 'QVector<int>' is registered using qRegisterMetaType().)
QObject::connect: Cannot queue arguments of type 'QVector<int>'
(Make sure 'QVector<int>' is registered using qRegisterMetaType().)
INFO:cfclient.ui.tabs.FlightTab:Changed effect to 0
INFO:cflib.crtp.radiodriver:Dongle reported ACK status == None
INFO:cflib.crtp.radiodriver:Dongle reported ACK status == None

kimberly
Bitcraze
Posts: 330
Joined: Fri Jul 06, 2018 11:13 am

Re: Radio Not Connecting

Post by kimberly » Thu Jan 23, 2020 10:08 am

Hi!

Since your VM now detects the USB, probably just starting the cfclient without sudo should be working now. Have you tried this before you did sudo cfclient?

Post Reply