Athlete photogate timer

Thread Starter

Aaron11

Joined Jun 23, 2012
22
Yay :) I'll get the parts from radio shack tomorrow and bench test it probably this weekend if I get my new violet lasers soon enough. I wish I leaned about MOSFETs in my circuits class I would of totally gone for this design over what I came up with its so much cheaper, simpler, faster, and just plain better thank you for all your input wayneh you have been such a big help :). There is one final design flaw left that I need to fix when you run through the photogate I was getting a lot of double feeds in other words my left leg would trip the laser then my right would trip it a split second later do you know of a component I can add to the circuit that will let me slow down how fast the circuit resets itself so it takes for instance a half second or so before the laser can be tripped again so that I can still use the fastest lap/average lap feature of the stop watch that data will be useless if there are 0.02 second readings on it from double feeds
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
See the last sentence of post #11 - you need a de-bounce. Get a 555 timer IC while you're at the Shack. If you don't have a supply of resistors and caps laying around, you may want to figure out what you'll need for the 555 circuit before you go shopping.

It'll allow you to set a quiet period during which another triggering is not possible. There are other ways such as a low-pass filter, but I believe that would interfere with the accuracy of the timing.
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
how inacurate is the low pass? because the 555 debounce circuits that I'm seeing are little complicated for my skill level. The fastest that the photogate will ever be tripped in the drills we run is about 2 seconds so the delay needs to be somewhere between 0.5 and 1.5 seconds so there is a decent window of error to fit into.
 

wayneh

Joined Sep 9, 2010
17,496
Is there any chance your timer might have this function in software, to prevent trips less than, say, 0.5 sec apart?

Thing is, you want the MOSFET to trigger sharply, not on some ramp, so that the timer switches cleanly. A "digital" solution such as the 555 accomplishes this nicely. I'm not too sure how to do this with a simple "analog" solution like a filter. You could build a monostable with other ICs such as a comparator but this wouldn't be any simpler than using a 555. Maybe somebody else has an idea?
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
I'm probably just going to have to suck it up and build the 555 debounce I just don't know where to begin with it so for instance where do I install this into the circuit you helped me design and how do I figure out what resistors and capacitors to use?

Funny here is a similiar system to mine that even uses a ROBIC stopwatch like mine but this guy used relays I want to use MOSFETs http://www.recumbents.com/wisil/timing/sprint_timer.htm
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
I'm probably just going to have to suck it up and build the 555 debounce I just don't know where to begin with it so for instance where do I install this into the circuit you helped me design and how do I figure out what resistors and capacitors to use?
I can draw something but I'm off to watch fireworks for the night. Back tomorrow.
 

wayneh

Joined Sep 9, 2010
17,496
Funny here is a similiar system to mine that even uses a ROBIC stopwatch like mine but this guy used relays I want to use MOSFETs http://www.recumbents.com/wisil/timing/sprint_timer.htm
Ah, this is very helpful. No substitute for experience.

In that circuit, the lefthand relay, let's call it the sensor relay, was added to reduce spurious triggering. I believe there could be better ways to do this, and if I were you, I think I'd only add this "feature" once the rest of the circuit is up and running, and when you've proven to yourself that it's required. If that incremental approach doesn't fit your plan and you need the whole system to work on the first try, then we'll deal with it.

That debounce circuit shown should be fine, although you might want different timing than that poster used. The output on pin 3 of the 555 is what you will send to the gate of the MOSFET.

If your supply voltage to the 555 is less than 12V, I believe the 555 will not put more than 10V to the output, which may not be enough to fully trigger a regular (not logic level MOSFET). So in that case you'll want to either choose a logic-level MOSFET (not? available at the Shack) or put a pull-up resistor on the 555 output pin 3. That will take the voltage up to the rail when the pin goes high, and the 555 will still be able to pull it low when pin 3 goes low. The whole idea is to provide the MOSFET only 2 states, a fully on or fully off signal.

The input to pin 2 will receive the signal that was previously applied to the gate in the circuit we were discussing without debounce. In the linked circuit, everything to the left of pin 2 and the 47K resistor is for getting a clean trigger signal onto pin 2. You're using a photosensor, so your needs will be a bit different.

Again, my approach would be to try the simplest circuit (nothing on pin 2 except what you had before) first and only add filtering, etc. once you know it's required. That said, you could try just duplicating the circuit shown, replacing the relay contact point with the signal from your sensor.
 

wayneh

Joined Sep 9, 2010
17,496
Nailed it, except for a line from R4 node with pin 4 (reset) up to Vcc.

