- Posts: 18
- Thank you received: 0
M66 keeps waiting
- Firehunter
- Topic Author
- Offline
- New Member
-
Less
More
1 year 2 months ago #333058
by Firehunter
M66 keeps waiting was created by Firehunter
I have configured a hydraulic tailstock on a CNC lathe. It has 2 valves (in/out) and 2 proximity sensors (min/max). I want to use M-codes to control the tailstock, but I can't get M66 to work. M64 and M65 do work properly. I've attached the sensor inputs to motion.digital-in-00 and 01. I can see the signals changing low/high in halshow. But when I try to test this functionality with a small G-code file, it keeps waiting on the M66 line.
It keeps waiting on line M66 P1 L4 Q10. Even if I manually turn the sensor on/off, it doesn't do anything. But when I use this line in MDI, it works without problems. When I use MDI I can see the gmoccapy interface "freeze" when I execute this line. It "unfreezes" when the sensor is operated.
Why doesn't my G-code work?
Code:
%
M64 P2 ; turn extend tailstock valve on
M66 P1 L4 Q10 ; wait for max sensor signal to go low
G4 P5 ; wait 5 seconds just for testing purposes
M65 P2 ; turn extend tailstock valve off
M64 P1 ; turn retract tailstock valve on
M66 P0 L3 Q10 ; wait for min sensor signal to go high
M65 P1 ; turn retract tailstock valve off
M30
%
It keeps waiting on line M66 P1 L4 Q10. Even if I manually turn the sensor on/off, it doesn't do anything. But when I use this line in MDI, it works without problems. When I use MDI I can see the gmoccapy interface "freeze" when I execute this line. It "unfreezes" when the sensor is operated.
Why doesn't my G-code work?
Please Log in to join the conversation.
1 year 2 months ago #333069
by andypugh
Replied by andypugh on topic M66 keeps waiting
L3 is correct for this application, but out of interest, does L1 work?
Does the 10 second timeout work?
Which LinuxCNC version?
In halshow are you looking at the motion.digital-in pins? (rather than the IO pins)
Does the 10 second timeout work?
Which LinuxCNC version?
In halshow are you looking at the motion.digital-in pins? (rather than the IO pins)
Please Log in to join the conversation.
- Firehunter
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 18
- Thank you received: 0
1 year 2 months ago #333070
by Firehunter
Replied by Firehunter on topic M66 keeps waiting
The other L-modes also don't work. Timeout doesn't work. Nothing happens after 10 seconds. Yes I'm looking at the digital-in-xx pins. LinuxCNC version on the splash screen is 2.9.0~pre1+git20230208.f1270d6ed7
Please Log in to join the conversation.
1 year 2 months ago #333084
by Benb
Replied by Benb on topic M66 keeps waiting
Since you're observing activity at hal pin “motion.digital-in-xx”, this confirms that the hardware input is functioning correctly. The issue likely lies further downstream—could it be that Gmoccapy is monopolizing this pin?
Please Log in to join the conversation.
1 year 2 months ago #333089
by andypugh
I don't think that anything has changed with M66 since that version (which was a prerelease that found it's way into the Debian archives during their testing phase, expected to be replaced, and then wasn't.
I don't expect it to make a difference to this particular issue but there are other fixed bugs that I would be happier knowing you are not going to see. The current release version (outside Debian) is 2.9.4. You can just download the .deb file and install it from our server:
www.linuxcnc.org/dists/
What Linux are you running? (eg, Debian Bookworm (my first guess)) and on what platform? (PC? Pi? Oher?) we can then point you to the exact package file you need.
Replied by andypugh on topic M66 keeps waiting
I really thought we had a newer version than that on Bookworm, but the package lists suggest otherwise.LinuxCNC version on the splash screen is 2.9.0~pre1+git20230208.f1270d6ed7
I don't think that anything has changed with M66 since that version (which was a prerelease that found it's way into the Debian archives during their testing phase, expected to be replaced, and then wasn't.
I don't expect it to make a difference to this particular issue but there are other fixed bugs that I would be happier knowing you are not going to see. The current release version (outside Debian) is 2.9.4. You can just download the .deb file and install it from our server:
www.linuxcnc.org/dists/
What Linux are you running? (eg, Debian Bookworm (my first guess)) and on what platform? (PC? Pi? Oher?) we can then point you to the exact package file you need.
Please Log in to join the conversation.
1 year 2 months ago #333116
by rodw
You do. Looks like the OP is using the version included in bookworm and has not used the 2.94 ISO
But that's not an issue. Just follow the instructions in the 2.94 docs under getting Linxucnc, section 7.
But also Debian Trixie should be released in the next couple of days. Once that happens an early adopter can do a
sudo apt dist-upgrade
should install Trixie and upgrade to 2.9.4
Replied by rodw on topic M66 keeps waiting
[/quote]I really thought we had a newer version than that on Bookworm, but the package lists suggest otherwise.
You do. Looks like the OP is using the version included in bookworm and has not used the 2.94 ISO
But that's not an issue. Just follow the instructions in the 2.94 docs under getting Linxucnc, section 7.
But also Debian Trixie should be released in the next couple of days. Once that happens an early adopter can do a
sudo apt dist-upgrade
should install Trixie and upgrade to 2.9.4
Please Log in to join the conversation.
- Firehunter
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 18
- Thank you received: 0
1 year 2 months ago #333125
by Firehunter
Replied by Firehunter on topic M66 keeps waiting
Thanks for the replies. I guess updating Linux and LinuxCNC is the only option left. The machine is at an other location, I will try installing the updates when I'm there again.
I made some changes to the gmoccapy interface, added some custom buttons using the Glade editor if I remember correctly. Will these modifications be overwritten when I do the updates?
I made some changes to the gmoccapy interface, added some custom buttons using the Glade editor if I remember correctly. Will these modifications be overwritten when I do the updates?
Please Log in to join the conversation.
1 year 2 months ago #333156
by rodw
Replied by rodw on topic M66 keeps waiting
Te linuxcnc folder is preserved on an upgrade but keep a copy off the pc.
What version of linuxcnc are you using? Versions before 2.8 might need some more work.
I have found its best to build a rough config with stepconf or pncconf, then cut and paste your ini file data into the generated ini file.It only takes an hour or so that way.
What version of linuxcnc are you using? Versions before 2.8 might need some more work.
I have found its best to build a rough config with stepconf or pncconf, then cut and paste your ini file data into the generated ini file.It only takes an hour or so that way.
Please Log in to join the conversation.
1 year 2 months ago #333174
by andypugh
Can you attach your HAL files(s)?
Replied by andypugh on topic M66 keeps waiting
Note that I don't actually expect that to fix this issue.Thanks for the replies. I guess updating Linux and LinuxCNC is the only option left.
Can you attach your HAL files(s)?
Please Log in to join the conversation.
1 year 2 months ago #333189
by PCW
Replied by PCW on topic M66 keeps waiting
The sample code works (standalone) for me,
That is just by manipulating/watching the pins in halshow:
That is just by manipulating/watching the pins in halshow:
Attachment not found
Attachment not found
Please Log in to join the conversation.
Time to create page: 0.099 seconds
