View Single Post
  #1   Spotlight this post!  
Unread 06-11-2011, 21:34
calcmogul's Avatar
calcmogul calcmogul is offline
WPILib Developer
AKA: Tyler Veness
FRC #3512 (Spartatroniks)
Team Role: Mentor
 
Join Date: Nov 2011
Rookie Year: 2012
Location: Santa Maria, CA
Posts: 52
calcmogul is just really nicecalcmogul is just really nicecalcmogul is just really nicecalcmogul is just really nice
C++ SetCompetitionMode() Error

I'm one of the programmers on FRC Team 3512 for the upcoming 2012 competition.

My team's been writing the code for a mock competition and rewriting our old robot's code in C++, but we've been having trouble with one function in particular. According to the documentation for WPILib, a function called 'SetCompetitionMode()' is required to run the code at a competition. Page 15 of the WPILib.pdf manual states that if the function isn't there, the field automatically provides one and passes it a value of 0. However, it needs to be passed 1 in order to work as competition code.

Including 'API.h', the header file that function is in, causes an unresolved inclusion compilation error. This header file isn't included anywhere on all three of our WindRiver installations. I've applied the latest WPILib C++ source patch from http://firstforge.wpi.edu/sf/frs/do/...cts.wpilib/frs, the one from the 2011 off-season, but the problem still exists.

Any suggestions or possible solutions are appreciated.
Reply With Quote