![]() |
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 |
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.
|
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. |
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. |
| All times are GMT -5. The time now is 02:29. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi