Class Threads
java.lang.Object
org.wpilib.system.Threads
-
Method Summary
Modifier and TypeMethodDescriptionstatic intGets the current thread's priority.static booleansetCurrentThreadPriority(int priority) Deprecated.Incorrect usage of real-time priority can lead to system lockups.
-
Method Details
-
getCurrentThreadPriority
Gets the current thread's priority.Priorities range from 0 to 99 where 0 is non-real-time, and 1-99 are real-time, and 99 is highest priority. See "man 7 sched" for details.
- Returns:
- The current thread's priority.
-
setCurrentThreadPriority
Deprecated.Incorrect usage of real-time priority can lead to system lockups. Only use this function if you are trained in real-time software development.Sets the current thread's priority.Priorities range from 0 to 99 where 0 is non-real-time, 1-99 are real-time, and 99 is highest priority. See "man 7 sched" for details.
- Parameters:
priority- The priority.- Returns:
- True on success.
-