nRF24L01+: can "long" wires cause this problem?

I have multiple working nRF24L01+ attached to ATMega328p based uC. All modules work fine and reliable.
Today, I changed the wires between one Nano clone and its nRF24L01+ module. No change to software. The “old” wires were approx. 10 cm long. The new wires are 50 cm and checked with DMM. The module is detected but the settings are wrong. Here the output of simple pingpair example with long wires:

Simple pingpair example
Send a 'T' via Serial to transmit a single 'ping' 
STATUS		 = 0x06 RX_DR=0 TX_DS=0 MAX_RT=0 RX_P_NO=3 TX_FULL=0
RX_ADDR_P0-1	 = 0x3020202030 0x3020202030
RX_ADDR_P2-5	 = 0xc1 0xc0 0xc0 0xc2
TX_ADDR		 = 0x3020202030
RX_PW_P0-6	 = 0x00 0x00 0x00 0x00 0x00 0x00
EN_AA		 = 0x1f
EN_RXADDR	 = 0x00
RF_CH		 = 0x04
RF_SETUP	 = 0x00
CONFIG		 = 0x00
DYNPD/FEATURE	 = 0x1f 0x00
Data Rate	 = 1MBPS

Here what simple pingpair example looks with short wires:

Simple pingpair example
Send a 'T' via Serial to transmit a single 'ping' 
STATUS		 = 0x0e RX_DR=0 TX_DS=0 MAX_RT=0 RX_P_NO=7 TX_FULL=0
RX_ADDR_P0-1	 = 0x6f69646172 0x6f69646172
RX_ADDR_P2-5	 = 0xc3 0xc4 0xc5 0xc6
TX_ADDR		 = 0x6f69646172
RX_PW_P0-6	 = 0x20 0x20 0x00 0x00 0x00 0x00
EN_AA		 = 0x3f
EN_RXADDR	 = 0x02
RF_CH		 = 0x4c
RF_SETUP	 = 0x27
CONFIG		 = 0x0f
DYNPD/FEATURE	 = 0x3f 0x04
Data Rate	 = 250KBPS

The latter is working, the former is not working.

When no nRF is attached, the output looks like that:

Simple pingpair example
Send a 'T' via Serial to transmit a single 'ping' 
STATUS		 = 0x00 RX_DR=0 TX_DS=0 MAX_RT=0 RX_P_NO=0 TX_FULL=0
RX_ADDR_P0-1	 = 0x0000000000 0x0000000000
RX_ADDR_P2-5	 = 0x00 0x00 0x00 0x00
TX_ADDR		 = 0x0000000000
RX_PW_P0-6	 = 0x00 0x00 0x00 0x00 0x00 0x00
EN_AA		 = 0x00
EN_RXADDR	 = 0x00
RF_CH		 = 0x00
RF_SETUP	 = 0x00
CONFIG		 = 0x00
DYNPD/FEATURE	 = 0x00 0x00
Data Rate	 = 1MBPS

First I thought “long wires, voltage drop, bad”. To fix that I used a base module (like shown here). Well, this did not help at all. Problem the same. I thought the length of wires 10 vs 50 cm should not matter when using the base module. Obviously I’m wrong.
But what happens here?
The base module provides 3.35V, the USB connection provides 4.70V. With the simple pingpair example started, I measured the following voltages on the pins with my DMM:

CE<>GND = 4.70V
CSN<>CSN = 2.94V
MOSI<>GND = 4.61V
SCK<>GND = 0.10V
MISO<>GND = 0.38V

Theses values are nearly the same when I use short wires, read varying by 0.05V.

I’m curious why the nRF is still detected but not working.
Maybe someone has come across this problem or simply know the reason.

Thanks & best

terraduino:
I'm curious why the nRF is still detected but not working

SPI is a (relativly) high speed interface.

That it does not work correctly with connection wires that are half a metre long is no surprise at all.

Tests with a multimeter are fairly pointless, you need an oscilloscope to see what is happening to the pulse edges.

You could try slowing the SPI right down from the defaults, but its not really an interface that is designed for remote connections.

Just get shorter wires. Why would tbe nRF24 need to be more than (say) 5 cm from its Arduino?

...R
Simple nRF24L01+ Tutorial

Dear @srnet, thanks for the feedback.
I'd expected to see random junk or a fully non-functional nRF24L01. Hence, I was surprised that the wrong output is always the same and not changing. Pretty interesting that the SPI seems to fail always in the same way.
I tested your suggestion to reduce SPI clock. Divided by 4 to 16, did not work. Note that the output was the same for all clock speed settings. I used_SPI.beginTransaction(SPISettings(RF24_SPI_SPEED, MSBFIRST, SPI_MODE0)); of the RF24 lib.

Dear @Robin2, the idea is to put the nRF24 closer to the ceiling to increase range and keep the Nano clone close to the ground and power socket. Moreover, the WAF is higher with just the nRF up and visible :wink:

Thanks & best

terraduino:
I'd expected to see random junk or a fully non-functional nRF24L01. Hence, I was surprised that the wrong output is always the same and not changing. Pretty interesting that the SPI seems to fail always in the same way

I would not of even bothered to try to get SPI working on half metre long random wires, that is just daft.

terraduino:
Dear @Robin2, the idea is to put the nRF24 closer to the ceiling to increase range and keep the Nano clone close to the ground and power socket.

That has got the concept of cable capabilities back to front. Long power wires are no problem. Long signal wires are not desirable.

What range do you want? I suspect it will make little difference whether the transceiver is on the ceiling or on a table. Just make sure it is clear of metal surfaces.

...R

I'm sure both of you are right. I already switched back to short wires.
Basically, I was curious why the interference on the signal wires seems to be absolutely constant.

In regards to range, one of my nRF24 has to overcome 15m and three concrete walls and floors, respectively, with mains cable and metal here and there. It has some dropouts from time to time so I thought I'll change the position to avoid reflections of surfaces.

Robin2:
Long power wires are no problem.

Isn't this a little misleading? If you had mains in mind, ok. But IMHO it is not true for low voltages such as 3.3 and 5V.

Thanks & best

terraduino:
Isn't this a little misleading? If you had mains in mind, ok. But IMHO it is not true for low voltages such as 3.3 and 5V.

Possibly. For lower voltages you have to use heavier cables to reduce the resistance in the wire to an acceptable level. But an Arduino does not need much current so the voltage drop will be correspondingly low.

However the problem with high frequency signals is that the energy is dissipated (perhaps through radiation) from long cables - a different sort of problem.

...R

@Robin2
Again, thank you for clarification :slight_smile:

Best