Need help in using the 38khz Ir Receiver Ir Transmitter Sensor Module Kit for Arduino

Hi, I am trying to do a project that will have an IR transmitter transmit some signal using the IRremote library, and then read the incoming value on the receiver using the analogRead

I have done some research and looked up tutorials online on how to set up the transceivers, the receiver is able to pick up signals from my TV remote just fine, but my receiver does not seem to pick up any signals from the transmitter.
Any help would be appreciated.

Below is the sensor module kit I have

and below is the code for my transmitter:

#include <IRremote.h> 
IRsend sender;

void setup() {
  // put your setup code here, to run once:
  Serial.begin(9600);  
}

void loop() {
  // put your main code here, to run repeatedly:
  sender.sendSony(0xFF02FD, 32);
  delay(100);
}

and below is the code for my receiver:


int sensorValue;

void setup() {
  // put your setup code here, to run once:
  Serial.begin(9600);  
}

void loop() {
  // put your main code here, to run repeatedly:
  int sensorValue = analogRead(A1);
  Serial.println(sensorValue);
  delay(1);
}

I once used an IR remote receiver. I build the transmitter my self. Serial data worked fine with 2400 baud, but not higher data rate.
I don't know what IRremote library does, and there is no specs about those Amazon products, so I have no idea how they work, but still I wonder why you use analog read in receiver SW. IR receivers have digital outputs, or is your receiver different?.

I am using analog read because I want to convert the read-in value from analog to digital; so I want some sort of numerical data. May I ask how you built the transmitter?

3-pin 38kHz receivers output a digital signal (pulse train),
so it makes no sense to use analogRead().

Try the receive examples of the IRremote library (should be in the examples of the IDE).
Leo..

It was years ago, but directly out of an IR receiver application note.
Try this. This is continous 38kHz (when you tune the frequency so), so you need an one IC more for modulation.


From this

Googling ir remote control arduino could help too.

Nothing else needed if you use an Arduino.
The transmitting Arduino can generate the required 38kHz carrier, and modulate that with the data/code you require. And an other Arduino can demodulate the data/code that the 3-pin receiver already has stripped of the 38kHz carrier As said, the library that OP is already using comes most likely with transmit and receive examples.
Leo..

Yes, I was able to find some IRremote examples that make use of the sender and receiver, I am assuming both the send pin and receive pin by default is the built in LED pin?

Yes thank you, but I believe the IRremote library is written for 38kHz signaling, so there should not be a problem with the modulation.

Not sure what you mean. An interrupt pin is commonly used to receive IR signals.
That's pin2 (or pin3) on an Uno.
But it all depends on what you want to do, which is not clear to me.
Leo..

Ok, my apologies,
So basically I want to set up a link between the IR transmitter and IR receiver, and while the transmitter is transmitting some signal continuously, I want the receiver to pick up the signal and measure the RSSI of the signal and have it be printed on the Serial monitor.
The board I am using is the Nano 33 IoT

I' afraid that's not possible with a 3-pin IR receiver. It either receives the signal or it doesn't.
Distance depends on power and footprint if the transmitter LEDs (which you don't seem to have used yet according to your code).

No experience.
Many of us still have and prefer the better supported older generation Arduino workhorses.
Leo..