Connect IR photodiode to ESP32 RMT?

papadeltasierra
Posts: 28
Joined: Thu Nov 03, 2022 1:57 pm

Connect IR photodiode to ESP32 RMT?

Postby papadeltasierra » Mon Oct 02, 2023 1:50 pm

Can anyone point me at some circuits showing how to connect an IR photodiode (note a 2-pin photodiode not one of those fancy "photodiode plus decoding circuitry" 3-pin sensors) to the ESP32's RMT circuitry?
I'm guessing something that boosts the photodiode's output is required - opamp? transistor?
I would prefer to use the ESP32's won RMT decoding, otherwise what's the point of having it ;-).
Thanks.

ESP_Sprite
Posts: 9583
Joined: Thu Nov 26, 2015 4:08 am

Re: Connect IR photodiode to ESP32 RMT?

Postby ESP_Sprite » Tue Oct 03, 2023 2:02 am

That's kinda hard. The decoding circuitry is there to make those chips specifically sensitive to a 38KHz carrier, ignoring everything else, and that is why they can give such a good binary output. A photo diode does not filter a carrier wave, so it picks up everything and everything goes in the analog output value it gives. Sunlight on photo diode? That's a DC bias in the output. 50 or 100Hz from an incandescent lightbulb? That's a 50 or 100Hz sine in your output. Got something that uses IR light like an Apple phone or a VR lighthouse? That ends up in the output. If you simply threshold that to get a binary value, you'll get an undecodable mess, with all of those influences jumbled together rather than a simple binary stream you can feed into the RMT.

Who is online

Users browsing this forum: No registered users and 111 guests