Page 1 of 1

Crazyradio connection problem

Posted: Wed Jul 12, 2017 3:12 am
by chuhao
Hi

I meet problem to connect crazyradio with my PC.

I installed crazyflie client on my Ubuntu 16.04. I start the client software, and cannot find crazyradio connected.
client_connection.png
Then I tried to check devices,

Code: Select all

lsusb
It shows,
Bus 002 Device 002: ID 8087:8000 Intel Corp.
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:8008 Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 002: ID 062a:4101 Creative Labs Wireless Keyboard/Mouse
Bus 003 Device 016: ID 1915:0101 Nordic Semiconductor ASA
Bus 003 Device 004: ID 214b:7000
Bus 003 Device 003: ID 1a2c:2124 China Resource Semico Co., Ltd
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
I thought device name should be "crazyradio PA USB", isn't it?

So, I tried to flash a new firmware to crazyradio, After,

Code: Select all

python usbtools/launchBootloader.py
It says
BootLoader started
. Then, check with

Code: Select all

lsusb
, the listed devices does not change at all.
If flash a new firmware by

Code: Select all

python usbtools/nrfbootload.py flash cradio.bin
, it shows,
('Found nRF24LU1 bootloader version', '18.0')
Flashing:
Flashing 7471 bytes...
Flashing done!
Verifying:
Reading firmware/bin/cradio.bin...
Reading 7471 bytes from the flash...
Verification succeded!
After the whole firmware flash process, I enter

Code: Select all

dmesg
, it shows,
[ 4963.152872] usb 3-12.4: SerialNumber: 0B42EF16C2
[ 4974.607767] usb 3-12.4: USB disconnect, device number 12
[ 4977.192918] usb 3-12.4: new full-speed USB device number 13 using xhci_hcd
[ 4977.283692] usb 3-12.4: New USB device found, idVendor=1915, idProduct=7777
[ 4977.283695] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=29
[ 4977.283698] usb 3-12.4: Product: Crazyradio PA USB Dongle
[ 4977.283700] usb 3-12.4: Manufacturer: Bitcraze
[ 4977.283701] usb 3-12.4: SerialNumber: 0B42EF16C2
[ 5003.790120] usb 3-12.4: USB disconnect, device number 13
[ 5006.950338] usb 3-12.4: new full-speed USB device number 14 using xhci_hcd
[ 5007.041121] usb 3-12.4: New USB device found, idVendor=1915, idProduct=7777
[ 5007.041123] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=29
[ 5007.041124] usb 3-12.4: Product: Crazyradio PA USB Dongle
[ 5007.041125] usb 3-12.4: Manufacturer: Bitcraze
[ 5007.041125] usb 3-12.4: SerialNumber: 0B42EF16C2
[ 6037.714441] usb 3-12.4: USB disconnect, device number 14
[ 6038.634627] usb 3-12.4: new full-speed USB device number 15 using xhci_hcd
[ 6038.725460] usb 3-12.4: New USB device found, idVendor=1915, idProduct=7777
[ 6038.725461] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=29
[ 6038.725472] usb 3-12.4: Product: Crazyradio PA USB Dongle
[ 6038.725473] usb 3-12.4: Manufacturer: Bitcraze
[ 6038.725474] usb 3-12.4: SerialNumber: 0B42EF16C2
[ 6059.186225] usb 3-12.4: reset full-speed USB device number 15 using xhci_hcd
[ 6059.438471] usb 3-12.4: USB disconnect, device number 15
[ 6059.638051] usb 3-12.4: new full-speed USB device number 16 using xhci_hcd
[ 6059.727958] usb 3-12.4: New USB device found, idVendor=1915, idProduct=0101
[ 6059.727960] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 6059.727961] usb 3-12.4: Product: nRF24LU1P-F32 BOOT LDR
[ 6059.727962] usb 3-12.4: Manufacturer: Nordic Semiconductor
[ 7113.620363] usb 3-12.4: USB disconnect, device number 16
[ 7115.154070] usb 3-12.4: new full-speed USB device number 17 using xhci_hcd
[ 7115.244596] usb 3-12.4: New USB device found, idVendor=1915, idProduct=7777
[ 7115.244600] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=29
[ 7115.244601] usb 3-12.4: Product: Crazyradio PA USB Dongle
[ 7115.244602] usb 3-12.4: Manufacturer: Bitcraze
[ 7115.244603] usb 3-12.4: SerialNumber: 0B42EF16C2
[ 7127.169554] usb 3-12.4: reset full-speed USB device number 17 using xhci_hcd
[ 7127.421803] usb 3-12.4: USB disconnect, device number 17
[ 7127.621383] usb 3-12.4: new full-speed USB device number 18 using xhci_hcd
[ 7127.711293] usb 3-12.4: New USB device found, idVendor=1915, idProduct=0101
[ 7127.711299] usb 3-12.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 7127.711300] usb 3-12.4: Product: nRF24LU1P-F32 BOOT LDR
[ 7127.711301] usb 3-12.4: Manufacturer: Nordic Semiconductor

