To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 1649
1648  |  1650
Subject: 
Re: ROM stuff: Better than PWM
Newsgroups: 
lugnet.robotics
Date: 
Sat, 19 Dec 1998 09:05:34 GMT
Original-From: 
Ben Laurie <ben@algroup.co.=spamless=uk>
Viewed: 
1053 times
  
Kekoa Proudfoot wrote:
every 1/1000th sec:
    count += p
    if (count >= n)
        turn motor on
        count -= n
    else
        turn motor off

That's it.

I'm sure this algorithm has been thought of before; I got the idea from
Bresenham's line drawing algorithm and from the Floyd-Steinberg error
diffusion dithering algorithm, but I believe this algorithm is a typical
one used in one-bit D/A converters.

Funny - I was thinking of doing exactly the same thing - and also basing
it on Bresenham. I've always wondered about 1-bit D/A, but if you
actually read the docco it is wrapped up in so much weird signal theory
it is very hard to understand (at least the ones I've read).

Cheers,

Ben.

--
Ben Laurie            |Phone: +44 (181) 735 0686| Apache Group member
Freelance Consultant  |Fax:   +44 (181) 735 0689|http://www.apache.org/
and Technical Director|Email: ben@algroup.co.uk |
A.L. Digital Ltd,     |Apache-SSL author     http://www.apache-ssl.org/
London, England.      |"Apache: TDG" http://www.ora.com/catalog/apache/



Message is in Reply To:
  ROM stuff: Better than PWM
 
So I was thinking about writing a motor driver that is better than what is in the ROM already. Here's the problem: You have a function called once every 1/1000th of a second. You want to allow n speeds of the motor at minimal cost in lookup tables. (...) (26 years ago, 19-Dec-98, to lugnet.robotics)

3 Messages in This Thread:


Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR