Hello Guest it is July 01, 2022, 07:52:48 AM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - MacCrazyman

Pages: 1
Mach4 General Discussion / using loops inside macros
« on: February 10, 2020, 02:39:53 PM »
Good day people,

I'm doing some custom macros for my cnc machine, everything is working fine but I'm having a problem with "FOR" loops when hitting the "STOP" button.
The thing is I have an M73 file wich performs a pattern for punching, in sumary it looks something like this:

for Y=1,Y lines,1
    moves to the next Y coords.
        for X=1, X columns,1
           moves to the next X coords
           external function for punching

the problem here is when I need to press the stop button for any reason, the movement stops but the machine continues punching until the end of FOR loops.
I tried using a BREAK statement when the signal Gcode_Running turns off but nothing happens.
Any idea of how to properly break the loops inside a macro?


General Mach Discussion / Punch press cylinder as Z axis
« on: January 23, 2020, 10:29:50 AM »
Good day for everyone,

I'm working in a retrofit project for a CNC punch press machine, I replaced the old electronic Palvision control system by a CSMIO/IP-S board, so my next step is to control the proportional valve for the 20 ton hydraulic cylinder. The speed of the proportional cylinder is controlled by a +/- 10V analog signal and it provides a 0-10V feedback signal to know the position.
So I was thinking in using a macro that would be called to perform every punch, but thinking further in the Gcode programming, it would be very useful to use the Canned cycles G81 to make programming easier as it only requires X and Y coordinates per line for machine to moves and "drill" (in case of a mill), and here comes the question, is there any way a script can recognize if G81 is activated and perform a punch in every line? or should I make an script to "link" the internal parameters of speed and position of Z axis to control the analog signal of the Ram?

I would appreciate if someone have a clue of how to perform this action.

Best regards.

Mach4 General Discussion / Using macros in mach4
« on: July 26, 2019, 11:27:23 AM »
Hello everyone,

I have used mach4 and mach3 to make some CNC routers for wood, now I'm working in a retrofit project for a NISSHIMBO puch press machine, I'm going to replace all the servomotors, computer and the old control card, the thing is this machine have some customized Gcodes used to make some routines, and my customer asked me to have the same Gcode functions in the new system. As mach4 does not have such customized Gcodes, I want to know if there is any way to program or modify these Gcodes, or how can I use macros to simulate these routines.

Best regards.

Pages: 1