radio module only works when connected through breadboard

Thread Starter

davidhoff

Joined Sep 19, 2008
66
I am using an nrf24l01+ radio module in my project to let 2 micro-controllers communicate wirelessly. There is a socket on my pcb where the wireless module plugs right in. I also have a socket mounted on a breadboard that I used for testing. The strange thing is, while using the breadboard socket, everything works great. As soon as I remove the breadboard, it stops working. Here are the things I've tried and the results:
module into pcb socket - no signal:(
module into breadboard into wires into pcb socket - works::)
module into ribbon cable into pcb socket - no signal:(
module into ribbon cable into breadboard into wires into pcb socket - works:)
module into breadboard into wires into ribbon cable into pcb socket - works:)

At first I thought the breadboard might just be moving the radio away from some source of noise on the board, so I made the ribbon cable to try out that theory. The ribbon cable didn't help. Then I thought maybe having all the wires parallel vs spaghetti style coming out of the breadboard might be the issue, so I tried connecting the breadboard and the ribbon cable at the same time, and it worked again, so I ruled out a problem with the cable. I also swapped the order of the ribbon cable and breadboard to see if maybe the socket on the pcb was only getting good contact with wires and not pins. Didn't matter. Continuity checks along the way said I was getting good contact all the time. I also tried holding the radio module near the breadboard, but not connected to it to see if it was just helping reflect signal at the antenna or something. No luck. As a last ditch effort, I wrapped the ribbon cable in foil and connected the foil to ground. Nothing. Any ideas what is going on here? I wish I had access to an oscilloscope, to see what's going on in there. I suppose it could be something either blocking the radio from receiving the signals, or a problem stopping the micro-controller from talking to the radio, but I can't think of a reason a breadboard would do either. Could it help dampen electrical noise? Something with extra capacitance? Any ideas / suggestions / things to try are welcome. And yes, I have checked many times that my wires are going to the same place with the connector on the breadboard, ribbon cable, and pcb socket. I'd like to avoid having a breadboard in the final project just for its mysterious magical effects.;)
 

ErnieM

Joined Apr 24, 2011
8,377
I am using an nrf24l01+ radio module in my project to let 2 micro-controllers communicate wirelessly. There is a socket on my pcb where the wireless module plugs right in. I also have a socket mounted on a breadboard that I used for testing. The strange thing is, while using the breadboard socket, everything works great. As soon as I remove the breadboard, it stops working. :)
Resisting the urge to just say "well don't do that"...

I have no idea what you are doing. If you are making "2 micro-controllers communicate wirelessly" are they on the same breadboard, pcb, or what?

What your set up is is completely unclear. Also "stops working" in very vague itself, what "stops?"
 

davebee

Joined Oct 22, 2008
540
Breadboards can have a lot of capacitance between adjacent pins, like around 6 pf, if I remember correctly, in a breadboard of mine.

Maybe try adding a little capacitance between connections in your PCB?

Can you take a picture of your layout and post it?
 

nickelflipper

Joined Jun 2, 2010
280
Any ideas what is going on here? I wish I had access to an oscilloscope, to see what's going on in there. I suppose it could be something either blocking the radio from receiving the signals, or a problem stopping the micro-controller from talking to the radio, but I can't think of a reason a breadboard would do either. Could it help dampen electrical noise? Something with extra capacitance? Any ideas / suggestions / things to try are welcome. And yes, I have checked many times that my wires are going to the same place with the connector on the breadboard, ribbon cable, and pcb socket. I'd like to avoid having a breadboard in the final project just for its mysterious magical effects.;)
I have the nrf24L01+ in sockets which are then wired point to point to the micro on one board, and hookup wire socket to socket on the other. No problems, and seems pretty tolerant. I might suspect a timing issue in the software setup? Playing with the delays for PTX and RX code seems to make a difference, or not enough time elapsed from standby mode? These chips have been frustrating for me.

Is the comms uni or bi directional? My settings
Rich (BB code):
1.  Auto ack on
2.  250 kbs data rate
3.  wait 500 us auto retransmit
4.  0 dbm power
5. IRQ enabled (seems to have internal pullup)
 

Thread Starter

davidhoff

Joined Sep 19, 2008
66
are they on the same breadboard, pcb, or what?

What your set up is is completely unclear. Also "stops working" in very vague itself, what "stops?"
Here's a picture of my setup.