FWIW, your timer is set to give a 1.137 sec "time out" delay, which can be calculated as 1.1•R•C. If you need it to be faster, make either C or R4 a bit smaller.
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
Ok final draft I was wondering if I can put a variable resistor in for R3 here so I can adjust how long the delay lasts for different applications where I might need it to last shorter or longer
 

wayneh

Joined Sep 9, 2010
17,496
You can always use a variable resistor instead of a fixed one and I think it's a good idea for your application. (In your drawing, you should add a line from the wiper terminal to one pole or the other. This makes it clear how you've set it up AND it's a useful way to steady the wiper signal as it moves, when it occasionally goes "open".)

I believe the only disadvantages of variable resistors other than cost are that they are subject to mechanical stress and inadvertent adjustment. Oh, and they're usually bigger. None of these should be a big problem for you.

BTW, the maximum supply voltage for the 555 is 16V and the max gate-to-source voltage for a MOSFET is 15V. So your 18V as drawn is too high for both. Now, a 9V battery under load will usually be less than 9V, but I think this is still not a good arrangement. I think the circuit will probably work fine with a single 9V battery if you use a logic level MOSFET, and also even if you don't. But you should be aware of this issue.
 
Last edited:

Thread Starter

Aaron11

Joined Jun 23, 2012
22
I got the circuit all soldered together I checked all my connections for shorts and opens. I used a 555CN IC (rated for 18v) and an IRF510 N-type mosfet. When light is exposed to the sensor the voltage difference goes from a low value (based on ambient light) to around 12v and this range changes based on the variable resistor I have in series with the sensor. Why is the sensor working in reverse to what it is suppose to its suppose to have no voltage difference when the light is on and 5+ volts difference when the light is off?? the voltage was measured between gate and source/ground, the voltage difference at Vcc IC vs ground is 12v, the voltage at the trigger vs the ground is 11.7v in light and .2v in dark. I tested the timer and it runs and generates lap times but the lap times are triggered when light is on instead of off and whether the adjustable delay is actually working is inconclusive at the moment I can't tell if it is.
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
... the voltage at the trigger vs the ground is 11.7v in light and .2v in dark.
Well that's unexpected. Do you have any specs on that sensor? You might have to just move it's position relative to the variable resistor.

But before you do that, I believe the 555 is triggered by a negative going pulse on the trigger, which is exactly what you'll get with what you've described. Maybe this is a happy goof?
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
I bought a pack of common photo resistors from radio shack it came with two large, two medium sized, and 1 small. I used one of the large ones for the circuit when illuminated by a laser or flash light the resistance reads zero it becomes a short but when in the dark my 2000k multimeter can't even read the resistance because it is so high. When I turn the Pot on the sensor all the way off to short trigger voltage is 12v in the dark 11v in the light and the gate reads zero for both. When at 50% resistance trigger voltage is 11.7v in the dark 1.6v in the light and gate voltage is 0.0v in the dark 11.1v in the light. When at 100% resistance 11.4v in the dark 1.1v in the light and gate voltage is 0.0v in the dark and 11.1v in the light. The circuit actually works its just working backwards lol I sure hope it's something stupid simple...
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
Ok I think I see how to fix this "In the monostable mode, the 555 timer acts as a "one-shot" pulse generator. The pulse begins when the 555 timer receives a signal at the trigger input that falls below a third of the voltage supply" I have to connect the trigger after the sensor not before so that when no light is recieved the resistance goes up lowering the voltage at the trigger generating a pulse.
 

wayneh

Joined Sep 9, 2010
17,496
As drawn, this will ground the trigger pin at all times. Not what you want.

Did you consider what I said above, that you WANT to capture a negative going pulse - which triggers the 555 - when the beam is broken? Maybe I've misunderstood your situation but it sounded like that was exactly what you already have.
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22
my problem is the mosfet is only being triggered when there is light and not when there isnt its working opposite to how its suppose to the mosfet is suppose to be triggered when there is no light not when there is light.
 

wayneh

Joined Sep 9, 2010
17,496
What is the current schematic?

You're saying the timer's output pin remains high indefinitely while the light shines on the sensor? What is the state of the trigger voltage while the light is on? And off?
 

Thread Starter

Aaron11

Joined Jun 23, 2012
22

This is how it was hooked up when I tested it. When there is no light trigger is high and when there is light trigger voltage is low so it is working in reverse of what was intended. I also tried running the photo resistor directly to the trigger pin with no ground but that didn't work either. You can see looking at it what is happening when the sensor has light it is shorting out the trigger pin to ground lowering it's voltage generating a pulse so to reverse that action I think I have to add another mosfet at the trigger pin what do you think?
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
Just reverse the positions of the sensor and the variable resistor, keeping the trigger between them.

BTW, the sensor is working normally - it conducts when lit and not when dark. :)
 
Top