Hello Guest it is April 29, 2024, 05:45:49 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.


Messages - Fledermaus

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 »
201
A variable declared in the screen load script has global scope. This means that it is visible to code in all other scripts and modules of Mach4. Its value persists throughout the Mach4 session.

Don't worry too much about the above detail for now. You will get to know it in time. All you have to do is include a variable declaration similar to the one shown at the start of the screen load script. You will see various similar declarations at the beginning of the script, so just add one of your own to that block. The variable name isn't important: use whatever you like providing it is unique.

Hope this helps.

Allan

202
Here is the outline of code I use to generate an output pulse based on the cycle time of the PLC scriptrunning at 20Hz. I use this pulse to reset my VFD. You may be able to do something similar.

--Declare global counter in Screen Load script:
count= 0

--Include this where you set your output high
-- Initialise timer to begin count of 600x50ms
 count  = 600 

--Add the following code to PLC Script
if (count > 0) then
    -- count down to 0
    count = count - 1;
end
if count <= 0) then
    --set your output low after 30 seconds
    hSig = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUTxx);
    rc = mc.mcSignalSetState(hSig, 0);
end

-- add this where you ordinarily reset your output
count = 0

I'm not claiming that this is optimum, but it works for me.

Allan

203
Steve

Many thanks for the insight into core operation. I tried your suggestion and created a toolpath about the size of your thumbnail in a corner of the tab that contains the Open File button. This worked fine when the TP was visible, but making it invisible did not prove successful: my original issue returned.

Spurred on by your ideas I reduced the toolpath to a 1x1 pixel and set its background colour to match the blue tab background I was using (I like plenty of colour!). This worked a treat: the TP was effectively invisible but allowed core operations to proceed correctly, executing macros as needed.

Allan

204
I've never had freezing fortunately. In fact Mach4 seems very stable.

The only time I've had missing toolpaths is when there has been an error in the gcode file. I seem to remember that this occurred recently an I traced it to mismatched parentheses in a comment line. I had just assumed that nested comments would have been OK, But no! (No nesting of brackets is permitted).

Pressing the Regenerate Toolpath button normally corrects the display after changing the Axis zero point.

Allan

205
I've been mystified for some time as to why Mach4 occasionally fails to pause and call my M6 macro when a tool is selected within a gcode program. At other times Mach behaves as expected, even using the same gcode file.

I eventually tracked this down to the toolpath display. My (customized) screen set ordinarily hides the toolpath displays on background tabs. When no toolpath is visible, the pause for toolchange and the M6 macro call are skipped. If any of the toolpaths are displayed, even briefly, prior to gcode execution, all works as expected: the program pauses and M6 is called. This is the case both for the simulator and my CSMIO/IP-A controller.

My personal feeling is that this behaviour is a bug: the user should be free to rearrange a screen set without disrupting core operations. Has anyone else seen this behaviour and found a solution other than always having a toolpath on display?

I haven't noticed any effect other than skipping of the tool change action: the gcode otherwise seens to run normally.

Allan

206
Ron

We seem to have differing expectations. I assumed that inside, groove, and outside were essentially the same and merely offered the convenience of the user not having to allow for tool radius when sizing the path. This is what seems to be the case with the polygon tool, and I am at a loss as to see why the rectangle uses a different approach. Anyway, I now have a much better understanding of your way of doing it.

By the way, I tried selecting groove, leaving everything else unchanged,  and got a rather strange looking toolpath.

Allan

207
Ron

Maybe I misunderstand, but I chose an inner rectangle, not a pocket, so assumed that the toolpath  would follow the inside of the line, leaving everything inside this path uncut. As it happened, I was clearing out some material around a small spigot, and the spigot would have been cut away by the helical ramp.

Surely the ramp should simply follow the line of the rectangular cut.

Allan

208
Hi Ron

Glad you are making progress. The attached is a simple inside rectangle similar to the ones that gave me grief previously.  There is an unwanted inner helix which appears to be used to set the height of each level of the rectangle. Of course the cut should only be along the rectangular path.

One further issue I've had is that the Z feed rate is invariably used during XY movements. I forgot to mention this last time.

Allan

209
Hi Ron

I find MW very useful but one irritation is that I have to enter the Max Plunge Rate each time I start the program:  for some reason the changes do not stick, unlike the other values in the Config dialog. I use metric units and the default of 60mm/min is far too low. Unless this is changed in advance, jobs  do not load properly (the tool changes are disabled).

I have also noticed that the rectangle tool can produce rogue tool paths when set to cut inside, though if the polygon tool is used instead, it works fine.

Finally, setting Spiral for the rectangle/polygon tools do not result in a Spiral cut, rather a zigzag  start at each level.. I would rather see a true spiral down, as happens with the circle tool.

It would be great if you could put these issues on your fix list for the next release.

Allan


210
OK, thanks Steve.  I currently only have a Hobby licence, so it's  odd that they were available in 2872.

Allan

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 »