I tried to run the example “Find Hole” from Dexter. The GoPiGo drives and stops in front of an obstacle and scans the environment, but can’t find a hole (see attached screenshot), even though there is plenty of room to drive further.
You know, I’ve never attempted this particular demo but others have. Short term, I won’t be able to take a look at it, so if someone else can pipe in? Otherwise, I’ll attempt it on Tuesday. I just didn’t want you to be kept wondering.
Im not 100% sure but i think it needs 3 consecutive infinate readings (>200) to be able to continue.
If it doesnt find 3 consecutive infinate readings the script will stop.
Hey TomDriftwood, it’s been a while since we looked at this example! I think you might want to tweak these lines:
STOP_DIST=20 # Dist, in cm, before an obstacle to stop.
SAMPLES=4 # Number of sample readings to take for each reading.
INF=200 # Distance, in cm, to be considered infinity.
REPEAT=2
DELAY=.02
You might increase (or decrease) any of the first 4 lines there to make it work successfully in your environment.