Go to Post What's this about a robot that they speak of? Are we supposed to build one???? - ryan_f [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 26-02-2010, 11:09
Radical Pi Radical Pi is offline
Putting the Jumper in the Bumper
AKA: Ian Thompson
FRC #0639 (Code Red Robotics)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2010
Location: New York
Posts: 655
Radical Pi has a spectacular aura aboutRadical Pi has a spectacular aura aboutRadical Pi has a spectacular aura about
Check for Enhanced I/O

I want to have the operation of the robot change depending on whether or not the IO board is plugged into the classmate. Normally we have controls through Joystick and PSoC, but there is a special circumstance where the Classmate needs to be portable without anything but the E-Stop button. Is there any way to detect whether the I/O board is connected to the classmate?
__________________

"To have no errors would be life without meaning. No strugle, no joy"
"A network is only as strong as it's weakest linksys"
Reply With Quote
  #2   Spotlight this post!  
Unread 26-02-2010, 11:25
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,112
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Check for Enhanced I/O

You could use one of the input pins as a flag that it is present, as long as you don't set that input in the virtual I/O controls when it isn't connected.
Reply With Quote
  #3   Spotlight this post!  
Unread 26-02-2010, 11:39
heydowns's Avatar
heydowns heydowns is offline
Registered User
AKA: Jeff Downs
FRC #1511 (Rolling Thunder)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Ra-Cha-Cha
Posts: 142
heydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond repute
Re: Check for Enhanced I/O

If you are using the "Enhanced I/O" mode (truly the enhanced mode, using the DriverStationEnhancedIO class) you can call DriverStationEnhancedIO::GetDigitalConfig() using any legitimate channel number. If the board is not present, it will return DriverStationEnhancedIO::kUnknown.

We had to do this when using the EnhancedIO, wrapping all our runtime EIO calls inside an "if" checking that the Cypress board was plugged in. Without that, repeatedly setting outputs/reading inputs through the DriverStationEnhancedIO would spam errors through to the Driver Station diagnostic window causing poor connectivity between DS and robot.
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
Analog Out on the Cypress PSoC (enhanced modeO gokul Programming 5 23-02-2010 14:05
'Enhanced IO Missing' error Ethan E Java 2 19-02-2010 22:51
Power for system check SciDKelly134 General Forum 3 16-02-2009 12:10
Digitally Enhanced Scouting System, DESS falconmaster General Forum 1 16-04-2007 13:05
842's "Digitally Enhanced Scouting System" ChuckDickerson General Forum 6 06-04-2007 11:44


All times are GMT -5. The time now is 13:01.

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