The WPI Robotics Library

The National Instruments compact RIO-9074 real-time controller (cRIO) is presently the robot controller provided by the FIRST Robotics Competition (FRC). It has around five hundred times more memory than previous FRC controllers. Dedicated hardware of FPGA capable of sampling across 16 channels replaces previously cumbersome programming techniques necessary with previous controllers.
The WPI Robotics library is designed to:
• Work with the cRIO controller
• Handle low level interfacing of components
• Allow all experience levels users access to experience appropriate features

C++ and Java are the two choices of text-based languages available for use on the cRIO. These languages were selected due to they represent a better level of abstraction for robot programs than previously used languages. The WPI Robotics Library is designed for maximum extensibility and software reuse with these languages.

The library consist classes which support the sensors, speed controllers, driver station, and other hardware in the kit of parts. In addition, WPILib supports many commonly used sensors which are not in the kit, such as ultrasonic rangefinders. WPILib has a general features, such as general-purpose counters, to provide support for custom hardware and devices. The FPGA hardware also allows for interrupt processing to be dispatched at the task level, instead of as kernel interrupt handlers, reducing many common real-time bug problems.

The WPI Robotics library does not support the C++ explicitly, exception handling mechanism, though it is available to teams for their programs. Uncaught exceptions will unwind the entire call stack and cause the whole robot program to quit, therefore, we caution teams on the use of this feature.

Objects are allocated dynamically to represent each type of sensor. An internal reservation system for hardware is used to prevent reuse of the same ports for different. In the C++ version the code source for the library will be published on a server for teams to review and make comments. In the Java version the code source is included with each release. There will be a repository for teams to develop and share projects community for any language including LabVIEW.

No comments:

Post a Comment