I am using the Arduino IR library included with the TeensyDuino addon (doesn't seem to be a major difference between the teensy and standard arduino one)
The Teensy is known working. The standard on/off blink sketch works, in the sample code the serial print works.
In short, the Teensy 4.1 is not reading any IR signals. I tried using the host of IR receive examples given with the library (IR Dump, IR sample, simple IR receive, etc...) I don't know if I can dump a raw sensor output but I have no clue on how to access it.
I am trying to get the sample code working so I can implement the functions into the prebuilt code for this project, updating it and making it work on the Teensy 4.1.
I tried making my own completely stripped down code to no avail.
I read the output of the IR sensor using my o-scope and it is working. Although, I just got it and i'm still very much a novice so theres a possibility i'm misreading it.
Since I only have the one sensor and its already flush mounted to a PCB I tried to jump over the data pin to an arduino MEGA and it also had weird results (either false reads with empty data or just empty data).
I have been bashing my head on my keyboard for a week and my deadline is quickly approaching. I cannot use another board as the alternative is out of stock "temporarily" (until september, well and far beyond my deadline)
I realized that the sensor was wired to port 20 instead of a power rail so I modified the code to write port 20 high. The output of the port is 3.3V which is within range of the sensor per the datasheet.
I checked port 21 with my oscilloscope during data transmission and the data is making it to the port, this time its coming out at 3.3V instead of 50mV.
I can't believe I missed that. That was supposed to be set to pin 21, the IR signal input pin.
I must have glanced over it many times.
In the main project the PLC will have to be in an ultra low power state most of the time so the power for the TSOP is set to a pin so it, and other hardware can be powered on only when needed.
It is now reading the remote signal and the console is responding it works, next i'll see if I can decode it and parse the data.
I think I should probably leave coding to be done during the day and not at 2am, or at the very least when I have access to coffee.
Thank you very much for your help Pylon, I greatly appreciate it.