Crazy Radio for senior project

Post here to get support
Post Reply
pmackin44
Beginner
Posts: 4
Joined: Sun Dec 29, 2013 8:08 pm

Crazy Radio for senior project

Post by pmackin44 » Sun Dec 29, 2013 8:20 pm

Hi,
I know this forum is for the crazy flie, but I was hoping for some help if I can get it. I am using this radio dongle for my senior project to create a wireless link between my computer and an RC car so that I can control it remotely. I have a program I have written in C# that contains the control in windows and I have loaded my dongle with your crazy radio firmware. I need to know what I need to do to send commands from my computer to to the dongle so it will send it out to nrfl01 on a hcs12 Dragon board. What pipe is being used in the firmware as well as do I need to send out configuration to the dongle for 2M as well as channel address? Currently I have a button setup to to send out a character but I can't seem to capture it on the other end. Any help would be much appreciated as I am fairly new at programming for USB devices.

Thanks :D



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

Re: Crazy Radio for senior project

Post by arnaud » Thu Jan 02, 2014 11:16 am

Hi,
You are in the Crazyradio section of the forum so your question is welcome, it is great to see Crazyradio used in other projects :).

The Crazyradio usb protocol is documented there: http://wiki.bitcraze.se/projects:crazyradio:protocol, USB EP1 is used to send/receive packets. By default the Crazyradio dongle starts in PTX mode at 2MBps with address 0xE7E7E7E7E7.

First, if the radio is sending packets you should see a LED blink, either red or green, that would mean that your C# usb part is OK. Then if it is blinking red the receiver is not ack-ing the packet. The receiver should be configured the same way as in the Crazyflie copter: https://bitbucket.org/bitcraze/crazyfli ... ult#cl-185. If the Crazyradio dongle blinks green then you are sending packets and an ack is received.

Good luck!

pmackin44
Beginner
Posts: 4
Joined: Sun Dec 29, 2013 8:08 pm

Re: Crazy Radio for senior project

Post by pmackin44 » Fri Jan 03, 2014 2:13 am

Thank you for the information. Currently my dongle when plugged in has a solid red light on and does not blink when I hit my button. Is a solid red led normal or is it saying something is wrong.

Thanks

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

Re: Crazy Radio for senior project

Post by arnaud » Fri Jan 03, 2014 9:11 am

Something seems to be wrong. When plugged both red and green LED are lit. When the PC finished the device enumeration both LED should go off. The only state where only the red LED should be lit is when the continuous carrier mode is enable, this is a testmode in which the ratio will generate a continuous sinus at fix frequency.

Do you have the usb driver installed? Can you test with the Crazyflie client. Even if you don't have a crazyflie the client will tell you if a dongle is detected in the about box and scanning for a copter should lit the red led for a little while and then switch it off. If your receiving board is configured like the Crazyflie the client will also detect it.

pmackin44
Beginner
Posts: 4
Joined: Sun Dec 29, 2013 8:08 pm

Re: Crazy Radio for senior project

Post by pmackin44 » Fri Jan 03, 2014 11:45 pm

Looks like I can see it as the Crazyradio dongle in the client software but I don't see my receiver doesn't show up which I expected since it appears it is stuck in continuous carrier mode. I have 2 of these dongles and both have been flashed with the version 0.52 firmware and both are doing the same thing. Is there an easy way to get it out of this mode?

Thanks

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

Re: Crazy Radio for senior project

Post by arnaud » Sat Jan 04, 2014 1:46 pm

The continious carrier mode has to be activated and is not activated by any software we have released so far (it is a test mode and I usually use it from python prompt) so if you dont activate it by mistake in your program it should not be ON. Does both red and green leds light up when the dongle is connected to the PC? This look like a hardware problem with the RED led, maybe its polarity is reversed. Are you using the Crazyradio dongle hardware or some other dongle?

Anyway, if the dongle is detected by our client it is a good thing. If your receiver is not detected it is maybe not using the same settings as in the Crazyflie. Have you double checked that the receiver is well configured?
The receiver should be configured as follow:
- PRX mode
- One active pipe with receiver address 0xE7E7E7E7E7
- 5 byte address
- Dynamic payload length enable
- Payload with ack enable

pmackin44
Beginner
Posts: 4
Joined: Sun Dec 29, 2013 8:08 pm

Re: Crazy Radio for senior project

Post by pmackin44 » Sun Jan 12, 2014 4:40 am

Thanks for the help. I got it to work finally. I had a different manufacture for the dongle and ordered one of the quadcopter kits since just the dongle was out of stock in the states. The lights on it worked as you described and I had some issues in my controller code I had to get sorted out. Once I got it the lights flashed green. I tried the other radio dongle and it worked too with the copter as well as my project. Thanks for the help. Your project is awesome although I'm still figuring out how to fly it.

Post Reply