PDA

View Full Version : Long pause screws up work, and programing question



3imoh
07-02-2009, 07:32 PM
So I had a long v-carve run today of 50 identical shapes in ply, and my spindle was starting to get a bit hot. I hit "s" to pause things about half way through for a bit to let it cool down.

After about 20 minutes, I hit resume and the spindle drills itself up to the collet into the work, and tries to keep on going. I did nothing other than hit S, and resume. Does anyone have any idea why this would happen? Very frustrating.

The worst part is that it my position is off so I have to Z3 again...this is going to cause issues with the parts that I already have cut, as I won't be able to get the zero dialed in enough to run over the top of the previous cut parts.

I can't just restart the file at a specific line number because I created a master file that loops thru an x and y counter calling a single cut file over and over and different 2d offsets.

I figured I could just edit the file to "skip" over the areas that have already been cut, but this statement does not work in SB:

if &xcount < 3 and &ycount < 5 then GOSUB skip

The software does not seem to evaluate this statement properly. It never does the GOSUB.

I have printed my vars right above this statement, and they are incrementing properly.

Any thoughts would be appreciated.

thanks,
Howie

Gary Campbell
07-02-2009, 07:47 PM
Howie...
2 things....
1) make sure that you enter the &xcount and &Ycount variables on sparate lines. (1 per line)

2) you can only perform 1 logical test per line. The "AND" is not valid

can you add your count variables (X &Y) and then run the file? It should go to the correct location and then resume the count for both in the normal fashion.
Gary

3imoh
07-02-2009, 08:36 PM
Hi Gary-

Thanks for the response. I will mess with it some more...I wish the programing language in SB was a bit more robust...maybe since they are open sourcing the language this area will get more attention?

BTW, any ideas on why the control software decided to see how far it could drill a her-saf v cutter into the table after just resuming from a pause?

I don't know what it is with my setup, but I have had a bunch of weird SW glitches that seem to crop up at various times. It has gotten to the point where I am avoiding cutting high dollar material (paperstone, etc) because I don't trust my machine.

I need to take some time and methodically go thru everything when I have some time. My day (non sb) job is keeping me really busy which is a blessing or a curse depending on my mood...

-howie

Gary Campbell
07-02-2009, 09:33 PM
Howie...
There have been a few glitches posted in the last couple weeks that sound similar to yours. (problems arising when cutting file is paused) Similar, but as usual, not exactly the same. I am not sure that they have been repeatable. If you can make yours repeatable, then the file and your settings can be sent to SB, and it will most likely get fixed fairly quickly.

I keep a copy of 3.5.20 around just in case I am using materials I cant afford to replace. As long as its a file that didnt originate in eCabs, then I can use the "Ol tried & true".

You are correct, the trust level I have in the software is not as high in the last few months as it was last fall.
Gary

srwtlc
07-03-2009, 12:37 AM
I just had the same thing after a long pause. I had a sheet of cherry MDF on the table, v-carving 24 plaques in it. After resuming from a long pause, it drilled it's way through the sheet and hit the collet! Short pauses have been fine. It takes 12 hours to carve these 24 plaques and I would agree that I'm not as confident as I used to be about leaving it on it's own.

beacon14
07-03-2009, 03:09 AM
Long pause, short pause, I don't think it matters, it seems to be a timing issue that you just happened to hit the S key while the CPU was in the middle of doing something which caused the SB to loose it's location.

recent thread (http://www.talkshopbot.com/forum/messages/26/42966.html?1244922290#POST88890)

3imoh
07-03-2009, 08:43 AM
Thanks guys...glad it is not just my machine. It is going to be hot here again today, so I am hoping that putting a pause statement in the file will not have the same effect. I'll make sure to move the spindle off the material in case it does.

ted
07-03-2009, 12:19 PM
Hi Guys,

If you could send a sample of one of the master files with embedded files so we can try and duplicate the problem with the long pause here, it would be helpful. We'll see if we can get it sorted out.

Howie, On the logic test issue. We'll put on the "wish list" to add logic tests with complex conditions. At the moment, as indicated in the Programming Handbook, you can only do one test at a time. But you can do the test you want by just breaking it into several lines. I know this is a little awkward, but it does work.

Ted Hall, ShopBot Tools

3imoh
07-03-2009, 12:35 PM
Hi Ted-

Thanks for looking at it. I will package up the files and send them as soon as I can.

Would you mind providing a sample of a multi-condition test? I tried various combinations and was unable to get it to work. Do I just chain these together with multiple IF/THEN statements on separate lines? The programming handbook is a bit vague in it's example.

thanks,
-Howie

beacon14
07-04-2009, 06:30 AM
You could try something like this:

If &xcount > 2 Then GOTO Next 'notice >2 instead of <3

If &ycount < 5 then GOSUB skip

Next:

3imoh
07-04-2009, 12:09 PM
Hi David. That would not work for me as I needed to test more than one condition to trigger a single event. Testing the vars in "isolation" would not get me what I needed in this case.

I was hoping that Ted and Gary were saying above that it was possible to test multiple conditions that would trigger a single action by using some sort of multi-line syntax.

That would be great to have on a wish list for the control SW.

ted
07-04-2009, 05:54 PM
Here's an example of one way to do your test.

IF &y < 3 THEN GOTO True_y
GOTO Continue
True_y:
IF &x < 5 then GOTO True_both

Continue:
'Your main stuff or a GOSUB Here
END

True_both:
GOSUB Skip
END

beacon14
07-04-2009, 06:25 PM
Howie,

Did you try it or are you just assuming it won't work? I think this is one version of the multi-line syntax they are referring to.

I am assuming in this case that &xcount and &ycount will be integers (whole numbers, not fractions); if that is not correct you'd have to change the equations a little but the logic should still work.

Let's look at the logic of each line:

If &xcount > 2 Then GOTO Next

In this case if &xcount is 0, 1 or 2 (ie, less than 3) then control will pass to the following line, but if &xcount is 3 or more the following line will be bypassed and the file will continue with the 3rd line, the "Next:" label.

If &ycount < 5 then GOSUB skip

This line only tests the &ycount variable, but this line will never be evaluated unless the &xcount variable is less than 3 due to the If/Then in the first line.

So the first two lines, taken together, do the same logic test as what you wanted in your original post, "if &xcount < 3 and &ycount < 5 then GOSUB skip"

I hope this makes sense. Ted beat me to the post but unless I am mistaken my three lines will do the same thing as what he posted. In programming, as in ShopBotting, there is always more than one way to make something work.

bcammack
07-06-2009, 08:44 AM
Decomposing a multi-conditional test works. Most compilers don't perform the 2nd conditional test if the first conditional test fails. Why should it? (meaning:if "this" AND "that". if "this" OR "that" decomposes differently.)

Back when dinosaurs roamed the earth, I used this fact to construct a precompiler for Basic language that didn't support conditional looping, ElseIf, Case statements, or most other sophisticated conditional structures that are commonplace today.

3imoh
07-06-2009, 09:59 AM
David, Ted-

Thanks much for the examples...those make sense now that I have had a chance to mess with it for a bit.