PDA

View Full Version : programming using SK



Justin G
06-26-2015, 06:30 PM
There may be another way to do this but here is what I am trying to do.

Using Aspire and programming a multi tool cutting operation, I want to tell the machine to go to specific points relative to TABLE BASE coordinates.

I normally run all my part files with temporary zeros set at wherever the corner of my material happens to be on the table, but my home-made off table zero plate and tool changing location/ height are ALWAYS the same.

I noticed that when I have a temporary zero set up, the memorized keypad buttons will still send the machine to the locations I set them when the zero is at the actual table base zero. I like this.

Is there a way to program my custom zero file to use the memorized command locations, instead of X,Y locations?

Example for tool change is:
jz 9
sk 1 (bit changing)
sk 2 (zero plate)
c2
jz 9
jh
end

This is essentially what I have my current c9 function set as, except the sk positions are X/Y positions currently.

Anyone know how to do this? thanks guys.

Justin G
06-27-2015, 11:40 AM
If there was a way to temporarily set the zero values to table base coordinates , run the program, then set them back to assigned zeros automatically, that would also be helpful. However possibly not for each part file I save from aspire as that could take a long time to manually punch in the code.

srwtlc
07-04-2015, 03:57 PM
I've no doubt that it can be done, but it will need to be handled in each possible scenario depending on the message box answers throughout the tool change. You would need to save the current location, issue a ST command to set to table base coordinates, go to the XY location used for Z zeroing, then reset to the saved location to continue. If I was near my machine, I'd play with it a bit. Some time back, I had a little file that would take a snapshot of your current location (based on the offset from the table base coordinates) and/or return to that location, that could possibly be used for this situation. You could have it take a snapshot of your current XY zero location at the start and when needed you would issue an ST just before it needs to go to your XY zero location and when finished, return to your working XY zero location.

It would take some trial and error to set up (the manual tool change files are a tad bit convoluted), but it could be done. I'd be willing to play around with it if you don't want to dig into that stuff.

Here's that thread (http://www.talkshopbot.com/forum/showthread.php?19663-Saving-your-current-location).

srwtlc
07-06-2015, 04:22 PM
Justin,

I took a moment to play with this and as it turns out, it's really quite easy to handle this for the XY zzeroing location. All you have to do is change how the variable for the location is set. If you open My_variables.sbc in the SB editor and find this section...

' If you always want to zero your z-axis in the same place on the table, change these values to
' the coordinates of the point that you want to use
&my_ZzeroStartX= no
&my_ZzeroStartY= no

Where 'no' will be your current value, and change the value to something like this, according to your chosen location...

&my_ZzeroStartX=-%(6)+(-2)
&my_ZzeroStartY=-%(7)+6

I just used -2 for the X location and 6 for the Y location. %(6) and %(7) are the system variables for the table base coordinates. So, if your working 0,0 is 10" from table base in X and 10" from table base in Y, you'll be moving negative that distance plus the distance from table base your Zzero location is at.

If you choose to use the keyboard to position it, you can use the set memory buttons as well.

If you never want to Zzero on a material surface, like v-carving, you may want to add a question message to determine which way you want to Zzero or just set up a separate Zzero file for doing so.

Setting up a toolchange position could be done in a similar manner by adding some user variables for it in the My_variables.sbc file and also adding some code to handle it in the MTC file. It may require that you have a prox switch on the Z axis though for setting the Z change height.

Justin G
07-06-2015, 08:51 PM
Scott,
This is awesome information. I will have to play around with all this and see how exactly to work it out.

I do not want to change my zero routine C2 permanently to the same location everytime because I do zero to both table and material, but for the C9 MTC, this is exactly what I am looking for. Thank you and I'll let you know what I can get worked.

Justin G
07-10-2015, 09:13 PM
Justin,

I took a moment to play with this and as it turns out, it's really quite easy to handle this for the XY zzeroing location. All you have to do is change how the variable for the location is set. If you open My_variables.sbc in the SB editor and find this section...

' If you always want to zero your z-axis in the same place on the table, change these values to
' the coordinates of the point that you want to use
&my_ZzeroStartX= no
&my_ZzeroStartY= no

Where 'no' will be your current value, and change the value to something like this, according to your chosen location...

&my_ZzeroStartX=-%(6)+(-2)
&my_ZzeroStartY=-%(7)+6

I just used -2 for the X location and 6 for the Y location. %(6) and %(7) are the system variables for the table base coordinates. So, if your working 0,0 is 10" from table base in X and 10" from table base in Y, you'll be moving negative that distance plus the distance from table base your Zzero location is at.

If you choose to use the keyboard to position it, you can use the set memory buttons as well.

If you never want to Zzero on a material surface, like v-carving, you may want to add a question message to determine which way you want to Zzero or just set up a separate Zzero file for doing so.

Setting up a toolchange position could be done in a similar manner by adding some user variables for it in the My_variables.sbc file and also adding some code to handle it in the MTC file. It may require that you have a prox switch on the Z axis though for setting the Z change height.

OK I got it down. A while back I had programmed my custom off table zero plate routine and saved it as custom 9. I am fairly certain this is the MTC custom slot. I did not end up changing anything in any of my variable files. I only changed the custom c9 file using the variables you mentioned with the minus sign in front of them: (-%(6)+X and -%(7)+X.) X being a generic place holder for my personal tool change location and zeroing plate location. I had to change the two line items only and the file works if I am zeroed at table base coordinates, or a working zero. I use the standard C2 to zero on top of material. Mission accomplished.

Thank you for all the help Scott. You obviously do not need it, but if you would like I can send you my file if you're curious.

srwtlc
07-11-2015, 11:04 PM
Glad you got it worked out Justin! Go ahead and post it here if you want, it may be helpful to others down the road. It's a good fix/option for anyone that may use a work offset and also uses a fixed Zzeroing location (whether you're using or not using the manual tool change system).

Joseph.fm
02-16-2016, 05:49 AM
Not here is no any way to temporarry make the value at zeroo ..you cant do this for temporarly but ban make a programe or command which change it by it self ..If any one think ?? so can tell me