|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#46
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
i have it hooked up and i had just hooked it up to the solenoid breakout card. but not there is no power to the photosensor
|
|
#47
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
NOw i got it to work at 24 volts. Now i need the code to work
|
|
#48
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
I am getting a reeding now of Rpms between 500 to about 3000. But still my motor keeps going very fast
|
|
#49
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
Quote:
With a 20ms execution rate using counts to read a one-per-rev sensor on a wheel spinning at 2000 rpm, you're going to see a *lot* of noise. Last edited by Ether : 11-02-2013 at 17:19. |
|
#50
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
The value (10) you put underneath the indicator, what does that number mean exactly.
|
|
#51
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
here
|
|
#52
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
Quote:
@ Bunniy: Many folks don't use the threaded display and can't tell who you are talking to if you just use the pronoun "you". |
|
#53
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
I don't think the "counts" method is going to work with a one-per-rev sensor. I think you need to use the "period" method that Mark posted.
|
|
#54
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
@ Ether: Thank you, im new to chief delphi so i dont know this
|
|
#55
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
We all started out new and had to learn. Try clicking the "quote" icon instead of "quick reply" and it will quote the message to which you are replying.
That will provide sufficient context. |
|
#56
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
thank you
|
|
#57
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
Quote:
|
|
#58
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
Why would using the period method be better?
|
|
#59
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
Quote:
|
|
#60
|
||||
|
||||
|
Re: Photosensor as encoder for bang bang.
To understand why, you have to do the math.
Using the "period" method, like Mark posted earlier in this thread, the FPGA samples the sensor at 153KHz and records the elapsed time between pulses with a 1MHz clock. For a one-per-rev sensor (like yours) on a wheel spinning at, say, 2000 rpm, that gives you a very accurate and hi resolution signal. See attachment. The "count" method is very accurate for high speeds with high counts-per-rev sensors like a 360CPR encoder. But for a one-per-rev sensor like yours, it's not very good. At a wheel speed of 2000 rpm and sampling every 20ms, you don't get enough counts to accurately determine what the speed is. Sometimes you'll get 1 count, and sometimes you'll get *no* counts. You can't convert that into a useable speed signal. See attachment. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|