Re: Crazyradio connection problem

Posted: Wed Jul 12, 2017 11:17 am
by arnaud
When you start the client and when you click "Scann" do you see the RED LED on the Crazyradio lighting up?

If so, the "select an interface" dropdown menu will show all powered-on Crazyflie detected (both radio and usb-connected Crazyflie). You should then be able to connect it.

The Crazyradio is VID:PID 1915:7777, the Crazyradio USB bootloader is 1915:0101. From your logs, there seems to be no problem with the Crazyradio USB connection.

If scanning from the client does not work, check that you have the user right to use the Crazyradio: https://github.com/bitcraze/crazyflie-l ... ermissions

Re: Crazyradio connection problem

Posted: Wed Jul 12, 2017 3:18 pm
by chuhao
Hi Arnaud

When I power on the crazyflie, LED on M1 keep blink in red.
After start client, it still cannot found devices. The log showed on terminal is showed as below,
xiaohao@go:~/bitcraze/crazyswarm/crazyflie-clients-python$ python3 bin/cfclient
INFO:cfclient.gui:Disabling STL printouts
INFO:cfclient.utils.input.inputreaders:Found readers: ['pysdl2', 'linuxjsdev']
INFO:cfclient.utils.input.inputreaders:Could not initialize [pysdl2]: No SDL2 support on Linux
INFO:cfclient.utils.input.inputreaders:Successfully initialized [linuxjsdev]
INFO:cfclient.utils.input.inputinterfaces:Found interfaces: ['leapmotion', 'zmqpull', 'wiimote']
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [leapmotion]: Leap Motion library probably not installed (No module named 'leapsdk')
INFO:cfclient.utils.config:Dist config read from /home/xiaohao/bitcraze/crazyswarm/crazyflie-clients-python/src/cfclient/configs/config.json
INFO:cfclient.utils.config:Config file read from [/home/xiaohao/.config/cfclient/config.json]
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [zmqpull]: ZMQ input disabled in config file
INFO:cfclient.utils.input.inputinterfaces:Could not initialize [wiimote]: Missing cwiid (wiimote) driver No module named 'cwiid'
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:v99.55 dongle with serial N/A found
WARNING:cfclient.ui.main:Exception while opening tabs ['Loco Positioning']
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.crtp.radiodriver:v99.55 dongle with serial N/A found
INFO:cflib.drivers.cfusb:Looking for devices....
INFO:cflib.crtp.radiodriver:v99.55 dongle with serial N/A found
INFO:cflib.drivers.cfusb:Looking for devices....

Re: Crazyradio connection problem

Posted: Thu Jul 13, 2017 5:13 am
by chuhao
It looks like I didn't set crazyflie address correctly.
I checked drone address over usb cable and set the adress to client software. It now can connect to crazyflie !
Just thinking it might be better to have a function to scan drone address automatic.

Thanks

Re: Crazyradio connection problem

Posted: Thu Jul 13, 2017 7:57 am
by arnaud
Scanning drone address would be hard and and it is actually a feature: right now the link has no protection but switching it a different address makes it harder to connect accidentally to the drone.

One thing I have been wanting to do for a while is to have the Crazyflie broadcasting its identity when not connected, this would allow for a passive scanning (this is how wifi works for instance). I guess it would solve this problem. But until that is done, the USB connection is the way to recover a Crazyflie from a random address.

Re: Crazyradio connection problem

Posted: Mon Jul 17, 2017 12:35 pm
by chuhao
usb connection is also a possible method.

Another problem I met is radio loss. When I put crazyflie within 1m of crazyradio, it can be connected. However, the connection is unstable. Especially when I move the drone further than 2m to crazyradio. It always lost the connection.

Is there any way to improve it?

Thanks

Re: Crazyradio connection problem

Posted: Mon Jul 17, 2017 12:42 pm
by arnaud
What radio parameters are you using? 2m range with a Crazyradio PA is not normal and surprising, we are observing much more range.

Re: Crazyradio connection problem

Posted: Tue Jul 18, 2017 3:31 pm
by chuhao
I use radio with parameters: radio://0/100/2M/E7E7E7E701

Re: Crazyradio connection problem

Posted: Wed Jul 19, 2017 9:29 am
by arnaud
OK, do you see any difference if you try a lower channel like 45?