C# Class CSharpRoboticsLib.Utility.Util

Provides various mathematical and logical utility functions
Afficher le fichier Open project: shockwave4488/CSharpRoboticsLib

Méthodes publiques

Méthode Description
AccurateWaitMilliseconds ( double time ) : void

Waits for a specified time more accurately than Thread.Sleep()

AccurateWaitSeconds ( double time ) : void

Waits for a specified time more accurately than Thread.Sleep()

Limit ( double value, double low, double high ) : double

Limits the value to a low and high threshold

ToDegrees ( double radians ) : double

Converts radians to degrees

ToRadians ( double degrees ) : double

Converts degrees to radians

WrapDegrees ( double degrees ) : double

Wraps degrees around -180 to 180

WrapError ( double value, double setpoint, double min, double max ) : double

Wraps an error value around a maximum and minimum input.

WrapRadians ( double radians ) : double

Wraos radians around -PI and PI

Method Details

AccurateWaitMilliseconds() public static méthode

Waits for a specified time more accurately than Thread.Sleep()
public static AccurateWaitMilliseconds ( double time ) : void
time double Time in milliseconds to wait
Résultat void

AccurateWaitSeconds() public static méthode

Waits for a specified time more accurately than Thread.Sleep()
public static AccurateWaitSeconds ( double time ) : void
time double Time in seconds to wait
Résultat void

Limit() public static méthode

Limits the value to a low and high threshold
public static Limit ( double value, double low, double high ) : double
value double value to be limited
low double lower limit
high double upper limit
Résultat double

ToDegrees() public static méthode

Converts radians to degrees
public static ToDegrees ( double radians ) : double
radians double angle in radians
Résultat double

ToRadians() public static méthode

Converts degrees to radians
public static ToRadians ( double degrees ) : double
degrees double angle in degrees
Résultat double

WrapDegrees() public static méthode

Wraps degrees around -180 to 180
public static WrapDegrees ( double degrees ) : double
degrees double
Résultat double

WrapError() public static méthode

Wraps an error value around a maximum and minimum input.
public static WrapError ( double value, double setpoint, double min, double max ) : double
value double
setpoint double
min double
max double
Résultat double

WrapRadians() public static méthode

Wraos radians around -PI and PI
public static WrapRadians ( double radians ) : double
radians double
Résultat double