Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

sine/cosine ustepping help

Status
Not open for further replies.

Tracid

Member level 3
Joined
Nov 1, 2006
Messages
57
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,288
Location
Neded, Slovakia
Activity points
1,756
I know its not PIC related but i want to do it with PIC and there are so many talented
people on this forum so i hope somebody can help!
I found this picture on the net.It illustrates the sine-cosine stepper motor microstepping with 1/10 microstep ratio.
The red is sine,the blue is cosine.The picture shows the current states during for four full step long.
If the sign of sin/cos is a ´+´(positive) the current flows from left to right.
If the sign is negative,currrent flows the opposite direction.
So i think its very nice except some things are unclear for me!The numbers there are painted by me using ´Paint´.
I would expect that if cosine is 100percent duty cycle the sine should be 0percent duty cycle(the number 1).
Then i would expect cosine zero when sin is 100percent at points 2,3.
And maximum duty cycle values are always reached,but the zero duty cycle level is never set(see 3).

But the picture shows at 100percent cosine not zero sine but about 10percent.This is what i cant understand!
Anybody can tell me if i am thinking the very wrong way?

And another question:What is the equation for calculating duty cycle values?
I thought it is simple since if i want 1/16 microstepping i need only 4bit resolution and thus 16 different values.
Then i saw some Excel tables showing them using 8bit resolution.But whatever the resolution be like the duty cycle percentages should be equal to all resolutions.
I would expect the sum of sin/cos percentages equal to 100percent,but the tables show the sum more than 100percent.

I would be very thankful if you can help me! I am thinking so long about and i am very confused now but cant figure out.
 

While the value in the interval just after 0 is 1, and the value in the interval just before is -1. Which averages out to 0.
At time 0, the signal is changing the fastest which is why having a value of 0 for a full interval would be a bad approximation.
However it's not the sum of the sine and cosine that should be a constant, it's the sum of the squares. But because these are approximations, so will the sum of the squares also be approximately constant.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top