Ultrasonic/optic sensors for wall angle detection?

Would it be possible to have 2 ultrasonic/optic sensors on your robot, 50 cm apart and to compare the distance inbetween the 2 to find the angle of the robot from the wall(with trig)? I’ve heard that this is not possible due to interference- is that true? I have also seen some discussion on Cheif Delphi saying that rangefinders don’t work when at an angle due to the angle of incidence/refraction. Do any teams have experience with this? Would you recommend any sensor in particular?

This will work, provided the angle that the sound/light is transmitted is small enough. If the transmit beam angle is more than a few degrees wide, you will get crosstalk (interference) between the sensors unless they use different frequencies or “take turns”. [there may be other ways to mitigate this I’m not thinking of right now]

This topic has what looks like a good candidate:

That one looks good but I’m looking for something with 6+ m range, do you know anything in this distance- and would it be possible in an angle range of 20 degrees

With the wall being 12x as far as your sensor separation, you’re going to need a really tight receive aperture even with time sharing. This is because the shortest distance is off to one side of where you expect it to be. For what you’re asking, I suggest combining a gyroscope for time away from the wall with something similar to your idea to regularly recalibrate. [but watch out for those slightly angled driver stations and the shield generator’s support trusses.]

Quick question, how about 1 LiDar and 1 optical? In general 2 diffrent sensor types to prevent interference?

As long as you can cross-calibrate them and they use different frequencies/colors, it should work at shorter ranges, questionable at longer ranges. Also note that optical / laser sensors may have problems with the clear walls on the field’s side rails. The alliance walls are metal for the driver stations and look to be opaquely colored for the feeder/scoring stations.

Alright how about a single sensor at 6+ meters just to figure out distance from the wall. What sensor type/make would you recommend? (and yes, this would be for autonomous ranging of the fuel cell target.)

That could work. Alternately, you could use a camera and cue off of the retroreflective target. If you’re off to one side, the target gets narrower, if you’re too far it’s too small, if you’re too close it’s too large. PixyCam and Limelight have made doing these determinations pretty easy.

I have also seen teams do this low-tech by streaming the camera back to the driver station, finding the sweet spot, and putting thin strips of tape on their laptop screen showing where the target should be.

Yep- that’s the plan for our team. We’re going to use a limelight with weighted targeting. We still want a rangefinder to get the power to shoot our balls with- so would most ultrasonic sensors work on the painted polycarb.

Ultrasonic isn’t going to care about whether it’s painted.
Even if you use a rangefinder sensor, you can likely get good range info from the elevation and height of the vision target.

Both the the Copperforge and the Playing With Fusion parts are based on the VL53L1X time-of-flight sensors. These sensors bounce an IR laser off the target to measure distance. The have excellent accuracy and 1mm precision, but they definitely won’t work past 4 meters.

According to ST they have a 27 degree field of view, so it’s going to be difficult to aim two sensors at the same target without having the two interfere. You could try reducing the sensor ROI (basically the area of the image sensor used) to try and decrease the field of view, but reducing ROI will also decrease sensitivity and maximum ranging distance.