Thread Tools
Jan 13, 2008, 11:56 AM
Registered User

Simple diy 2.4GHz

I just bought a couple of Jennic 2.4GHz modules and followed an app note off their site to build this 2 channel transmitter and receiver. It required no other components apart from a voltage regulator and worked first time! To program the modules I used a Pololu usb to serial convertor and the free IDE and programming software from the Jennic site.

This thread has become rather large! It remains the place for discussion,help and news for this project, however the latest code can be found at the open source google project here
Last edited by Alan Hopper; Aug 09, 2010 at 09:38 AM.
Sign up now
to remove ads between posts
Jan 13, 2008, 02:09 PM
Registered User
That looks very neat Alan. I wish my projects worked first time!

How many channels can the modules transmit? Looking at the datasheet it appears to be 4 analog. Are the modules 'bound' to each other or could another receiver react to your transmitter?

Keep up the good work
Jan 13, 2008, 02:37 PM
Registered User
Yep the module only has 4 analog inputs, if you wanted more you could connect an i2c or spi adc or another processor. Jennic's demo source code uses the two application timers for pwm output to the servos, I shall do some tests to see it it is possible to get interrupt driven pwm to work well enough on the gpio outputs to allow more servo outputs. The provided Api gives you full control over binding.
Jan 17, 2008, 08:17 AM
Registered User
Alan, that looks very promising. May I ask where you purchased and at what cost?

Jan 17, 2008, 09:19 AM
Flying Fatboy
Gordito Volador's Avatar
It looks like Digikey has them in the USA $20 to $28 per module.

Regards, Bill
Jan 17, 2008, 12:07 PM
Registered User
I bought them in the UK from farnell

If you search their site for zigbee they also have the maxstream and meshnetics modules which are also tempting. I have not done any proper range testing yet but my initial feelings are that the low power modules with chip antenna I bought are fine for toy cars and boats for my 2yr old son but probably not up to serious use. I have been tweaking the software and will post something soon.

Last edited by Alan Hopper; Jan 17, 2008 at 12:18 PM.
Jan 18, 2008, 09:21 AM
Registered User
Hi Alan,

Very interesting looking modules, and the onboard processor seems nice! I didn't see it in the specs, but do these modules frequency hop or are they like the Xbee's?? (I forget if the Zigbee protocol determines this or not).
I have been flying with my 9303 modified with Xbee Pro's and have been able to make the channel hop under interference conditions; from your experience, can you change the channel on the fly (and how many channels are there?)
Lots of questions! Keep up the good work!

Jan 18, 2008, 10:30 AM
Registered User
I am no expert in all this stuff and am slowly trying to get a handle on it all. The modules comply to IEEE 802.15.4 like the xbee modules. There are 16 channels available and it is up to the developer to do stuff like hop channels if a chosen channel becomes bad. The latest Jennic audio reference design hops but unfortunately most of the code is hidden in a library file which I can't find the source for. I am interested to know what other sytems do about the PAN ID, all the references say it should be unique. The audio reference design does scan for conflicting ids at startup however it does not appear to change it if a conflict occurs later. I'm am trying to make my code as cooperative and friendly to other sytems as possible, so all thoughts gratefully received. What do the XPS sytems do about PAN IDs?
Jan 18, 2008, 11:19 AM
Registered User
how do you coordinate hopping on the xbees.
Alan ( not hopping yet ) Hopper
Jan 18, 2008, 11:47 AM
Registered User
The weather is far too wet too make range testing tempting, so I just did some latency testing instead. I timed , on the transmitter, the interval between sending a packet with a 4 byte payload ( 2*16bit channel data) and receiving an ack. It varied between 1 and 4 ms(with an integer 1ms timer so possiblycloser to 2 - 5ms). This was with a good link and no retries. This ties up well with sending a few more channels should make little difference as the packet overhead is large.
Last edited by Alan Hopper; Jan 18, 2008 at 11:59 AM.
Jan 18, 2008, 01:17 PM
Registered User
Hi Alan, and thanks for your reply.

On the Xbee's, as best as I see it, you have two options with regards to hopping (that don't require you delving into the Xbee software itself).

One: you can have the TX Xbee count the number of times it was prevented from transmitting due to interference on its channel.

Two: you can have the TX Xbee count the number of times it has not received an ACK from the receiver.

If either of these cases occur more than a certain number of times, I have the TX Xbee reset, so that it starts a new scan and picks a (new) channel with low noise on it. On the receiver side, if (when) it loses contact with the TX it automatically starts to look for it, channel by channel, until it finds it again.

A frequency hop and re-acquisition typically takes the system about 1 second.

In terms of PANID's, I simply hard coded my own value; between the PANID and setting my receiver to only listen to the TX's 16bit identifier, I figure the odds are on my side. However, it is entirely possible to have the Xbee scan the spectrum on startup and return all the PANID's present; a new non-conflicting PANID can then be chosen.

Looking forward to more updates,

Jan 19, 2008, 06:59 AM
Registered User
I just did a crude range test. I set the tx to slowly move the servo back and forwards. I placed the tx on a tall (1m ish) plastic bin and went for a walk with the rx. For the first 60m it was pretty solid, there was the occasional dead spot of an inch or so. After this the dead spots got bigger but it still worked much of the time at 200m(as far as I went). This was on rough common land ringed with houses, most of which have wifi routers. I shall strap it to a plane(controlled by 35MHz) next and get the tx to log the error rate.
Jan 19, 2008, 11:56 AM
Registered User
I just discovered a bug in the Jennic sample code that meant loosing a single packet could stop the servo moving for up to 255 further packets, having fixed it and gone for another walk the results were very much better!
Jan 20, 2008, 12:01 PM
Registered User
I just had a play with the hopping stuff, you appear to be able to change channels at will. I set the tx to change channels just before sending each data packet, which is every 20ms and made the rx sync to this. The rx knows the sequence the tx uses. It all worked fairly painlessly. This approach appeals to me, maybe with the addition of a slowly changing blacklist of channels that are used less or not at all. I suspect this will cope more quickly with a change in conditions than changing only when a problem is found. Anyone got any thoughts or experiences with this stuff?
Jan 27, 2008, 09:35 AM
Registered User
Just got a chance to play with the hopping software again. I had a problem with restarting communications if the receiver was powered down and up once the transmitter had started hopping. This is now fixed and comms are re established in about 0.3s after cycling the rx power. The tx now checks for a unique panid on startup. I did the same range test as before, but with the hopping software. At the limit of my test (200m) it was totally solid even outside a house where the old software was always intermittent (I can see the wifi router through the window!). I had always assumed that I would need the more powerful modules and external antenna for my planes but I think I now have enough confidence in the basic modules to put one in my Alula dlg and see what happens. btw the low power modules with chip antenna weigh 2.25g.

Thread Tools

Similar Threads
Category Thread Thread Starter Forum Replies Last Post
Idea Spektrum DX6 DIY Transmitter antenna replacement using 2.4GHz Wireless network parts? jaskew Radios 18 Jun 17, 2009 12:28 PM
Discussion Sort of DIY 2.4Ghz Spectrum Analyzer village_idiot DIY Electronics 11 Feb 23, 2008 11:55 AM
Discussion DIY +12dBi, increase the range of your rubber ducky 2.4Ghz antenna dalbert02 Aerial Photography 1 Jan 01, 2006 11:58 AM
Antenna for 2.4GHz video transmitter Wile E Power Systems 7 Sep 25, 2001 04:42 PM
2.4Ghz xmit system for a small fortune jas_Qfix Electric Plane Talk 28 Jul 02, 2001 08:37 AM