PnCconf Mesa 7i96s PWM speed control OUTPUT_SCALE

More
12 Sep 2025 00:03 - 12 Sep 2025 00:05 #334849 by rhscdn
I'm setting up my machine and 7i96s using PnCconf and have had some issues with the spindle speed control. My VFD expects an analog 0-5v signal for speed control, i.e. 0v stopped, 5v 18000 RPM. It is open-loop, no spindle encoders. The motor has 2 poles and the drive frequency at 18000 RPM is 300 Hz. When I generate my .ini and .hal files with PnCconf I get the following in my .ini file.
[SPINDLE_0]
P = 0.0
I = 0.0
D = 0.0
FF0 = 1.0
FF1 = 0.0
FF2 = 0.0
BIAS = 0.0
DEADBAND = 0.0
MAX_OUTPUT = 18000.0
OUTPUT_SCALE = 36000
OUTPUT_MIN_LIMIT = 0
OUTPUT_MAX_LIMIT = 18000

With these settings, when I specify a speed of 18000 RPM (M3 S18000), I'm seeing less than 200 Hz on the VFD display and the spindle seems slower than I expect. Looking through the forums, I see most examples have OUTPUT_SCALE=MAX_OUTPUT. Sure enough, when I change the .ini file and set OUTPUT_SCALE = 18000, and command the spindle with M3 S18000 I get 300 Hz on the VFD display and a higher speed at the spindle. Can anyone explain what is going on here? Have I done something foolish? Any ideas on why OUTPUT_SCALE is configured as 36000 in PnCconf?
Last edit: 12 Sep 2025 00:05 by rhscdn. Reason: formatting

Please Log in or Create an account to join the conversation.

More
12 Sep 2025 00:22 #334851 by PCW
Its because pncconf assumes that the PWM full scale is always 10V so if you specify 5V
Is sets the scaling so that you would get 5V (1/2 of full scale scale) at 18000 RPM.

Just leave the "analog Max Voltage" at its default 10V
The following user(s) said Thank You: rhscdn

Please Log in or Create an account to join the conversation.

More
12 Sep 2025 00:54 - 12 Sep 2025 00:55 #334853 by rhscdn
Thanks PCW! The quick reply saved me much head scratching. I will admit that I find this area of the setup a little confusing. Isn't the Mesa 'Spindle Out' voltage fully defined by the input Spindle+ and Spindle- values? Given a potentiometer wiper can never have a voltage higher than its input, what is the need for specifying the 'analog Max Voltage' at all?
Last edit: 12 Sep 2025 00:55 by rhscdn.

Please Log in or Create an account to join the conversation.

More
12 Sep 2025 01:03 #334854 by PCW
Yes, but the pncconf spindle setup also works with other devices with fixed 10V or +-10V  full scale
(7I77,7I76,7I83 etc)

It really should have an additional field for potentiometer type outputs based on the card type
Maybe "Full Scale Analog Output" and "Voltage For Maximum RPM" or some such
The following user(s) said Thank You: rhscdn

Please Log in or Create an account to join the conversation.

Moderators: PCWjmelson
Time to create page: 0.099 seconds
Powered by Kunena Forum