|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Code Declaration Window - Check Team in Code
I normally use Microsoft Visual Studio outside of robotics, and constantly use the "Code Declaration Window" and I love it. I was wondering if anyone knew of something similar in WindRiver (or Eclipse...)
I found something similar on the internet, but it didn't tell me how to activate it. It just told me it was there and showed a pretty screenshot... Also, does anyone know how to check the team color in C++? I saw sombody post it earlier, but I can't seem to find it again for the life of me, and I've tried looking through the WPILib docs too... (Including regenerated ones I generated) ~DtD |
|
#2
|
||||
|
||||
|
Re: Code Declaration Window - Check Team in Code
There is a "GetAlliance" function on DriverStation, which returns an Alliance enum. I can't find it in the docs, but it is in the source for V1.2.1562. Its in DriverStation.cpp line 316, and DriverStation.h lines 23 and 46.
|
|
#3
|
|||||
|
|||||
|
Re: Code Declaration Window - Check Team in Code
Is there the same/similar block in Labview to get what team you are on (Blue or Red) ??
I know I could just add a switch to the robot that is switched before each match but trying to take the Team Error out. . . I remember reading about it, but can't find it now. |
|
#4
|
||||
|
||||
|
Re: Code Declaration Window - Check Team in Code
Quote:
Eclipse is big on context menus. To learn what can be done, it's often surprisingly educational to highlight some identifier and then right-click to see the context menu. WRT to whatever you found on the internet -- if you post a link, maybe someone can help you figure out how to plug it in to Workbench. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| May I get a steering wheel and pedal code check? | windell747 | Programming | 1 | 11-02-2008 08:43 |
| Problems integrating CMUCAM code and IFI Default Code | Windward | Programming | 2 | 06-02-2007 16:48 |
| problems using gyro/adc code with camera default code | tanstaafl | Programming | 7 | 22-01-2006 23:09 |
| Team THRUST - Kevin's Code and Camera Code Combine | Chris_Elston | Programming | 3 | 31-01-2005 22:28 |
| Fix-it window and dashboard code changes | David Brinza | Programming | 3 | 28-01-2005 01:00 |