I am making a fire fighting robot that basically detects flame and tries to put out the fire with water. The robot is on wheels hence it moves towards the fire before putting out the fire.
I have three flame sensors which can detect the flame and steer the robot in the direction of flame.
Now the issue is that even though we know in which direction the flame is we don't know how far away the flame is. We need to know this information so we can steer the robot a certain distance and stopping it before a certain threshold so it can spray water otherwise it would keep going into the flame. The flame sensors don't calculate the distance from robot so we need guidance on how to do that.
We came across the method of triangulation but am not sure if it's the correct and the best way to do it. I would love to hear on how we can achieve this.
I am willing to bet you do not know the direction of the flame. You only know there is a flame somewhere that the sensors detect. What is the cone of vision for each of your sensors? Do all the sensors see the flame at the same time or do some of them need to be turned to also see the same flame?
for triangulation i was considering putting two flame sensors on the servo motors and slowly rotating the servo motor until both flame sensors detect the flame at some angles
then using trignometry i was thinking of finding the perpendicular distance from flame to line joining the two sensors.
Yes you are correct we don't know the exact direction but more of a general direction like to the left, to the right or in the middle using three sensors. Only atmost 2 sensors detect the flame the robot rotates until only the middle sensor is in front of flame and the only one detecting it hence setting its direction towards fire. The cone of vision is about 90 degrees.
Are you talking about flame sensors like what is in your furnace? Those have to be directly in a flame in order to detect that a flame is present. By that point your robot is going to be awfully close to the flame unless if it on a very long arm in front of the robot. You might be better using an IR camera instead of flame detectors. A stereoscopic IR camera would be able to give you ranging as well.
Thinking out load … wonder if you could use three thermistors mount in short “ focusing” tubes , say a central on one each side at say 45 deg and calculate distance based on heat.
Or maybe mount the outers on a servo and calculate distance based on the best angle ?
That's a neat idea, but would depend on the flame sensors at the left and right sides to have very narrow cone of detection as @Paul_KD7HB suggested.
If the sensor out of the box has a broad response area, you could experiment with placing the sensor at one end of a tube so it could only "see" like when you look through a tube.
Tube diameter and length might be variables in such experiments. Tube material should be opaque to the flames - IR radiation can go through some materials that appear solid to us. I've used cardboard tubes wrapped in aluminum foil with success.
That sensor has only a digital output that is calibrated using the potentiometer. They detect light in the 760nm -1100nm range and only provide a range of 80 cm. I think your robot is going to fry getting that close to a fire. If it were that easy, wouldn't we all have firefighting robots in our home by now?
Like I said, if this technology was reliable and easy, we'd all have fire-fighting robots in our homes.
If you put a limit on the functionality that you are asking for of a closed environment with an open flame source and ideal lighting conditions for your sensor, then yes, I think what you are proposing might work. However, you would not need to rotate each flame sensor independently. You know the max distance the sensors will work. So, if you mount two of them some distance apart but focused on a single point, then would know if the flame is detected there. Then you would just have to swing the whole setup side to side to detect where the flame was. You'd be creating a stereoscopic flame detector. Kind of like we have stereoscopic vision to do depth perception.
The problem you are going to run into is your sensor is not unidirectional. It is merely a sensor. it's going to be triggered when pointed in the general direction of a fire. You'd have to figure out some way to narrow it's field of view.