// Set the acceleration of the generator gvarset (8131, 100000); timer = 30; do {timer -;} while (timer> 0); // Delay for 30ms // Convert reference spindle speed to frequency. // The value of the coefficient k is selected in such a way as to convert // 12-bit spindle speed to generator frequency k = 123456; freq = eparam * k; // Calculate the raw value of the generator frequency by using the multiplier k // Send the generator frequency value gvarset (8130, freq); timer = 30; do {timer -;} while (timer> 0); // Delay for 30ms exit (99); // normal exit