NRF24L01 Multiple Pipes Transmiters with 1 Receiver

Hi All
I am new to this forum, I just join to this site today. I do need some help about writing the code for NRF24L01 with multiple pipes. Basicly 3 transmitters and 1 receiver. I am planing to do the project by using NRF24L01 to power on the garage (Not Open the garage). I have 3 cars. me, my wife and 1 very old car (most the time the old car stay home). If 2 cars out the house then power off the garage. if my wife's car or my car home then power on the garage. If I use the NRF24L01 then how can detect the what pipe not receive signal to turn off the garage vise versa. I am not concern the string or data. I concern the transmit and receive connectivity. I did try to use bluetooth HC-05 but the range is short did not work well (from garage to the car park about 30ft). all you help will be appreciate.

Thank A lot

It sounds like you want each transmitter to be identified with a particular car so that the receiver can know which cars are in the garage. Is that correct ?

What about using all the transmitters with the same pipe and just send a message that identifies which car it comes from - for example 'M' 'W' or 'O' for "man", "woman" or "old" ?

...R

The availabe() function, of the RF24 library, can take a parameter so that the transmitter that is sending to the receiver is identified.

byte inPipe;
if ( radio.available(&inPipe))

The variable inPipe holds the number of the pipe that is sending to the receiver.

If you activate autoacknowledge and send from the base station
you can check for failing transmissions.

If you can't reach one of the cars they are not in the garage
if the communication works.

Why not put an RFID tag on each car? Then you only need one Arduino, and no circuits in the cars.

First, Thanks all your suggestions.

Thanks for robin2 : I did try use the short message to identify which car had transmit, but when the car leave the house, there is no transmit, so the receiver keep waiting for the message.

Thanks for groundfungus: very good suggestion, I will try " if(radio.available(&inpipe))" to determine the pipe available or not.

Thanks for Whandall : very good suggestions, How do I do to get auto acknowledge when there is no transmit (which means the car leave the house).

Thanks for aarg: by using RFID, currently I do use the RFID for my kid walk back home from school to open the door. But the RFID need very close distance in-order to trigger. How do I put RFID-receiver in the garage then the RFID-tage in side the car can be trigger from a distance.

Thanks all

If you enable autoacknowledge, a send can fail,
as the transmitter gets feedback from the addressed node if successfull.
It will fail (after configured retries) when the addressed node did not send an acknowledgement.
Switching between send and receive modes is handled automatically.

Note that you can get back up to 32 bytes via acknowledge with payload (very handy).

So you could send polling packets round robin to all of your cars,
keeping track of (the last) successful send(s).
If too many sends fail in a row, you can assume the car left.

What library are you using for the NRF24L01s?
There are a lot of different ones.

I use a modified version of ManiacBugs library,
wich in its pure form hinders you in using the chip fully
via flushFifos and powerdown mode.

ManiacBug seemed to be afraid of interrupts,
so the whole library is polled/blocking.

cch333333:
Thanks for robin2 : I did try use the short message to identify which car had transmit, but when the car leave the house, there is no transmit, so the receiver keep waiting for the message.

Then you don't have the correct program. Your code should be designed so it does not wait for anything.

...R