Pages: [1]   Go Down
Author Topic: Reading Multiple Gates on One I/O Pin  (Read 856 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Full Member
***
Karma: 5
Posts: 240
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I am trying to read when the state of one of 8 photogates goes low by checking one I/O pin, the timing requirement of the system does not allow me to poll 8 pins sequentially.  I would like to be able to set up an interrupt on one pin that would be trigger on a falling edge when any of the 8 gates goes low.

This may be a trivial question and an easy Google if I knew what the name of a device like was, but alas I do not.  Can someone give me digital hand?

Thanks

wade
Logged

UK
Offline Offline
God Member
*****
Karma: 13
Posts: 903
Twitter: @simonmonk2
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm not entirely sure what you are trying to do, I'm guessing use a latching parallel to serial shift register.

You may not need to do that, it is possible to read 8 IO pins on the Arduino simultaneously (well nearly), as long as they are on the same port.

http://www.arduino.cc/en/Reference/PortManipulation
Logged

--
My New Arduino Book: http://www.arduinobook.com

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 308
Posts: 26474
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

An 8-input NAND.
« Last Edit: November 12, 2010, 03:41:26 pm by AWOL » Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

UK
Offline Offline
God Member
*****
Karma: 13
Posts: 903
Twitter: @simonmonk2
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

erm, yes - I see what you mean, I completely missed the point.

http://ecee.colorado.edu/~mcclurel/dm74ls30.pdf
Logged

--
My New Arduino Book: http://www.arduinobook.com

0
Offline Offline
Full Member
***
Karma: 5
Posts: 240
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

AWOL,

The NAND gate was exactly what I was looking for thanks.

wade
Logged

Somewhere in the Sonoran Desert
Offline Offline
Full Member
***
Karma: 1
Posts: 108
"This was not intended to be a factual statement."
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Why use a gate at all.

Use a 'wired or'.

Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17301
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes a diode wired to each device can be wired-ORed to create a single signal.

Lefty
Logged

Pages: [1]   Go Up
Jump to: