Results 1 to 7 of 7

Thread: Saving your current location

  1. #1
    Join Date
    Dec 2000
    Location
    Thorp, WI
    Posts
    2,862

    Default Saving your current location

    Over the years of chasing one of these things (ShopBots) back and forth, I've always kept my eyes open for things that could be automated or ideas for helpful routines. A recent thread, along with many in the past, speak of where the user has stated that they have lost position and can't find their way home because of a crash or some other issue. Some users say that they try to remember to write down the coordinates or take a picture/screenshot of it so that they can do a C3 to home the machine and then use those coordinates to get back to where they started from. I'm talking the last known working location of 0,0, where ever it may be on the table.

    I know that there are many users that have been at this for a long time and can easily make up custom files/routines to do whatever, but at the same time there are some who are new to all this or some that don't care to get into the programming side of things. So with that said and with the above repeated scenario in mind, I though I'd make a little file that could be run that would save your last location or take you back to that location when desired.

    There are a couple of things that you need to do to set it up, but I'll attach the main file that should work for all who want to try it out.

    First, you'll need to open the file my_variables.sbc in an editor (SBedit, Notepad, etc.)which is found in your C:\SbParts\Custom folder (it would be a good idea to make a copy of this file and drop it in the SbParts folder just in case). Once you have it open, scroll all the way to the bottom and add these lines...

    'These values are used for current the location snap shot
    &my_LocSnapShotX=0
    &my_LocSnapShotY=0


    ...Save and close.

    Then take the attached file and place it in your C:\SbParts folder and you can run it from there just like any other file or alternately, you can put it in the C:\SbParts\Custom folder and rename it to CustomXX.sbc (were XX will be a number that isn't being used for a custom file in the custom folder. After doing this, you can then run it from the 'Cuts' menu in SB3 where it will show up as 'Location SnapShot' in the menu (This would be the recommended way).

    Another option for running it is to set it up on a button with the 'Buttons' program that is in the 'Tools' menu, but this is only in SB3 3.8.XX.

    I'm not at my machine today to test this thoroughly, but it should work from what I can see in simulation. I've been using a system of work offsets (up to 6 different locations) for several years, and this is a derivative of that system, but just for a quick simple current location save and return.

    If someone wants to give it a try and let me know if it works as intended, that would be great. To test it, home your machine (C3), jog to another location and run the file, choosing to save the current location. That location should now be your new working 0,0. After that, if you home again or move somewhere else and do a Z2, run it again, but this time choose to return to the last saved location, it should return there and be set to 0,0. This would simulate a situation where you lost position and had to restart/reset.

    Keep in mind, that if you want to return to the table base coordinates, all you have to do is key in 'ST' to set the coordinates back to the table base coordinates.

    If you give it a whirl and have any troubles reply back.
    Attached Files Attached Files
    Scott




  2. #2
    Join Date
    Apr 2013
    Location
    Kennebunkport, Maine
    Posts
    4,439

    Default

    Thanks for the effort Scott, Be a bit before I'm back on machine , but will give it a whirl then. Downloaded-bookmarked.
    scott P.
    2013 Desktop/spindle/VCP 12.0*
    Maine

  3. #3
    Join Date
    Mar 2006
    Posts
    7,832

    Default

    Scott,
    I almost always 0,0 in the center of my material. So consequently what i do to start out is do a C3 and go to table 0,0.

    Then i manually move the bit to the center of the material (marked with an X) and then i take those coordinates that i move it to (say for example X 23.56 Y18.44) and i write them down on paper.

    I then zero X,Y

    so now if i lose position i just go back and do a C3, MX23.56, MY18.44 and i'm back to center of my material.
    So your mod basically remembers that position for you and eliminates the need to do the manual repositioning correct?
    Words of Wisdom:
    “Words that sink into your ears are whispered…… not yelled”
    “The biggest trouble maker you’ll probably ever have to deal with, watches you from the mirror every morn’n”
    “The only difference between a rut and a grave is the depth”
    -----------
    Just remember...when it's time for the hearse to pull up..there's no luggage rack on top!
    -----------
    The beauty of the Second Amendment is that it will not be needed until they try to take it...Thomas Jefferson

  4. #4
    Join Date
    Dec 2000
    Location
    Thorp, WI
    Posts
    2,862

    Default

    That is correct Jack. The intent is to eliminate the need to write down, take a screen shot, take a picture with your phone, etc. etc., the location that you're at before doing the Z2. The routine saves the location to file and zeros the axes there. When resetting, after a C3, it uses the saved values to reposition the axes and again zero them. Sorry, but it can't remind you to use it though.

    If you have a z axis prox switch, you could have it reset the Z axis for the last tool that was zeroed as well (not if it was broken or changed).
    Scott




  5. #5
    Join Date
    Mar 2006
    Posts
    7,832

    Default

    So what happens if your computer crashes or the control box crashes? Won't you lose it anyway?

    Actually that is a great time saver the only thing i'd suggest is that somehow you could have that info saved to your harddrive or thumbdrive instead of just cached in the memory so that if you did have a catastrophe it would be in a place where you could recall it. or am i confused? Good job though!
    Words of Wisdom:
    “Words that sink into your ears are whispered…… not yelled”
    “The biggest trouble maker you’ll probably ever have to deal with, watches you from the mirror every morn’n”
    “The only difference between a rut and a grave is the depth”
    -----------
    Just remember...when it's time for the hearse to pull up..there's no luggage rack on top!
    -----------
    The beauty of the Second Amendment is that it will not be needed until they try to take it...Thomas Jefferson

  6. #6
    Join Date
    Mar 2009
    Location
    Pope Valley CA
    Posts
    692

    Default

    At a quick glance, it looks like he is writing it to the my_variable.sbc file.
    Ron Sloan

  7. #7
    Join Date
    Dec 2000
    Location
    Thorp, WI
    Posts
    2,862

    Default

    Jack, the values are saved/written to the 'my_variables.sbc' file (which is on the hard drive). If the program or computer crashes, it's still there upon restarting the program or computer. The variables in that file are loaded into SB3's memory each time you do a C3 or C2 and most generated cut files along with each time you run this routine.
    Scott




Similar Threads

  1. Find current location?
    By Chelmite in forum ShopBot Desktop
    Replies: 10
    Last Post: 12-22-2014, 08:23 PM
  2. Current Projects
    By rcnewcomb in forum Folder 2010
    Replies: 9
    Last Post: 05-10-2010, 12:56 PM
  3. HSD 2.25 Spindle current
    By 3ps in forum Archives2008
    Replies: 3
    Last Post: 01-12-2008, 11:12 AM
  4. HSD 2.2 SPINDLE CURRENT
    By 3ps in forum Archives2007
    Replies: 8
    Last Post: 11-15-2007, 01:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •