Robotics Adventurer:
This question has come up before. It can only be answered officially by Marc.
Personally, I think we should be building on existing code rather than "reinventing the wheel".
On a different note, have you actually tried using the wrappers that you mentioned? Did it work OK?
Trevor
Yeap. You can check out my youtube channel youtube.com/merlinjim for screen shots. I did have to download the source to both OpenCV and EMGU and recompile from scratch for a few things (some of the Kalman stuff wasn't wrapped right in the default EMGU implementation - you need to add a Predict that takes no arguments and uses IntPtr.Zero for the control argument on the underlying library)
So what did I get out of it?
Near frame object detection - I don't know if you've noticed, the bot is wider than the IR. The vision can override the IR if it detects an obstacle.
Mid frame wall detection - very accurate out to about 3m. I'm using hough feature extraction to extract the base floor distances - almost like a laser SICK would - and then I feed those (rather inaccurate) figures through a kalman filter. The driving algorithm uses this information to look ahead and try to predict if a wall continues, breaks, or turns, without having to stop and take an IR reading
callibration - if the drive miscallibrates the angle due to repeated calls or due to missing one or more calls, it can be harsh on the driving algorithm. The drive algorithm uses every IR wall verification to also check the slope of the wall visually and autocorrect errors as small as 3 degrees or as large as 60 degrees with respect to being orthogonal to the wall.
Ramp detection - I'm using the OpenCV fast array maths to quickly compute averages of the wall above the mid frame wall detection code. If it's a bright object, I assume it's the ramp and modify my behaviour accordingly
I'll be happy to help any who want it set up these kinds of sensors for the sumo competition :) Just as soon as I hit this darn qualify button! My bots made it out a couple times... I just want to be sure he's got a good shot before I click it :)