Go to Post I don't know if the WPILibrary has a FluxCapacitor.vi in it. - DavidGitz [more]
Home
Go Back   Chief Delphi > Technical > Control System > Sensors
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 30-01-2011, 00:32
StevenB StevenB is offline
is having FRC withdrawal symptoms.
AKA: Steven Bell
no team
Team Role: College Student
 
Join Date: May 2005
Rookie Year: 2005
Location: Stanford, CA
Posts: 412
StevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond repute
Re: Line Tracking Photoswitch Info and Demo Video

Just a couple additional notes, since I'm an electrical engineering student and happened to be wiring the sensor up today.
  • The sensor acts like a switch that closes when it sees a white object. It's using transistors inside rather than a mechanical switch, but as far as the wiring is concerned it acts just like a limit switch (except that it needs +12V power). Like a limit switch, it has a "normally open" and "normally closed" output; one output will be high when it sees a light object, the other will be high when it sees a dark object. Look at the sensor datasheet for all the gory details.
  • The digital sidecar has built-in pullup resistors, which means that unless you connect the GPIO pin to ground, it will have a value of 5V. This means you don't need any additional circuitry to hook up the photoswitches. See the Digital Sidecar datasheet for more information.
  • The attached schematic tries to show the whole picture. Note that you could just as easily connect the black wire to the GPIO pin, it's just a matter of whether you get a "1" for dark or a "1" for light. (My apologies if I mixed up LO and DO on the schematic. Let me know and I'll fix it.)
  • The part number is 42EF-D1MNAK-A(2). The 2 isn't given, but it's apparently part of the number based on Rockwell's part selection tool. If you haven't found it already, a CAD model (STEP) is available on Rockwell's site.
To those wondering how you program these things: it's a switch - a digital input - a 1 or a 0. Once you calibrate it, it will have one value when it's over the carpet and the other value when it's over the tape. All you have to do is read the sensor value to determine if you're on the tape or not.
If you have questions about how to follow a line, look at this white paper from NI, or ask an FLL student.
Attached Thumbnails
Click image for larger version

Name:	linesensor_drawing.png
Views:	73
Size:	20.8 KB
ID:	9886  
__________________
Need a physics refresher? Want to know if that motor is big enough for your arm? A FIRST Encounter with Physics

2005-2007: Student | Team #1519, Mechanical Mayhem | Milford, NH
2008-2011: Mentor | Team #2359, RoboLobos | Edmond, OK
2014-??: Mentor | Looking for a team...
Reply With Quote
  #17   Spotlight this post!  
Unread 09-02-2011, 21:03
SHH SHH is offline
Registered User
FRC #3260
 
Join Date: Feb 2011
Location: Pittsburgh, Pa
Posts: 1
SHH is an unknown quantity at this point
Re: Line Tracking Photoswitch Info and Demo Video

We have hooked the photoswitch up to the power distribution board and to the signal pin on the DSC, but we only recieve "true" when we use the DigitalInput get() method, no matter what surface the photoswitch is directed at. Any help would be greatly appreciated.
Reply With Quote
  #18   Spotlight this post!  
Unread 09-02-2011, 21:59
kinganu123 kinganu123 is offline
Registered User
FRC #1747
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Piscataway, NJ
Posts: 243
kinganu123 is on a distinguished road
Re: Line Tracking Photoswitch Info and Demo Video

Quote:
Originally Posted by SHH View Post
We have hooked the photoswitch up to the power distribution board and to the signal pin on the DSC, but we only recieve "true" when we use the DigitalInput get() method, no matter what surface the photoswitch is directed at. Any help would be greatly appreciated.
I found that initializing Victors (doesn't matter if they are really there or not) solved my problem. The DB37 cable apparently needs to send more power and this is only possible by creating more "sensors" in the DSC
But before you do that, do your lights change color? Green when it sees nothing and orange and yellow when it does?
__________________
Reply With Quote
  #19   Spotlight this post!  
Unread 09-02-2011, 22:53
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: Line Tracking Photoswitch Info and Demo Video

Quote:
Originally Posted by kinganu123 View Post
I found that initializing Victors (doesn't matter if they are really there or not) solved my problem. The DB37 cable apparently needs to send more power...
Ack! You need to make sure that you are properly supplying battery power to the Digital Sidecar's small white Wago power connector. The power should come from a 20 Amp circuit on the Power Distribution board.
Reply With Quote
  #20   Spotlight this post!  
Unread 14-02-2011, 14:09
Nicandy's Avatar
Nicandy Nicandy is offline
Registered User
AKA: Nicole/Andy
FRC #3580 (Marinerds)
Team Role: Engineer
 
Join Date: Feb 2011
Rookie Year: 2011
Location: Cape Coral
Posts: 23
Nicandy is an unknown quantity at this point
Re: Line Tracking Photoswitch Info and Demo Video

What did you use to connect the white sensor wire to connect the photoswitch to the I/O on the digital sidecar?
Sorry for posting such a basic question on a month old thread, but any help would be greatly appreciated.
Reply With Quote
  #21   Spotlight this post!  
Unread 14-02-2011, 15:20
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: Line Tracking Photoswitch Info and Demo Video

Quote:
Originally Posted by Nicandy View Post
What did you use to connect the white sensor wire to connect the photoswitch to the I/O on the digital sidecar?
Cut one of the three-wire PWM extension cables in half. One half will have the appropriate connector for the Digital Sidecar's I/O pins. Carefully tuck the cable's black and red wires out of the way, covering the ends with electrical tape so they don't contact anything. Splice the cable's white wire to the sensor's signal.

Or you can do what we typically do and make your own connector. Crimp the appropriate kind of female pin onto the sensor's signal wire and insert it into the appropriate kind of servo-style connector housing. We're running low on parts and should probably order more from a place like Hansen Hobbies.
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


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

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