I’ve a couple of these 38 kHz IR Proximity Sensors for tracking an object, heat-shrink helps avoid cross talk but he output just isn’t consistent.
One off powered from a battery and output to a scope helps you see just how much the signal bounces from the first appearance of an object as how this changes when the object is pulled right into the sensor.
Has anyone got some tips for smoothing out the issue - even if it reduces the response time?
I am sorry you are having problems using your IR proximity sensor. Could you tell us more about the output you are seeing? Could you post screen captures of your oscilloscope that shows the proximity sensors’ outputs?
I’ll have to send those when I’m back from robotchallenge.org/ next week.
Broadly rapid transitions High to Low, mostly undetected with odd trigger as objects approach becoming more solidly on with odd detection gaps until the object is Very close. I’m trying to work around with counts on detection gained and lost but it’s not great.
Issues for 5v and 3.3v operation, difference being range - Jumper didn’t appear to make much difference to 3.3v range.
I would be happy to take a look at those when you post them; however, it sounds like what you are seeing might be the expected behavior. Below is an oscilloscope capture from the 38 kHz IR proximity sensor’s product page that shows its output when an object is close to its threshold of detection.
I bought these quite some time ago. I’m not sure I saw the limitation then but the real key for me is finding a way of making them useful.
Broadly, the output depiced goes from mostly off with odd bits off “on” noise to something that’s mostly on with odd bits of “off” noise. Any single sample is a random output that is not necessarily representative of actual state.
I’m thinking about best ways to process this signal to give a more reliable response, at the moment it appears that guessing is about as reliable as detection. If the output is filtered in software or hardware then we’re getting to a more reliable, I was hoping this forum may have a few tips on what’s worked for others.
Like you mentioned, implementing some sort of filtering or averaging would smooth out the signal. I recommend implementing a running average to see if that helps smooth it out. Also, you might consider using two separate units; one dedicated for transmitting and the other for receiving. This might help reduce spurious readings and is how the proximity detection on our new Zumo 32U4 robot works.