Hello Guest it is March 28, 2024, 04:46:26 AM

Author Topic: Motor Tuning entries for a Sunwin Rotary 4th Axis  (Read 1317 times)

0 Members and 1 Guest are viewing this topic.

Motor Tuning entries for a Sunwin Rotary 4th Axis
« on: December 23, 2019, 01:40:12 AM »
I have an Industrial CNC machine successfully running Mach3.  I love it.  I have added a 3rd party 4th Axis which is sold by Sunwin from China.  I use the IndCNC profile for rotary but that company cannot tell me how to set the Motor Tuning for this maverick addition.  The Sunwin 4th Axis gives the following setting information but I can't figure out what numbers to enter in each of the Mach3 Motor Tuning calibration boxes.

--------------------------------------------------------------------------------------------------------------
Sunwin Gearbox Router Rotary: 
Fourth axis pulse equivalent setting:
Basic parameter setting:
Pulse for 1 rotating degree (Pulse for 1 circle of motor shaft*driver subdivision)/circumference.
For example:  two phase motor, 8 subdivision, reduction ratio 20, (200*8*20 = 32000)
     1. Mach3 set by the angle: 360 degrees a circle 32000 / 360 (degrees) = 88.88888888 (pulse).
     2. Mach3 set by graph length or perimeter 3200 / (perimeter 12.6 mm) = 254.777 (pulse).
--------------------------------------------------------------------------------------------------------------

How does this information translate to the Step entry and other options at the bottom of the Motor Tuning Page?
I've tried many options and sometimes get proper movement in X and in Y but, after a few minutes, it starts rotating "out of control". 
The above information seems to be in mm, not inches.  But Mach3 wants Steps per Inch.  And when Sunwin says pulse, how does that translate to Steps per inch?
Help!!

Offline RICH

*
  • *
  •  7,427 7,427
    • View Profile
Re: Motor Tuning entries for a Sunwin Rotary 4th Axis
« Reply #1 on: December 23, 2019, 08:20:06 AM »
There is a Steps Per Unit  calculator located in Members Docs for linear and rotary .
This spread sheet will calculate the required steps per unit for linear and rotary stepper motors.
Imperial and metric calculation are provided for. Pulses per second are also calculated based on miscellaneous inputs.

Here is the link:
https://www.machsupport.com/forum/index.php?topic=16315.0

-------------------------------------------------------------------------------------------------------
The 4th axis or rotary should be defined in degrees and  is used for indexing.
It will be A, B, C axis in motor tuning. Steps per ,are, Steps per  DEGREE. Velocity and  Accel need to determined / to find an appropriate value.
- Ports & Pins / Motor Outputs enables what axis letter is enabled.
-The rotation of movement + or minus , cw/ccw, is defined by mathematical standards and     the Right Hand Rule is good way to remember it. So depending on how the rotary is mounted determines if it's A,b, or C.
- Direction of spindle rotation is the same as the mill, namely, one views from the spindle towards to the chuck in the direction of the axis.
In Config >General Logic Configuration tick the box for the appropriate axis  to make it angular and then Save Settings.  If I recall correctly.....not ticking the box just accounts for what units are used ie; mm or inches .
Note also the following:
The way the rotary rotates to get to a position and what is also shown in the DRO and can be affected by "Rotational"  settings. Config>General Logic Configuration has three Rotational settings you can use.
Rot 360 rollover – if checked the A axis DRO will display from 0 to 360 degrees and then start over at 0.
If not checked the A axis DRO will be additive such that 2 revolutions will display as 720 degrees.
The rollover only works for G91.
Ang Short Rot on G0 – The axis will move in the shortest possible move to a new position. So if at 0 degrees, and you jogged  to 359 deg then it would just rotate  -1 degree.
Rotational Soft Limits – if checked will apply software limit switches to the rotary axis.
-----------------------------------------------------------------------------------------
 For motor tuning you can use the calculator or Caluculate the steps per ( the units are degrees for an angular rotary axis ).
Example Calc:
For my rotary using micro stepping and a 72 gear ratio:
200 steps / rev X 1 rev /360 degrees = .5555 steps / deg X 10 micro steps X 72 gear ratio=400 steps per unit
Note that   1 / steps per  is the theoretical resolution of the rotary. Say it is 400, then 1/400=.15 degrees.
----------------------------------------------------------------------------------------------------------------
 - Stepper controlled 4th axis cannot run continously, it can index, do rotary but not act as  a true spindle. Actually Mach3 can't run any axis continuosly.
 The rotary can be defined as either angular or linear( via motor tuning ), thus, gcode commands can make it rotate  a number of revolutions, or, as linear it will rotate but in terms of a linear move which  relates to the work diameters circumference. Yes, one can command to make a" lot " of  rotations or a  long distance, BUT, as said it does not act like a true spindle.
Merry Christmas,
RICH
Re: Motor Tuning entries for a Sunwin Rotary 4th Axis
« Reply #2 on: December 23, 2019, 09:48:04 AM »
Rich,
Thank you, thank you, thank you.
DJ