Go to Post I love how these contests always seem to find their way to go back to Dave Lavery and (pick one) Krispy Kreme/Heidi/Photoshop - DCA Fan [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 18-01-2009, 15:14
DtD's Avatar
DtD DtD is offline
I hope the watchdog starves!
AKA: Pathogen David
FRC #2410 (The Metal Mustangs (Merged from 2334, Hazmat Robotics))
Team Role: Programmer
 
Join Date: Jan 2008
Rookie Year: 2008
Location: Kansas
Posts: 86
DtD will become famous soon enoughDtD will become famous soon enough
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
Reply With Quote
  #2   Spotlight this post!  
Unread 18-01-2009, 17:43
EHaskins EHaskins is offline
Needs to change his user title.
AKA: Eric Haskins
no team (CARD #6 (SCOE))
Team Role: College Student
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Elkhorn, WI USA
Posts: 998
EHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond repute
Send a message via MSN to EHaskins
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.
__________________
Eric Haskins KC9JVH
Reply With Quote
  #3   Spotlight this post!  
Unread 19-01-2009, 20:51
Gamer930's Avatar
Gamer930 Gamer930 is offline
Team 930 and 171 Alumni
AKA: Justin
no team
Team Role: Alumni
 
Join Date: Mar 2002
Rookie Year: 2002
Location: New Berlin, WI
Posts: 388
Gamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to beholdGamer930 is a splendid one to behold
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.
__________________
2010 to Present, Scorekeeper/Field Power Volunteer for FRC/FTC/FLL
2005 - 2010, Team 171 College Mentor
2002 - 2005, Team 930 Student
Reply With Quote
  #4   Spotlight this post!  
Unread 20-01-2009, 07:09
gvarndell's Avatar
gvarndell gvarndell is offline
Software Engineer
AKA: Addi's and Georgie's Dad
FRC #1629 (GaCo)
Team Role: Parent
 
Join Date: Jan 2009
Rookie Year: 2008
Location: Grantsville, Maryland
Posts: 350
gvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond reputegvarndell has a reputation beyond repute
Re: Code Declaration Window - Check Team in Code

Quote:
Originally Posted by DtD View Post
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...
I don't know what this code declaration window does but Workbench has many powerful code navigation/comprehension features -- type hierarchy display, quick find declarations, etc.

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.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

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


All times are GMT -5. The time now is 02:29.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi