non-linear with regards to bits.
Consider just the least signifcant bits at low speed: adding one more
bit doubles the calculated speed.
At high speed, the low order bits are much less significant.
So, consider how accurate you need to be and think about doing the
conversion in ranges. Perhaps you could do some fairly quick linear
interpolation from a look-up table in EEPROM. Or, maybe you don't
even need to interpolate.
As to getting speed from the output pulse width; that just won't work.
As the load on the motor varies, the speed will vary as well
regardless of the applied voltage.
You might want to see what Phillip Malone has done (he used to hang
out here but I haven't heard from him in a long time)
http://philbot.com/software.htm
Phil has done some absolutely
brilliant work with the OOPic.
Richard
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/oopic/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/oopic/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:oopic-digest@yahoogroups.com
mailto:oopic-fullfeatured@yahoogroups.com
<*> To unsubscribe from this group, send an email to:
oopic-unsubscribe@yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
No comments:
Post a Comment