Rectangle probe.ngc

More
9 years 7 months ago #90343 by andypugh
Replied by andypugh on topic Rectangle probe.ngc
M110 is in the user-defined M-codes range (M100-M199). When the G-code contains any of those then the system looks for an executable file of the same name, and tries to run it.

You will need to find out what that M110 file was in the original config.

Please Log in or Create an account to join the conversation.

More
9 years 7 months ago #90717 by rbarry1068
Replied by rbarry1068 on topic Rectangle probe.ngc
OK, I found an M110 command in the code repository:
Code:
#!/bin/sh # Clear axis info notifications # use in gcode subroutines and/or connect to pushbutton # M1nn files must exist _before_ starting emc # in the [DISPLAY]PROGRAM_PREFIX # or in a dir specified by [RS274NGC]USER_M_PATH # the pin for axisui.notifications-clear-info is in emc-2.4pre # using an earlier version will print error to stdout halcmd setp axisui.notifications-clear-info 1 sleep .100 ;# requires a sleep that does <1 halcmd setp axisui.notifications-clear-info 0 # if a M1nn command fails and its script exits with nonzero status, # the gcode program exits. So always exit 0, and make sure # the M1nn command prints a message in order to keep on going. exit 0

So then I created an M110 file in linuxcnc/nc_files/examples/, then set it have executable privs for all users. I thought, OK, I've got this fixed now, but NOOOO. Still have the same error when executing rectangle_probe, "unknown m code used: M110" .

What am I missing now??

Please Log in or Create an account to join the conversation.

More
9 years 7 months ago #90744 by rbarry1068
Replied by rbarry1068 on topic Rectangle probe.ngc
I also put a copy of the M110 command file in the same directory as my machine.ini file, still no joy. I noticed that I could set the "wait for start" value in rectangle_probe to 0 and it would at least run, but I did not get any values in the probe_result.txt file, just zeroes.

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #90750 by rbarry1068
Replied by rbarry1068 on topic Rectangle probe.ngc
ArcEye was right!! You MUST have the M110 command file in the directory referenced by the PROGRAM_PREFIX variable of your machine.ini file. I am now probing again.

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #90752 by rbarry1068
Replied by rbarry1068 on topic Rectangle probe.ngc
Weeeeelll, I'm probing, but the rectangle_probe_result.txt file has some strange numbers in it. All the Z values are the same as the X values. I must have something in my .hal file messed up. I looked through the .hal file but couldn't see anything. I also ran the HAL METER app and the Z values seemed OK there. Any ideas?

Please Log in or Create an account to join the conversation.

More
9 years 6 months ago #90753 by dgarrett
Replied by dgarrett on topic Rectangle probe.ngc
You have discovered a typo in the file rectangle_probe.ngc

Thanks for the report.

Patch applied for 2.7:
git.linuxcnc.org/gitweb?p=linuxcnc.git;a...dd32d76161631b3ee6f4

Search rules are used for locating M files, please see:
linuxcnc.org/docs/2.7/html/config/ini-co...ml#_rs274ngc_section

Section 2.4 [RS274NGC]
USER_M_PATH --- defines search rules for finding M files

The default ini setting to use provided mfiles for ngcgui is:
USER_M_PATH = ../../nc_files/ngcgui_lib/mfiles

The sample M110 file is:
git.linuxcnc.org/gitweb?p=linuxcnc.git;a...10;hb=refs/heads/2.7

Please Log in or Create an account to join the conversation.

Time to create page: 0.156 seconds
Powered by Kunena Forum