586,060 active members*
4,328 visitors online*
Register for free
Login
Page 1 of 2 12
Results 1 to 20 of 25
  1. #1
    Join Date
    Oct 2007
    Posts
    51

    NcPlot feature request

    Requested feature is there a way that you could make a script command from your
    Run time Estimation \ program extents so as to insert xy size into program as note if so with the ability to round up to a fraction.

    I’ve been playing around with scripts to reformat current files to a new machine and Ncplot’s ability to use scripts is a God send.
    Also in Run time Estimation \ estimated run time \ average feed rate, allow feed rate to be edited here instead of in file only.

    I also noticed that the {alt}-{F}-{X} shortcut is listed as Export DXF and as Exit

    And one more request this one my be a stretch but is it possible through a new feature or through a script function to select multiple lines of txt and replace one line of txt with selected txt in active file through NcPlot. I’ve been copy and pasting to do this and would like to do this with a script

    I have code written that uses sub programs and my new/used laser cutter does not call sub programs from in the active file like my other 4 machines so I copy and paste the same sub code multiple times to convert code.

    I’m new to vbscript so not sure if there is script code to do this in an active program like NcPlot

    I'll post some of my scripts if anyone is interested, might inspire someone in there work

    Thanks

    PS I’m using version 2.07

  2. #2
    Join Date
    Mar 2003
    Posts
    765
    Hi,

    One of the items on my list is to expand the scripting functionality, so any suggestions for new/improved functions are welcome.

    The average feed rate on the run time estimation page is of course calculated from the program code. I'm going to be adding feed rate/rapid rate override controls to the run time estimation so that you can see the effects of feed rate changes without editing the program.

    Thanks for spotting the duplicate shortcut keys, I need to go through all the menus and re-look at all the shortcuts.

    As a suggestion for converting your programs with subs, have a look at the macro translator. Besides converting macro programs it will also expand sub programs, leaving you with a longhand program without any sub calls.

    Thanks,
    Scott

  3. #3
    Join Date
    Oct 2007
    Posts
    51
    Thanks Scott,
    For the speedy response one question about macros (I’ve never messed with them) do I need to write one to expanded sub call programs to longhand or is this a built in function? I’ve looked at the help file and I’m not sure where to start. Are there any other examples you could give me. I’ll Google (CNC macros) as well.

    PS here is an example of what I’m trying to do.
    Attached Files Attached Files

  4. #4
    Join Date
    Mar 2003
    Posts
    765
    No, you can run any program through the macro translator. Without a program loaded into the editor go to 'Tools / Macro Translator' and click the 'Browse for Macro Folder' button. Select the folder where your program is located and then change the file filter box from 'Macro Files (*.mac)' to 'All Files (*.*)'. Select your program and then click the 'Execute' button.

    You will get a file that has every command that was executed in the order it was executed, so subprograms get copied every time they are called. You will need to remove the actual 'M98' commands from the resulting code. I thought these were removed automatically, I'll have to check and see why they aren't.

    Thanks,
    Scott

  5. #5
    Join Date
    Oct 2007
    Posts
    51
    Thanks Scott,
    That’s exactly what I was looking for.
    And to all of you thinking NcPlots price is high (as I’ve read in a few posts) $300.00 is cheap for all it does before finding NcPlot I had no way of view/testing my file and this is with 3 different programs to nest parts and write code. This macro feature alone will pay for itself in one or two days in saved time. If you’re thinking of buying NcPlot , Buy it!

  6. #6
    Join Date
    Oct 2007
    Posts
    51
    Scott one more scripting request
    How about the ability to insert header and footer so maybe something like
    ncplot.header = (string name)
    (Which inserts a string at home position of txt in edit window)
    Header string example:
    Dim header
    Header = _
    “G20” &Vbcrlf& _
    “G54” &Vbcrlf& _
    “G90”

    and
    ncplot.footer (which inserts a string at end position of txt in edit window)
    That way header , footer, and notes can be inserted through use of one script.

  7. #7
    Join Date
    Oct 2007
    Posts
    51

    Vbscripts

    Here are some of my scripts please forgive any unnecessary steps these are my first attempt to write script files so Google was all I had to go on .
    To all feel free to hack these to fit your needs
    Attached Files Attached Files

  8. #8
    Join Date
    Mar 2003
    Posts
    765
    You can add header and footer text using the existing script methods, like so:


    --------------------------
    dim header
    dim footer
    dim ptr

    header = "Header Text"
    footer = "Footer Text"

    ncplot.ncpsetselection 0,0
    ncplot.ncpinserttext header & vbcrlf

    ptr = ncplot.ncpgetlineindex(ncplot.ncpgetnumlines - 1)
    ncplot.ncpsetselection ptr,0
    ncplot.ncpinserttext footer & vbcrlf

    --------------------------

    Hope this helps,

    Scott

  9. #9
    Join Date
    Oct 2007
    Posts
    51
    thanks that does help. As i posted earlier i have justed started to learn vbscript

  10. #10
    Join Date
    Oct 2007
    Posts
    51
    Scott,
    Got one more question is there a way while running a script to pause the script and return to NcPlot to get a value and return it to the script. Like the ability through the mouse to click on the plot screen and return the curser coordinate to the script.
    What I’d like to do is to make a script that I can load one of many filler parts to my cut layout and use your NCPlot.NCPAddressAdjust and NCPlot.NCPRotate in a script to insert the code in one step if it’s possible to do this it would save some time if not I’ll continue to use them from the pull down menu
    Thanks

  11. #11
    Join Date
    Mar 2003
    Posts
    765
    No, there's nothing like that in there now but I can see how that could be useful. I'll add this to my list.

    Thanks,
    Scott

  12. #12
    Join Date
    Oct 2007
    Posts
    51
    Scott I Don't want to be a pest but can you add a scripting comand like the one for controling preferances in v2.20b5
    (NCPGetPrefSetting(strSetting), and NCPSetPrefSetting strSetting, newValue)
    but to change subprogam handling
    [SUBPROGRAMS]
    Default Path =
    Ignore M98 = 1 (change this to 3)
    Ignore G65 = 1 (ect.)
    this would save a click or two after converting format
    thanks

  13. #13
    Join Date
    Mar 2003
    Posts
    765
    Yep, I have this on my list already. The goal is to be able to access all of the non machine configuration related settings.

    Thanks,
    Scott

  14. #14
    Join Date
    May 2006
    Posts
    6

    Machine Config Script Folder Selection

    Scott,

    I would like the ability to store machine specific script files is their own folder within the scripts folder and be able to select that folder to be the default when changing machines. I have a lot of scripts that I have written that are specific to a certain machine and it gets cluttered when I hit the script button a 20 script files that I could not use for the machine come up. Possibly the ability to specify 2 folders so you could have universal scripts in one folder and all machine specific scripts in their own folder.

    Thanks

  15. #15
    Join Date
    Mar 2003
    Posts
    765
    I actually have this on my list already, you should see it for the release of v2.20.

    Thanks,
    Scott

  16. #16
    Join Date
    May 2006
    Posts
    6
    Scott,

    Is there a way to get and set the current cursor position? When I use the NCPAllCaps function it puts the cursor back to the top of the program. I would like to reposition the cursor back to the spot that it was before.

    Thanks

  17. #17
    Join Date
    Mar 2003
    Posts
    765
    You can set the cursor position with NCPSetSelection but there's no way to get the current cursor position. I'll add this though, simple enough to do.

    Thanks,
    Scott

  18. #18
    Join Date
    Feb 2006
    Posts
    992
    Scott,

    In turning mode, keep getting error message if the program radius smaller than .017 and somehow the graph is look funny if try graph part of the circle, full circle is fine.
    The best way to learn is trial error.

  19. #19
    Join Date
    Mar 2003
    Posts
    765
    Can you post an example? This sounds like you may need to switch between radius/diameter mode for the X axis.

    Scott

  20. #20
    Join Date
    Feb 2006
    Posts
    992
    Quote Originally Posted by MetLHead View Post
    Can you post an example? This sounds like you may need to switch between radius/diameter mode for the X axis.

    Scott
    Thanks Scott,
    I tried diameter and everything is working fine now.
    The best way to learn is trial error.

Page 1 of 2 12

Similar Threads

  1. NCPlot Rotate feature
    By georgebarr in forum NCPlot G-Code editor / backplotter
    Replies: 2
    Last Post: 05-14-2009, 10:15 AM
  2. Feature Request
    By TURNER in forum NCPlot G-Code editor / backplotter
    Replies: 2
    Last Post: 07-03-2008, 01:56 AM
  3. Request DNC feature
    By single phase in forum NCPlot G-Code editor / backplotter
    Replies: 3
    Last Post: 12-14-2007, 04:04 AM
  4. Feature Request
    By robinsoncr in forum MadCAM
    Replies: 3
    Last Post: 08-06-2007, 04:03 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
  •