Yea, scaling and all the math made my brain hurt.
First, it helped me to stop thinking of INI file terms like ENCODER_SCALE whenever they are used to set the value of something in HAL. Think about the underlying pins when working on the math, not the arbitrary INI parameter name. I got confused (still do) between all the various 'NNN_SCALE' things in INI and would mix up what was affecting what. Helps when you write them out all in one place:
- encoder.N.scale = [SPINDLE_N] ENCODER_SCALE = 10000
- stepgen.N.position-scale = yada yada yada
So hurdle #1 - spindle and c-axis are in different units. Spindle is in revolutions, c-axis is in degrees. This causes brain hurt.
#2 - as you noticed, spindle scale is a velocity thing, so it's a RPM/RPS formula not steps per degree.
#3 - remember that my spindle drive is internally in velocity mode ONLY, and my stepgen is always in velocity-mode... so I don't switch the stepgen position-scale via M102/103.
If you are switching the drive internally, you will almost certainly need to change the stepgen scale for each drive mode.