Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Photomicrosensor Help...

Status
Not open for further replies.

Fast Matt

New Member
Hello All

I have surfed in from the WWW to ask a question.... I have perused some past posts and know there must be somebody here who can answer my question.....

I will readily admit I'm a dope at electronics - I have enough sense to do some basics etc...But I'm a dope...... (smart enought to ask others I guess :) )

Anyway.....
I have a slot car track..... And - I'm trying to make two "slot type" photomicrosensors work with a Phidget I/O board (that go into the PC - that ties in with my slot racing software...)...... The two sensors are about 18 inches apart.... Same lane (for those familier with slot tracks) - or to explain - the same car passes both sensors - seperated by 18".... The senors are Omron EE-SX1070.... Very basic. It works great when you are cruising - no issues at all - however.....

The documentation says they rise and fall at 4 miliseconds...... So - my problem is - the darn car covers the 18 inches in less than a tenth (when racing).... Sounds like it should come close to working - right? Of course not......Basically the input is only seeing one signal. I'm not able to get two distinct signals.....

My question is - how can I "pulse" the signal faster - or in my terminology - have it die quicker :D
The "output" from the sensor goes right into the I/O card - I don't have anything branching off like an LED..... I'm not sure If a zenor Diode will do it - It just seems to stay hot too long....maybe an LED to help pull the voltage down quicker..... or both??

I appreciate any input!!

Thanks
Matt
 
Ron, matt said 4 miiliseconds, not microseconds.

That said those little cars must be whizzing along not to be seen in that window.
You mention only one signal instead of two, if both cars are in alignment when they pass the infra reds then this is gonna happen no matter what, however if there is a visual gap between the cars then there might be a slow down capacitor on the pcb somewhere probably put there to increase noise immunity, if the delay is software then there int much you can do about it.

You'd be better having 2 infra reds one for each car.
 
Microseconds - correct not milli....I did the conversion to something I could understand earlier in the day. I did say I was a dope to start with.... I was looking at datasheets and diagrams too long.... :D

Correct KISS - that is what I'm using (now I have to google schmidt trigger - but yes!)
I have attached a picture of the section of track where the sensors are - just to make it clear. Each lane has 2 sensors.
I pull 5V and G off of the I/O board - run that to the array of sensors - then run the "output" from each sensor back to an input. I did forget to say I have diodes on each output.... Each input has two sensors wired to it - there are 4 lanes - 4 inputs - 8 sensors....... I have also attached a rough-ish diagram showing what one lane looks like....

The purpose of all of this....... In the racing software - as you race you can "burn" fuel. These sensors are for detacting a pit stop. If the signal comes in once (stopping between the sensors) - it starts a refuel action in the software after 1 second - and stops when the second signal triggers...... This is all easy to do with modern slot car tracks - so called "digital" tracks... My track style is direct from the 60's so I'm trying to adapt this pit stop function to it....... I can't find anyplace that it has been done (and documented...)

The I/O board is at
https://www.phidgets.com/products.php?category=0&product_id=1012_2

I did find this on the link above:
Digital Inputs

Number of Digital Inputs 16
Digital Input Impedance 10 kΩ
Low Voltage Max (True) 1.3 V DC
High Voltage Min (False) 3.8 V DC
Digital Input Voltage Max ± 30 V DC
Digital Input Update Rate 125 samples/s
Trigger Length Min 3 ms

Maybe I'm mixing apples and oranges? Maybe it can't be done with what I have??

Thanks for all the help!!!!!
 
Last edited:
I don't think you need the diodes. But having said that I'm not sure how you can tell that it is stopped between the sensors since they both look the same to the I/O board.
What size is Rl?
 
I assume that the slot car interrupts the beam when it goes by? If so, I don't see how you would get any pulse at all.

Since both transistors are effectively in parallel, you will only get a low going pulse when both beams are blocked at the same time.
 
Agreed with above, both beams have to be broken to get a low, though technically with both broken on that circuit you'd get a floating and thats probably why it doesnt have a good response time, you'd have to wait for the input to discharge, if you want a logic low with both beams broken then try a pulldown resistor from the diodes cathodes to ground, if you want a logic low when either beam is broken then your gonna have to rework your circuit.
 
You also kinda got your circuit messed up. The (A) point below should be connected to the logic input.

You need a resistor to +5, (A) then the transistor and then ground. Point A, is where the logic point would be,

The issues would be that 0.6 would be dropped across the transistor, to make 0.6 V for a low.

If you wanted to use two diodes to make an or gate, but I think you want an and gate. You can use a diode to do a "wired-or", but not a AND function. See: https://en.wikipedia.org/wiki/Wired_logic_connection

An AND function could be made with +5, a resistor pull up, (A) an optocoupler (C1), optocoupler (E1), optocoupler (C2), optocoupler (E2) and ground. Point (A) is the logic input. This would make it active low at aprox 1.2 V if they are both triggered at the same time.

What you might be missing is that a diode drops around (0.6 V) and so does the Collector-Emitter junction will drop (0.6V) aproximately for silicon. Schotkey diodes may have a much lower drop (typically (0.2). The drops are approximate. You have to check the datasheet.

I think when I read the phiget datashhet, a low has to less than 1.2 V. If, so some of these methods could be iffy. Two transistors in series add up to 1.2 V.

So, if you want to use one port and AND the result, you might have to use a AND gate.
 
Last edited:
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top