Sorry I don’t understand “controlling each phase of the motor”
I try to make a system for positioning control with accuracy about 10µm so I have to read all the pulses (A and B) so I can’t use overflow .11000rpm is not necessary for a servo motor for controlling an axis it is too high but for a spindle motor it is common and in some cases the position of the spindle motor is important for example when someone wants to make thread in the pipe or masonry screws but it is not the main problem when I try to read the encoder and send command for servo drive the servo pass the position and then AVR move back the servo and it pass the position again and it happen repeatedly or in the other word the motor start to shaking in the purpose position. I think if the controller read the position faster and make the command signal sooner it’ll solve.
--- On Thu, 8/23/12, David Kelly <dkelly@hiwaay.net> wrote:
From: David Kelly <dkelly@hiwaay.net>
Subject: Re: [AVR-Chat] Re: fast controller
To: AVR-Chat@yahoogroups.com
Date: Thursday, August 23, 2012, 2:39 AM
On Aug 22, 2012, at 4:48 PM, Philippe Habib wrote:
> That's 184 RPS, but he said he has 2048 points per rotation. I'm guessing a quadrature encoder that he has to read, determine direction and increment/decrement 374k times per second. I can see why he moved that part to hardware.
He didn't say it was a quadrature encoder. If its a simple 2048 pulses per revolution then use that to drive the clock input to a timer/counter module. A 16 bit timer/counter will overflow 5.7 times per second which should be easy to catch in an overflow interrupt to extend the precision to 32 bits or more.
What the single bit pulse counter is not going to do is detect the direction of rotation.
I'm a little concerned about 2048 pulses per revolution at 11,000 RPM. My question is, "Why? Are you trying to control each phase of the motor?"
--
David Kelly N4HHE, dkelly@HiWAAY.net
============================================================
Whom computers would destroy, they must first drive mad.
[Non-text portions of this message have been removed]Message
Re: [AVR-Chat] Re: fast controller
2012-08-23 by farshid alipour
Attachments
- No local attachments were found for this message.