Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: razer00 on March 27, 2014, 11:21:25 AM

Title: How can I change analog output continuously from a location to another?
Post by: razer00 on March 27, 2014, 11:21:25 AM
Hi, guys,

I'd like to make the controller output digital or analog signal at each location to control a part of my device.
I could change the head speed by putting F code at the end of each coordinate.

X10.0 Y10.0 F20
X11.0 Y10.0 F20.5
...

However, I need to output at least one analog signal differently at each location.
Can I do as following to use the spindle signal?

M3 S10
X10.0 Y10.0 F20
M3 S15
X11.0 Y10.0 F20.5
...

In this case, the problem is that I should divide the path too finely and the voltage changes step-wise rather than gradually.

Isn't there any way to change the analog output voltage gradually by interpolating two values assigned at two different positions?
Thank you for your advice in advance.
Title: Re: How can I change analog output continuously from a location to another?
Post by: KTM on March 28, 2014, 06:11:51 AM
You could possibly use a timer in the M3 macro to increment the feedrate override.