Pages: 1 [2]   Go Down
Author Topic: need help understanding code  (Read 1124 times)
0 Members and 1 Guest are viewing this topic.
Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 309
Posts: 26496
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

What have you got connected to pin 2? i.e how are you triggering this thing?
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.

Offline Offline
Newbie
*
Karma: 0
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

What have you got connected to pin 2? i.e how are you triggering this thing?

photo/light gate.   When a fin blocks it, it sends a high logic to arduino.
Logged

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

And does it work? are you seeing interrupts from it?
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.

Offline Offline
Newbie
*
Karma: 0
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes it works, I wrote my own code to give me the RPM based on the output from this.

Also used pwm to change the speed for the motor and this was confirmed by the rpm read.


So can anybody help me understand this code?
« Last Edit: March 05, 2013, 08:21:59 am by Caadi » Logged

Pages: 1 [2]   Go Up
Jump to: