Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

M62&63 causing pause in toolpath exectution #382

Open
DDanielMK opened this issue Jan 10, 2025 · 1 comment
Open

M62&63 causing pause in toolpath exectution #382

DDanielMK opened this issue Jan 10, 2025 · 1 comment

Comments

@DDanielMK
Copy link

Hi there

I have successfully set up Mega-5X on a 5-axis 3D printing setup, and I am using the M62 and M63 to toggle the states of a number of relays. I guess this is to be expected, but whenever I use M62 or M63, there is a brief pause in the motion of the axes while the relays are switched. This isn't a major issue as the axes are moving quite slowly, but it would be nice if the M commands could be executed without the axes having to stop. I am fairly sure that I wasn't having these delays when I was using M42 on Marlin to do the same thing on a 3-axis setup.

I am not very knowledgeable when it comes to what is happening in the registers etc, but if there is a way to get rid of the delay that would be great.

Thanks :)

D

@fra589
Copy link
Owner

fra589 commented Jan 10, 2025

Hi @DDanielMK,

The management of the digital output features of grbl-Mega-5X uses the same standard as LinuxCNC.
http://linuxcnc.org/docs/stable/html/gcode/m-code.html#mcode:m62-m65
The M62 and M63 commands are synchronized with the movement. This means that grbl-Mega-5X waits for the end of the current buffered movement (end of movements + deceleration + stop) before changing the output state of the pin, then it resumes the rest of the movements (acceleration then stabilization of the speed).
The brief pause that you observe in the movement is therefore normal.
The M64 and M65 commands (turn on/off digital output immediately) work independently of the movement and have no impact on it.
But be careful, when using M64 and M65, the digital outputs change state immediately, without taking into account the upcoming movements that are already in the buffer.

I don't know enough about Marlin to know if the M42 command is synchronized or not.

@++;
Gauthier.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants