Diez B. Roggisch wrote: >John Thornton schrieb: > > >>If you add the extensions to the [FILTER] section of the ini file they will >>show up in >>the file open dialog box. >> >>http://www.linuxcnc.org/docview/html//config_ini_config.html#sub:[FILTER]-Section >> >> > >I didn't manage to configure any filters. But I will try again, thanks. > > > >>If configured you can use M5 to stop your spindle... >> >>http://www.linuxcnc.org/docview/html//gcode_main.html#sub:M3,-M4,-M5: >> >>You can also use M62-65 to control other outputs... >> >>http://www.linuxcnc.org/docview/html//gcode_main.html#sec:M62-to-M65: >> >>I think I spend too much time reading the manuals :) >> >> > > >Is there a way to hook into the M*-commands? Or is that toggling some >pins on the parport? > >This won't help much, as the milling machine itself doesn't support >this. We could try & wire something together, but then the problem would >be that you somehow need to turn the power *on* first. But that's a >hen-egg-problem: axis only runs when the milling machine is turned on. >And I don't want to only turn on and off the splindle, but the whole >system, including vacuum table & controller. > >Or do I miss something here? > >Another thing I'd like to do is to send an email so that I know the >machine is finished, even if I'm not in my office. > > The M-codes from M101-M199 are "custom M-codes". When the interpreter encounters one, it looks for a file named the same as the code, for example M101, and executes it. That file should be in the nc_files dir specified in your ini file. So you could make M101 be a bash script, python, perl, compiled code - whatever you want.
If you can write a script to send the right command to the power strip to power off the vac table and such, then you can make that an M code. Similarly for email - you could have a script that sends an email. A couple of caveats though - the scripts get two parameters, an integer and a float (I think), and they can't return a success/failure code to EMC - it's just assumed that the command has completed "successfully" when control is returned to EMC. - Steve ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Emc-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-users
