Thread: pressure switch
View Single Post
  #6   Spotlight this post!  
Unread 14-02-2002, 23:15
Lloyd Burns Lloyd Burns is offline
Registered User
FRC #1246 (Agincourt Robotics)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Toronto
Posts: 292
Lloyd Burns is an unknown quantity at this point
You can use either of the small wire cables you were given, either the two-wire cable (one run per switch, with black carrying ground, red the signal), or the three-wire shielded cable (one run does both switches), using the black to go to both switches, and red to one and white to the other.

It doesn't matter which terminal is connected to ground. We use ring terminals at the switch terminals.

Ours are wired with 3-wire; the black goes to pin 3 of the digital input (one of several grounds), and red to 2, and white to 1. You can pick any digital input you wish, we use rc_sw1 (pin 1) and rc_sw2 (pin 2).

When the switch is below the set-point pressure, it is closed, and the input the program sees is a '1'. When the pressure goes higher than the set-point, the switch opens and the program sees a '0'.