Two Transmitter to One Receiver using nrf24l01

Hi, Im completely new to arduino and wireless data transmiting, I need to complete a project that uses nrf24l01 as the tranceiver and arduino uno as the controller.

Tx1 is placed at a different area than Tx2, so what I need to do now is, when the receiver receive data i need to make my arduino know the transmitting data is either from Tx1 and Tx2, so the condition will be.

if Tx1 = led1 turned on
and if Tx2 = led2 turned on

this look simple but im having a hard time to do it, please help me sifus. :confused:

Have a look at this Simple nRF24L01+ Tutorial.

The examples are as simple as I could make them and they have worked for other Forum members. If you get stuck it will be easier to help with code that I am familiar with. Start by getting the first example to work

It includes an example for a master and 2 slaves that can easily be extended to a larger number of slaves.

Wireless problems can be very difficult to debug so get the wireless part working on its own before you start adding any other features.

...R

thank you robin, already look upon your code, and it is not simple as i thought it would be, do you have like simple for beginners like me to understand. please help me :sob:

this is my code, that only works on one to one transmission only.

TX

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>

RF24 radio (9,10);

const uint64_t TXAddress = 0xB00B1E50C3LL;


void setup()
{
  radio.begin();
  radio.openWritingPipe(TXAddress);
  radio.stopListening();
}

void loop()
{
  const char text[] = "A";
  radio.write(&text, sizeof(text));
  
  delay(1000);
}

RX

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>

RF24 radio (9,10);

int led1 = 2;

const uint64_t RXAddress = 0xB00B1E50C3LL;


void setup()
{
  
  Serial.begin(9600);
  
  radio.begin();
  radio.openReadingPipe (0,RXAddress);
  
  radio.startListening();
}

void loop()
{
  if (radio.available())
  {
    char text[32] = {0};
    radio.read(&text, sizeof(text));
    Serial.println(text);
    Serial.println (sizeof(text));
    digitalWrite(led1, HIGH);
    delay(400);
    digitalWrite(led1, LOW);
    delay(50);      
  }
}

nickilyasha:
thank you robin, already look upon your code, and it is not simple as i thought it would be, do you have like simple for beginners like me to understand. please help me :sob:

I don't know how to make it any simpler than in my Tutorial.

If there is some specific part that you don't understand then if you tell me I will try to explain. Maybe your questions can help me to improve the Tutorial.

Have you tried my examples?

...R

Robin2:
I don't know how to make it any simpler than in my Tutorial.

If there is some specific part that you don't understand then if you tell me I will try to explain. Maybe your questions can help me to improve the Tutorial.

Have you tried my examples?

...R

yes i had tried them, its working, but yours is multi transceiver right, is there a way to make it simpler by changing it to one to one transceiver.

nickilyasha:
yes i had tried them, its working, but yours is multi transceiver right, is there a way to make it simpler by changing it to one to one transceiver.

I don't understand what you mean by "one to one" considering that your Title says "Two transmitter to one receiver"

Also I'm not sure which of my examples you refer to when you say "multi trannsceiver"

If you describe the project you are trying to build it will be much easier to help you.

...R