UCCNC Macro sharing - Page 4

Page 4 of 6 FirstFirst 123456 LastLast
Results 37 to 48 of 64

Thread: UCCNC Macro sharing

  1. #37
    Member
    Join Date
    Jun 2015
    Location
    Sweden
    Posts
    842
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    Quote Originally Posted by MerzkeCustom View Post
    Looking for a little help! I have a 3 axis touch plate that I was using in Mach3 and now that I have switched to UCCNC I am trying to get it to work there. It came with an excel document that created some G-Code that you saved in Mach3 and by clicking the auto tool zero button it would run the macro. Is there a way of getting UCCNC to do the same function? I have the excel doc and can email it to anyone that might be able to help. Thanks in advance!
    You can probe with G31 in the UCCNC just like how you can in Mach3.
    There is the M31 macro button, the red probe iconic button on the main screen, pressing that calls the macro M31 in your Profile/macros folder, it actually do probing.
    Open that folder up and check the M31 code to see what it exactly does.



  2. #38
    Member
    Join Date
    Apr 2014
    Posts
    206
    Downloads
    6
    Uploads
    0

    Default

    I don't believe there is a macro function that will allow the values to be written to an external file (CSV or text)
    ....
    But I may be wrong
    Rob



  3. #39
    Member
    Join Date
    Oct 2005
    Location
    USA
    Posts
    785
    Downloads
    3
    Uploads
    0

    Default Re: UCCNC Macro sharing

    This will write a string to a file 1 line at a time. IF there is NO such file it creates it and IF there is a file it appends to it.

    // Write one string to a text file.
    string text = "X" +AS3.Getfield(226) + " , Y" + AS3.Getfield(227) + " , Z" + AS3.Getfield(228);
    System.IO.File.AppendAllText(@"C:\uccnc\Probe1.txt", text+ Environment.NewLine);

    THIS is what the file looks like after 3 probes and writes

    X0.2000 , Y1.9500 , Z-0.6700
    X0.8100 , Y2.7550 , Z-0.1950
    X1.7450 , Y2.4950 , Z-1.2800

    Hope that helps , (;-) TP



  4. #40
    Registered
    Join Date
    Jul 2015
    Posts
    11
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    Hello everyone!...
    I have a question, im writing a macro that need the user input a value into a variable. Anyone know how can achieve it???

    Thanks in advance!!



  5. #41
    Member
    Join Date
    Apr 2014
    Posts
    206
    Downloads
    6
    Uploads
    0

    Default Re: UCCNC Macro sharing

    audiokiller,

    I believe there are two methods available... one is available now (using variables or vars#) and the other which "should" be in the next release can have a popup to ask the user for input, either as a string (text) or a double (number)

    The first method, if you have a look at pdf page 51 of the current manual (parametric programming) it explains variables and using vars#.
    http://www.cncdrive.com/UCCNC/UCCNC_usersmanual.pdf

    The way that I prefer is the message box popup (as I don't have to remember to store the vars in advance of me running the macro code.....)
    The following is extracted out of the current development version of uccnc "macro_capability_detailed.htm file within the uccnc documentation folder.

    Function: string TextQuestion(string Questiontext)
    Description: This function shows a Question form waiting for a string as the answer. The text of the question shown on the Form is the parameter.
    Example: string val = exec.TextQuestion("Stop code execution?");

    Function: double Question(string Questiontext)
    Description: This function shows a Question form waiting for a double value as the answer. The text of the question shown on the Form is the parameter.
    Example: double val = exec.Question("What X position to move?");

    If you are running the vars# method, you could put an if statement in the macro to check the current vars# saved is set or have a simple dialog box popup with a yes no question to ask if you've set the vars already (if you have a look at post # 25 in this thread you can see some code I posted which uses the yes/ no messagebox query and you can customise it as required).

    Rob

    Rob



  6. #42
    Member
    Join Date
    Sep 2005
    Location
    Indonesia
    Posts
    1086
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    Just curious, can we run uccnc software with any hardware or only run with uccnc hardware product. So that we can replace mach3 with this uccnc software on the same hardware. Thanks.



  7. #43
    Member
    Join Date
    Apr 2014
    Posts
    206
    Downloads
    6
    Uploads
    0

    Default

    Quote Originally Posted by asuratman View Post
    Just curious, can we run uccnc software with any hardware or only run with uccnc hardware product. So that we can replace mach3 with this uccnc software on the same hardware. Thanks.
    You must buy a uc motion controller (uc100 (usb), 300 (usb or Ethernet) or 400 (Ethernet)).... uc300eth is not released yet.

    Uccnc will not work with parallel ports or any other motion controllers.



  8. #44
    Member
    Join Date
    Sep 2005
    Location
    Indonesia
    Posts
    1086
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    Thanks for reply. How about post processor, are they available for many software?



  9. #45
    Member
    Join Date
    Apr 2014
    Posts
    206
    Downloads
    6
    Uploads
    0

    Default

    Quote Originally Posted by asuratman View Post
    Thanks for reply. How about post processor, are they available for many software?
    For the most part, I'd say you could use the mach3 post processor... it depends there are a few extra m codes for plasma.

    What software do you use?

    Rob



  10. #46
    Member
    Join Date
    Sep 2005
    Location
    Indonesia
    Posts
    1086
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    What software do you use?
    I want to use fusion360.



  11. #47
    Registered
    Join Date
    Jul 2015
    Posts
    11
    Downloads
    0
    Uploads
    0

    Default Re: UCCNC Macro sharing

    Quote Originally Posted by robertspark View Post
    audiokiller,

    I believe there are two methods available... one is available now (using variables or vars#) and the other which "should" be in the next release can have a popup to ask the user for input, either as a string (text) or a double (number)

    The first method, if you have a look at pdf page 51 of the current manual (parametric programming) it explains variables and using vars#.
    http://www.cncdrive.com/UCCNC/UCCNC_usersmanual.pdf

    The way that I prefer is the message box popup (as I don't have to remember to store the vars in advance of me running the macro code.....)
    The following is extracted out of the current development version of uccnc "macro_capability_detailed.htm file within the uccnc documentation folder.

    Function: string TextQuestion(string Questiontext)
    Description: This function shows a Question form waiting for a string as the answer. The text of the question shown on the Form is the parameter.
    Example: string val = exec.TextQuestion("Stop code execution?");

    Function: double Question(string Questiontext)
    Description: This function shows a Question form waiting for a double value as the answer. The text of the question shown on the Form is the parameter.
    Example: double val = exec.Question("What X position to move?");

    If you are running the vars# method, you could put an if statement in the macro to check the current vars# saved is set or have a simple dialog box popup with a yes no question to ask if you've set the vars already (if you have a look at post # 25 in this thread you can see some code I posted which uses the yes/ no messagebox query and you can customise it as required).

    Rob

    Rob
    Thank you very much Rob, I will try this and report the result =)



  12. #48
    Member
    Join Date
    Apr 2014
    Posts
    206
    Downloads
    6
    Uploads
    0

    Default

    Quote Originally Posted by asuratman View Post
    I want to use fusion360.
    Sorry I've not used ad360 before, if it has a Mach post processor I would have thought it would be fine.

    Rob



Page 4 of 6 FirstFirst 123456 LastLast

Tags for this Thread

Posting Permissions

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


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

UCCNC Macro sharing

UCCNC Macro sharing