M-File Help: RandomPath | View code for RandomPath |
Vehicle driver class
d = speed. The waypoints are positioned inside a region bounded by +/- dim in the x- and y-directions. The driver object is attached to a Vehicle object by the latter's add_driver() method.init | reset the random number generator |
demand | return speed and steer angle to next waypoint |
display | display the state and parameters in human readable form |
char | convert the state and parameters to human readable form |
goal | current goal coordinate |
veh | the Vehicle object being controlled |
dim | dimensions of the work space |
speed | speed of travel |
closeenough | proximity to waypoint at which next is chosen |
randstream | random number stream used for coordinates |
veh = Vehicle(V); veh.add_driver( RandomPath(20, 2) );
Create a driver object
d = speed. The waypoints are positioned inside a region bounded by +/- dim in the x- and y-directions.Convert driver parameters and state to a string
s = R.Compute speed and heading to waypoint
[speed,steer] = R.VehicleDisplay driver parameters and state
R.display driver parameters and state in compact human readable form.Reset random number generator
R.randstream© 1990-2011 Peter Corke.