- Joined
- Dec 18, 2019
- Messages
- 7,318
Nice threads!
Your tables for N and D will have to be regenerated or modified. Your screw pushes the carriage faster than mine. My lathe has a 12 TPI lead screw, yours is 8 TPI. So we need to turn your screw slower than I would turn mine.
For a 20 TPI thread, I need to step the motor 15 ticks, for every 128 encoder pulses.
On your lathe to get 20 TPI, the motor must be stepped 10 ticks for every 128 encoder pulses, or basically N needs to be 1.5 times smaller.
Of course N needs to be an integer, but the ratio N/D needs to be 0.66666 (1/1.5 or 2/3) the ratio that runs on my lathe.
Due to the differing lead screws (with the current tables) you will not cut the same threads as I would at 1:1 final stepper ratio. That is the explanation.
That's fixable! I can generate a custom build, but I really should have the sw calculate it for you. Modifying the table by hand is error prone, especially when there's 4 tables and everyone may have a different lead screw. Currently I calculate this offline using a python script. Need to convert that to C. For the moment, I can do a hack, but there have to be a lot of tests and checks in the real code to make sure 1) the ratios are correct and 2) that N and D remain integers.
Your tables for N and D will have to be regenerated or modified. Your screw pushes the carriage faster than mine. My lathe has a 12 TPI lead screw, yours is 8 TPI. So we need to turn your screw slower than I would turn mine.
For a 20 TPI thread, I need to step the motor 15 ticks, for every 128 encoder pulses.
On your lathe to get 20 TPI, the motor must be stepped 10 ticks for every 128 encoder pulses, or basically N needs to be 1.5 times smaller.
Of course N needs to be an integer, but the ratio N/D needs to be 0.66666 (1/1.5 or 2/3) the ratio that runs on my lathe.
Due to the differing lead screws (with the current tables) you will not cut the same threads as I would at 1:1 final stepper ratio. That is the explanation.
That's fixable! I can generate a custom build, but I really should have the sw calculate it for you. Modifying the table by hand is error prone, especially when there's 4 tables and everyone may have a different lead screw. Currently I calculate this offline using a python script. Need to convert that to C. For the moment, I can do a hack, but there have to be a lot of tests and checks in the real code to make sure 1) the ratios are correct and 2) that N and D remain integers.