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

Gmoccapy - Patch for Combination M61 + G4 #2489 - Version 2 #2841

Draft
wants to merge 1 commit into
base: 2.9
Choose a base branch
from

Conversation

zz912
Copy link
Contributor

@zz912 zz912 commented Jan 8, 2024

This patch ensures that the automatic command G43 is not executed immediately, but when the LCNC is in IDLE mode.

This patch ensures that the automatic command G43 is not executed immediately, but when the LCNC is in IDLE mode.
@zz912 zz912 changed the title Patch for Combination M61 + G4 #2489 - Version 2 Gmoccapy - Patch for Combination M61 + G4 #2489 - Version 2 Jan 8, 2024
@zz912
Copy link
Contributor Author

zz912 commented Jan 8, 2024

I would like to ask @gmoccapy and @hansu to review my patch proposal.

@hansu hansu requested a review from gmoccapy January 9, 2024 21:21
@andypugh
Copy link
Collaborator

The idea as described sounds fine, but I think we need Norbert (@gmoccapy ) to look at the code to be sure it will work without unintended side-effects.

@zz912
Copy link
Contributor Author

zz912 commented Jan 20, 2024

I agree with Andy.
It will be good to wait for Norbert.

@zz912
Copy link
Contributor Author

zz912 commented Mar 3, 2024

I would like to add some more information about what this patch is good for. Currently, Gmoccapy behaves randomly when we want to change the tool with G43 active. Sometimes only a tool change is implemented. Sometimes a tool change is performed and the tool table window is closed.

I made two examples. In both cases I have G43 active and in both cases I change the tool from tool1 to tool10.

set_tool_variant1
set_tool_variant2

@zz912
Copy link
Contributor Author

zz912 commented Mar 23, 2024

@gmoccapy Can we at least add this Pull Request to the master branch? The master branch is still in development and could be tested.

@gmoccapy
Copy link
Collaborator

Please do not add this, I do only know one case where the actual way does not work. I do hope to have time to go on developing the GUI in about one year

@zz912
Copy link
Contributor Author

zz912 commented Mar 31, 2024

@gmoccapy
I was thinking about:
Gmoccapy - Patch for Combination M61 + G4 #2489 - Version 3

Replace MDI commands:

        if "G43" in self.active_gcodes and self.stat.task_mode != linuxcnc.MODE_AUTO:
            self.command.mode(linuxcnc.MODE_MDI)
            self.command.wait_complete()
            self.command.mdi("G43")
            self.command.wait_complete()

By changing the parameters:
'5401-5409' - Tool Offsets for X, Y, Z, A, B, C, U, V & W. Set by G43. Volatile.

There would be no need to deal with problematic MDI mode switching.

Would it be acceptable to you if one of the experienced programmers did it?

I understand that you don't want push PR from an amateur like me. That I'm an amateur is a fact, it's not sarcasm.

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

Successfully merging this pull request may close these issues.

None yet

3 participants