Hello Guest it is April 28, 2024, 10:13:54 AM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - SwiftyJ

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
211
Mach4 General Discussion / Re: How can I smooth out motion in my LUA script
« on: February 02, 2019, 10:54:05 AM »
How about using M64 and M65 to turn the outputs on and off? I don't know if this will help with the 'smoothness' of the motion but it is a bit tidier.

So your code would end up like this..

Code: [Select]
local inst = mc.mcGetInstance()

local GCode = ""
GCode = GCode .. "G00 G91 Z-2.0\n"
GCode = GCode .. "M64 P0\n" --Output 0 on
GCode = GCode .. "G00 G91 Z-.25\n"
GCode = GCode .. "M65 P0\n" --Output 0 off
GCode = GCode .. "M64 P1\n" --Output 1 on

mc.mcCntlGcodeExecuteWait(inst, GCode)

212
Mach4 General Discussion / Re: teach me
« on: October 15, 2018, 02:54:10 PM »
I’m nowhere near you, but are there certain things you want to add to your machine/want to achieve ?

213
Mach4 General Discussion / Re: mc.mcJogIncStart
« on: October 15, 2018, 02:44:44 PM »
How are you setting the jog increment value?
If you are using mcJogGetInc, then you should be using mcJogSetInc to set the increment value

214
Mach4 General Discussion / Re: coding help
« on: September 30, 2018, 02:41:47 PM »
If you replace your scr.GetProperty and scr.SetProperty commands with the API calls mc.mcCntlGetFRO and mc.mcCntlSetFRO your code will work

215
Mach4 General Discussion / Re: Velocity Units/Minute ?
« on: September 30, 2018, 02:39:31 PM »
The velocity in the machine.ini file is in counts/second I think.

If you take your counts per unit for that motor, divide by 60, and then multiply by the velocity you want, you will get the velocity value in the machine.ini file

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22