![]() |
Auto Ultrasonic Distance Sensor
2 Attachment(s)
So we are trying to code the robot to do forward from its starting position till it reaches a specific distance from the wall. We are using a MB1040 as the distance sensor. The code, which is attached, for some reason just makes the robot keep going forever forward. The sensor has been tested and it works perfectly. I'm sure I'm probably just missing something really stupid :(. Any help would be much appreciated.
|
Re: Auto Ultrasonic Distance Sensor
You need a stop for the drive. If you just write a -1 value to the drive it will continue to drive.
|
Re: Auto Ultrasonic Distance Sensor
Oh wow. I did that for the launcher motors but didn't do it for the driving ones. Ok thanks! Easy fix :)
|
| All times are GMT -5. The time now is 08:47. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi