Handling G30 in KMotionCNC and Probe signal?

Moderators: TomKerekes, dynomotion

Gerad
Posts: 6
Joined: Thu Feb 27, 2020 4:29 pm
Location: Austria

Re: Handling G30 in KMotionCNC and Probe signal?

Post by Gerad » Sat Dec 26, 2020 9:53 pm

Hi Tom

I try to get the old milling machine to work.
Is a portal machine with 2 X axis.
Can move with commands via console moverel0=100 for example,
also movement with cursor keys out of MACH3 Schmidtscreen ist ok.
But if I use MIDI interface: G0 X100 only CH0 moved and Ch3 (slave from 0) dont move.
What could be the reason for this?

BR
Gerad

User avatar
TomKerekes
Posts: 2677
Joined: Mon Dec 04, 2017 1:49 am

Re: Handling G30 in KMotionCNC and Probe signal?

Post by TomKerekes » Sat Dec 26, 2020 10:26 pm

Hi Gerad,

Make sure any slave is not defined in DefineCoordSystem().
Regards,

Tom Kerekes
Dynomotion, Inc.

Gerad
Posts: 6
Joined: Thu Feb 27, 2020 4:29 pm
Location: Austria

Re: Handling G30 in KMotionCNC and Probe signal?

Post by Gerad » Sun Dec 27, 2020 11:02 am

Hi Tom

I have tried to remove the line with „DefineCoordSystem(0,1,2,3)“ in init.c
but problem is still here.
If I changed to DefineCoordSystem(0,1,2) I got a compiler error.
What means this command?
With cursor keys X master and x slave moves fine, same with input from console moverel0=100
But G Code Commando with MDI G0 X100 -> only master X axis moved.
Same if I push a button from the screen, for example „Park Position“ or some similar
Have tried to activate Slave Axis in MACH3 also same.

BR

Gerard

Moray
Posts: 288
Joined: Thu Apr 26, 2018 10:16 pm

Re: Handling G30 in KMotionCNC and Probe signal?

Post by Moray » Sun Dec 27, 2020 12:00 pm

DefineCoordSystem, is what tells the interpreter what channels to output motion.
It requires channels XYZA to be declared. Any channels you're not using, set to -1.

What I suspect you need to use is DefineCoordSystem(0,1,2,-1), assuming X is on channel 0, Y channel 1, and Z channel 2.

By setting A axis to your slaved channel, that overrides the slaving, so only the master channel moves.

Gerad
Posts: 6
Joined: Thu Feb 27, 2020 4:29 pm
Location: Austria

Re: Handling G30 in KMotionCNC and Probe signal?

Post by Gerad » Sun Dec 27, 2020 10:07 pm

Hi Moray

Thanks for your help, now everything works fine !!!

Best Regards

Gerad

Post Reply