The one with all the buttons is a remote. It sends messages to the main board telling it what to do. The remote works fine. The other board works fine too, as long as the radio module is connected through the breadboard.
Here are more pictures in case anything was unclear about the connections.

doesn't work


works


doesn't work


works


works


I know I'm getting good connections because my meter says so, and it works with the breadboard. As for stops working, I mean that the micro-controller does not receive messages from the radio module. This could be the radio doesn't get a message from the other radio, or it could be the radio receives the message and can't communicate with the micro. I don't have a way to tell since all my debugging is done with a meter and feedback from the micro.

Breadboards can have a lot of capacitance between adjacent pins, like around 6 pf, if I remember correctly, in a breadboard of mine.

Maybe try adding a little capacitance between connections in your PCB?
I think something like this could be what's going on. Where would I need to add the capacitors to? One from each line to ground?

I might suspect a timing issue in the software setup? Playing with the delays for PTX and RX code seems to make a difference, or not enough time elapsed from standby mode? These chips have been frustrating for me.
I don't think it's a code problem, since it works under some conditions with the same code. I'm not using the irq, or standby on the unit that is having issues. I found this resource very helpful in getting the chips to do more than sit on my desk.http://maniacbug.wordpress.com/category/rf-radio/ He wrote some code libraries that I'm using and has some good examples and demos as well.

Is the comms uni or bi directional?
Right now it's one way. When it works, it works one or two way. When it doesn't work, it doesn't work either way.
 
Last edited:

nickelflipper

Joined Jun 2, 2010
280
The pictures help. I know that the microchip 2.4Ghz transceivers specify an exclusion zone free of ground planes underneath the chip, or on chip antenna. I would of thought that the module would be overhung off the edge of the pcb, and could explain why it works with the breadboard and not the pcb. Could you try spacing the module further off the pcb somehow to see if that helps?

I'll take a look at maniacbug's code, although I'm pretty sure I've seen it before, Thanks:).

EDIT: Could be noise generated from the voltage regulator under the module, no caps on input or output???? very suspicious.
 

Thread Starter

davidhoff

Joined Sep 19, 2008
66
The pictures help. I know that the microchip 2.4Ghz transceivers specify an exclusion zone free of ground planes underneath the chip, or on chip antenna. I would of thought that the module would be overhung off the edge of the pcb, and could explain why it works with the breadboard and not the pcb. Could you try spacing the module further off the pcb somehow to see if that helps?

I'll take a look at maniacbug's code, although I'm pretty sure I've seen it before, Thanks:).

EDIT: Could be noise generated from the voltage regulator under the module, no caps on input or output???? very suspicious.
The reason the board design is so bad is because I did it myself, and I don't know exactly what I'm doing most of the time. As for spacing the module further off the pcb, do you mean like with the ribbon cable? And lastly, what do you mean about not having caps on input or output being suspicious? Like I said, most of the time I have little clue what I'm actually doing. What is the proper way to do this and why?
 

nickelflipper

Joined Jun 2, 2010
280
The reason the board design is so bad is because I did it myself, and I don't know exactly what I'm doing most of the time. As for spacing the module further off the pcb, do you mean like with the ribbon cable? And lastly, what do you mean about not having caps on input or output being suspicious? Like I said, most of the time I have little clue what I'm actually doing. What is the proper way to do this and why?
The pcb looks fine :), just the radio module location may not be optimum. I was thinking of stacking another 2x6 female into the existing just to test the theory if possible. Or another way would be to hook up the ribbon cable again, then place the module over the pcb location to see if you lose communication. Then you know its a pcb placement issue. A little proto adapter board to scramble the pins and get the module looking the other way could be the fix.

Look at the regulator data sheet to see what they recommend for caps. They will typically be 1uf, 0.1uf, or some combination.
 

Thread Starter

davidhoff

Joined Sep 19, 2008
66
Look at the regulator data sheet
Well, who would ever think to do that? Haha. Thanks. I really need to start actually reading them instead of just looking up the pin numbers and ignoring the rest. I just figured since I was getting 3.3v out of it, everything was good.
 

Thread Starter

davidhoff

Joined Sep 19, 2008
66
Success! It looks like nickelflipper hit this one right on the head. After adding the capacitors called for on the datasheets...
It's working with any cable and even directly in the socket. I think that the capacitance in the breadboard might have been smoothing things out just barely enough to get it to work. Maybe. But the moral of the story is, READ the datasheet. Thanks everybody!
 
Top