[Emc-users] C programming !
Hi Steve I am interesting in the level of development programming that specify of G code. On the work shop this year was first time tested rigid taping. So what programming language used to specify machine movement that is necessary to perform rigid taping? Thank you aram - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] New Gecko Driver
Stephen: I reset SERVO_PERIOD & TRAJ_PERIOD as you suggested. It seems to have eliminated the warning. I'm up and fully functional. Thank you very much. On Saturday August 18 2007 11:39 am, Stephen Wille Padnos wrote: > > You should be able to set SERVO_PERIOD to 1,000,000 and TRAJ_PERIOD to > 10,000,000 without adverse effects. -- Hugh Currin Klamath Falls, OR USA - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Interactive machining
--- Sven Mueller <[EMAIL PROTECTED]> wrote: > > See the difference? _Many_ people, including me, are certainly > more > comfortable at writing complex code in a more readable language > than > G-Code. And at that, probably also a language easier to > understand at > first glance that TCL (I don't understand your gcode.tcl filter > script, > even though I can read C, C++, Pascal, Ruby, PHP, Perl, lua, > Basic, ... > easily). > > Speaking of the above: lua would probably be a really good choice > if you > want to implement a scripting language inside emc2. > > Regards, > Sven If you want to directly control EMC, why not try Python? Axis, as well as several other utilities, are written in it. It's easy to learn as well. For a simple example, see ( http://cvs.linuxcnc.org/cvs/emc2/src/emc/usr_intf/axis/scripts/mdi.py?rev=HEAD ) Mark - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] gcode output for xfig updated
Hi! transfig and ngc2fig does not install on my ubuntu machine. It complaines about a missing dependancy named libc6. Any suggestions? //Simon Till Harbaum / Lists skrev: > Hi, > > it's http://www.harbaum.org/till/cnc > > Am Donnerstag 19 Juli 2007 schrieb Mark Wendt (Contractor): > >> Till, >> >> Can you post the URL again? >> >> Thanks, >> Mark >> >> At 02:26 AM 7/19/2007, you wrote: >> >>> If you want to leave the surrealistic mode just uncheck the "Dali" >>> checkbox. After that most realistic projects should work. >>> >>> Till >>> >>> - original Nachricht >>> >>> Betreff: Re: [Emc-users] gcode output for xfig updated >>> Gesendet: Mi, 18. Jul 2007 >>> Von: [EMAIL PROTECTED] >>> >>> GCODE for XFIG? Amazing. I havent used Xfig for about 8 years now, but can you giove me some information about what kind of realistic cnc projects can be done with Xfig? I basically used xfig long ago to create eps drawings for publications. Lrv Till Harbaum / Lists wrote: > Hi, > > someone who wants to stay anonymous donated new font support > code the gcode enabled xfig. Thus the downloads are enabled again. > > Till > - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Interactive machining
So there is some interest in a programming language. I use Mach and do some VB code with that, so here are the essential elements that Mach has added to VB.. Code (G01 x1) will send the code to Mach for immediate move. A loop like: while IsMoving wend will wait until no gcode is being processed. There are a series of SetDRO, GetDRO that can set or get any of the internal values from Mach- not just the X,Y position but any parameter held within the system, like feed rate, motor tuning values, etc Likewise a SetLED and Get LED for al the various state bits. With these commands we can write login in VB that can interact with the user and run any movement the machine can do. It ought not be to hard to link Perl or TCL or any scripting language into EMC. ron ginger - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] New Gecko Driver
Hugh Currin wrote: >EMC List: > >I've just upgraded my drivers to Gecko G202s. All seems to work well and I'm >trying to fine tune EMC. > >These microstepping drives and higher rapids push the 1GHz computer much more >than the original half step drivers. I was getting "joint 0 following error". >After some experimentation I decreased the Base Task Period, Servo Task >Period, and Trajectory Planning Period. I kept the ratio between these the >same. > > It's not necessary to keep the ratio the same. The BASE_PERIOD needs to be fast enough to do step generation at the rate you need. The SERVO_PERIOD needs to be fast enough to make the shapes you want within the following error you specify, and is usually set to 1 ms. This is the rate at which new velocity commands are generated for the step generator. >Using 30,000 / 600,000 / 6,000,000 for these periods I was able to get 51 >in/min before a following error. Using 20,000 / 400,000 / 4,000,000 I started >losing steps around 75 in/min. This seems to solve the problem with >the "joint 0 following error" problem and I'm running into driver/motor >limits. Reducing the periods further doesn't seem to do much. This is fine >and I've set rapids to 60 in/min which is fast enough to scare me real good. > > You should be able to set SERVO_PERIOD to 1,000,000 and TRAJ_PERIOD to 10,000,000 without adverse effects. >However, I now seem to get an "Unexpected realtime delay, check dmesg for >details" warning. Minimal testing seems to show this error occurs once, soon >after EMC is started. After it seems to be fine. I checked the dmesg file and >can find nothing related. (I saved dmesg, ran EMC getting the warning, then >compared the old and new dmesg files finding no change) Decreasing the >Periods seems to promote this warning sooner after starting EMC. > > Yep - the error is printed from the TRAJ thread, I think. It measures the actual time between executions, and if it's more than 1.1 times the expected time (or something around there), the error is printed. Since you decreased the period, you also decreased the margin around it by a similar ratio. Note that EMC1 in the early days would report that error if the delay was soemthing like 10x expected, so this warning has a much tighter tolerance. I think the warnings only print once per run of EMC2, so that would be why you only see one copy in dmesg. >What would "Unexpected realtime delay" indicate and what should I adjust to >get rid of it? > > You should look at the actual numbers - if it's telling you that the actual time was 600,000 instead of 400,000, that's probably not an issue. If it's telling you that the time is 300,000,000 instead of 400,000, that may be a problem. You can correct it by setting TRAJ_PERIOD and SERVO_PERIOD back to 10 ms and 1 ms - I don't think that will hurt anything in your setup, since your rapid speeds aren't too high, and you aren't running analog servos. - Steve >I'm not sure what's helpful, but I'm using: > GPL Version 2 (2006) (EMC2 2.0.5) > TkEmc > *.ini modified from stepper_inch.ini > TASK = milltask > PARAMETER_FILE = stepper.var > EMCMOT = motmod > HALFILE = core_stepper.hal / standard_pinout.hal > >Thank you for any help. > > - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
[Emc-users] New Gecko Driver
EMC List: I've just upgraded my drivers to Gecko G202s. All seems to work well and I'm trying to fine tune EMC. These microstepping drives and higher rapids push the 1GHz computer much more than the original half step drivers. I was getting "joint 0 following error". After some experimentation I decreased the Base Task Period, Servo Task Period, and Trajectory Planning Period. I kept the ratio between these the same. Using 30,000 / 600,000 / 6,000,000 for these periods I was able to get 51 in/min before a following error. Using 20,000 / 400,000 / 4,000,000 I started losing steps around 75 in/min. This seems to solve the problem with the "joint 0 following error" problem and I'm running into driver/motor limits. Reducing the periods further doesn't seem to do much. This is fine and I've set rapids to 60 in/min which is fast enough to scare me real good. However, I now seem to get an "Unexpected realtime delay, check dmesg for details" warning. Minimal testing seems to show this error occurs once, soon after EMC is started. After it seems to be fine. I checked the dmesg file and can find nothing related. (I saved dmesg, ran EMC getting the warning, then compared the old and new dmesg files finding no change) Decreasing the Periods seems to promote this warning sooner after starting EMC. What would "Unexpected realtime delay" indicate and what should I adjust to get rid of it? I'm not sure what's helpful, but I'm using: GPL Version 2 (2006) (EMC2 2.0.5) TkEmc *.ini modified from stepper_inch.ini TASK = milltask PARAMETER_FILE = stepper.var EMCMOT = motmod HALFILE = core_stepper.hal / standard_pinout.hal Thank you for any help. -- Hugh Currin Klamath Falls, OR USA - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
[Emc-users] Drive Upgrade
DIY-CNC, EMC, Gecko: I just finished my driver upgrade, enough to know it's working. I still need to optimize the EMC configuration, but it works great so far. I'm using Gecko G202 drivers, a PMDX-131 breakout board, built up 70V power supply, and EMC2. All suppliers were great. I ordered from PMDX, Gecko, AnTek and Mourser. The orders were placed and came without a hitch, all very promptly. Service from PMDX was particularly helpful. They helped before the sale and answered all my email inquiries after sale within 12 hours. Great service. The PMDX-131 was also great to use. It saved a considerable amount of hand wiring, a big time saver. If you're doing something similar I can recommend these suppliers and products. Thanks. -- Hugh Currin Klamath Falls, OR USA - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] C programming ?
Hi Aram EMC2 uses two of the variants: C and C++. C# (C-Sharp) is a relatively new variant developed by Microsoft just a few years ago. It's mostly useful for .Net programming, which we thankfully don't have to deal with for EMC2. If you're interested in working on low-level parts of the code, then you should start with C. All of the real-time code and anything related to HAL are written in C. If you want to work on the interpreter or NML, then you'll need C++. Note: the C++ isn't exactly pretty, so I wouldn't try to use the NML library as example code for learning purposes. There are lots of languages used for the GUIs: TCL/Tk, python, C, C++ ... Any or all of those would be good to learn as well. Hope this helps - Steve [EMAIL PROTECTED] wrote: >Hi >I want to learn about about programming part of EMC2 >So I decided to buy C programming book and see what is inside and same >time take college class C programming. >I found out that there are 3 type of C languages- C from nisi , C >sharp and C++. > > >My question is what type of C language used for EMC2? >It is confusing >Thank you, >aram > - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
[Emc-users] C programming ?
Hi I want to learn about about programming part of EMC2 So I decided to buy C programming book and see what is inside and same time take college class C programming. I found out that there are 3 type of C languages- C from nisi , C sharp and C++. My question is what type of C language used for EMC2? It is confusing Thank you, aram - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Interactive machining
I tried and used the TCL preprocessor and I think it does the same things as O-Word, but it has far more possibilities and it is really more readable than O-Word, but O-word is read internally by the interpreter while with the TCL preprocessor and the filter for .gcl files a complete G-code program will be sent to EMC2. I think that the point is not to have a command to move directly the machine, (like $emc->move({ X => 0})) because the same result can be achieved using the common G0 or G1 g-code commands in the preprocessor, I think that the real point is, as told also by Sven, to have a way to get feedback from emc2. The ability to get a feedback from EMC2 (or HAL) while working, would permit the interactive machining as requested by Ron. for example: if (hal.pin.0 == true) G0 X20 else if (hal.pin.1 == true) G0 Z20 ecc.ecc. Regards Manfredi My websites: www.m24-pro.com www.emc2cnc.altervista.org >From: Sven Mueller <[EMAIL PROTECTED]> >Reply-To: "Enhanced Machine Controller (EMC)" > >To: "Enhanced Machine Controller (EMC)" >Subject: Re: [Emc-users] Interactive machining >Date: Sat, 18 Aug 2007 05:47:53 +0200 > >Jeff Epler schrieb: > > AXIS can automatically execute a filter program when loading a > > machinable file. You can also use the NML messages for issuing "MDI" > > commands to feed your program in line-by-line. (I just verified that, > > at least in the development version of emc 2, this doesn't kill blending > > altogether, though it's likely that blending degrades more quickly when > > fed by MDI than by file) > > > > Personally, I lean towards using filters because then I benefit from the > > preview plot. > > > > Using tcl as a gcode preprocessor: http://axis.unpy.net/01167315565 > > > > To make ".gcl" files openable in axis, put this in your inifile: > > PROGRAM_EXTENSION .gcl TCL-preprocessed gcode > > gcl = /path/to/gcode.tcl > > and make gcode.tcl executable > >While these preprocessors look really useful, they don't support what >Ron thinks of, which would be a programming language which is able to >feed commands to emc2 as well as get feedback from emc2. Assuming a perl >binding, this could mean > >=my >$emc = new CNC::EMC2; >$emc->move({ X => 0, Y => 0, Z => 10 }); >$emc->straight_probe( { Z => 0 } ); >if ($emc->probe_tripped) { > printf("%d %d %d\n",$emc->trip_x,$emc->trip_y,$emc->trip_z); >} else { > # do something else >} >my $dialog=new Dialog; ># do whatever is needed to open a dialog which allows jogging ># of all axes as well as direct entering of target positions, ># to select {max,min}[xyz] > >surface_scan($minx,$miny,$minz,$maxx,$maxy,$maxz); >... >= > >See the difference? _Many_ people, including me, are certainly more >comfortable at writing complex code in a more readable language than >G-Code. And at that, probably also a language easier to understand at >first glance that TCL (I don't understand your gcode.tcl filter script, >even though I can read C, C++, Pascal, Ruby, PHP, Perl, lua, Basic, ... >easily). > >Speaking of the above: lua would probably be a really good choice if you >want to implement a scripting language inside emc2. > >Regards, >Sven > >- >This SF.net email is sponsored by: Splunk Inc. >Still grepping through log files to find problems? Stop. >Now Search log events and configuration files using AJAX and a browser. >Download your FREE copy of Splunk now >> http://get.splunk.com/ >___ >Emc-users mailing list >Emc-users@lists.sourceforge.net >https://lists.sourceforge.net/lists/listinfo/emc-users _ Don't just search. Find. Check out the new MSN Search! http://search.msn.com/ - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users