Go to Post The last 20% takes 80% of the time. Beware. - JVN [more]
Home
Go Back   Chief Delphi > Technical > Electrical
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 09-02-2006, 15:51
DemonYawgmoth's Avatar
DemonYawgmoth DemonYawgmoth is offline
Registered User
AKA: Artem Kochnev
FRC #1396 (Pyrobots)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2003
Location: Staten Island, NY
Posts: 28
DemonYawgmoth is an unknown quantity at this point
Send a message via AIM to DemonYawgmoth Send a message via MSN to DemonYawgmoth
How to connect the touch sensor?

We want to use one of the touch sensors that came in the sensor bag this year, and we cant seem to find anything online as to how to connect the touch sensor to the robot controller and such. Where would the wires connect on the RC? Would it plug into a digital input or analog input. I'm guessing analog, but im not sure? Thanks in advance guys.
  #2   Spotlight this post!  
Unread 09-02-2006, 16:07
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,113
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: How to connect the touch sensor?

Do you mean microswitch?

The "common" connection goes to ground, and either the "normally open" or "normally closed" connection goes to a digital input on the RC. You'll read its value as 1 when the switch is open, and 0 when the switch is closed.
  #3   Spotlight this post!  
Unread 09-02-2006, 16:34
DemonYawgmoth's Avatar
DemonYawgmoth DemonYawgmoth is offline
Registered User
AKA: Artem Kochnev
FRC #1396 (Pyrobots)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2003
Location: Staten Island, NY
Posts: 28
DemonYawgmoth is an unknown quantity at this point
Send a message via AIM to DemonYawgmoth Send a message via MSN to DemonYawgmoth
Re: How to connect the touch sensor?

maybe im doing something incorrectly, but if i test it with if (rc_dig_in01 == 0) and then do some other stuff, would that work? also, how would we print stuff with printf()? we used it 2 years ago but i forgot how to get it to work. Also, i forgot the proper procedure for connecting the RC or OI to the computer to actually get these printf values. Thanks.
  #4   Spotlight this post!  
Unread 13-02-2006, 00:29
Chriszuma's Avatar
Chriszuma Chriszuma is offline
Jack of all trades
AKA: Chris Hammond
FRC #0068 (Truck Town Thunder)
Team Role: Alumni
 
Join Date: Oct 2004
Rookie Year: 2005
Location: Clarkston, MI
Posts: 290
Chriszuma is just really niceChriszuma is just really niceChriszuma is just really niceChriszuma is just really nice
Send a message via AIM to Chriszuma
Re: How to connect the touch sensor?

Yes, that should work, as long as the stuff you want it to do is enclosed in {braces}. The printf command is very simple.

Code:
printf( "The digital in is reading %d", (int)rc_dig_in01 );
When you download the code with IFI Loader, it should automatically bring up a terminal window that dissplays the printf outputs. (you can also click 'terminal window' in the menu to bring it up).
__________________
2006 T3 World Tour: Great Lakes - Waterloo - Palmetto - IRI
2006 Awards: Motorola Quality - RadioShack Innovation in Control

My website: http://zuma.phire.org/
Truck Town Thunder's website: http://trucktownthunder.com/
Closed Thread


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
Bannner IR sensor Measures Ball Exit Velocity Dale(294engr] Technical Discussion 4 15-02-2006 23:57
Making a Sensor Board SpaceOsc Technical Discussion 11 15-05-2004 12:46
heres the code. y this not working omega Programming 16 31-03-2004 15:18
Quick Optical Sensor Question zorro Technical Discussion 10 21-01-2003 06:39
How do you connect optical sensor? archiver 2001 1 23-06-2002 23:05


All times are GMT -5. The time now is 04:44.

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