peter ~

Verified Members
  • Content count

    199
  • Joined

  • Last visited

Community Reputation

22 Excellent

1 Follower

About peter ~

  • Rank
    Member

Profile Information

  • Gender
    Male

Uncategorized

  • Location
    Canada

Recent Profile Visitors

409 profile views
  1. peter ~

    Anyone dynamic milling 13-8 PH?

    I wonder if it is worth it to maintain climb instead of zigzag, I do not prefer climb anymore.Seems like too much time goes into those microlifts. I used to cut a lot of 17-4 ph dry on a conventional lathe. It is tough stuff .Typically when Im cutting stainless on a mill I use a stepover between .005 to .025 I find the tools heat and wear less with a skinny cut at high speed.
  2. peter ~

    Anyone dynamic milling 13-8 PH?

    500 to 600 might work with that material however you will need to assign a lower cutting speed to your helical entry to avoid burning your tool. If you have air jets it would be good for something like this..
  3. peter ~

    Robotics for mastercam

    Fascinating, thank you J.
  4. peter ~

    Robotics for mastercam

    One of our 5 axis programmers was telling me there was a mastercam product for programming non cnc robots. Is that a real thing? If so what is it called please?
  5. peter ~

    I need help please

    What version of Mastercam are you using please? What machine are you working with ie. Mill, Router, Lathe, or Wire EDM ?
  6. You can run the FT command for solid selection first,
  7. Lathe and wire EDM operations are still unsupported by NETHOOKS hopefully this will change in the near future.
  8. peter ~

    Probe errors for help

    Can you translate what this says for us please?
  9. peter ~

    Stock Models not generating

    For best results the stock model operation from operation manager should work fine. If your result 3d model is a sheet solid you could try create surface from solid then create solid from surface with a .005 tolerance for example, this usually takes care of the small gaps.
  10. Here is some C# codes I use to scan information from a .nc file. In this console application the information is loaded into a winform. You could also load data from an ncfile easily into a premade excel worksheet by creating a com object of the document C# is very strongly typed when it comes to excel so it is easy to setup. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Threading; using System.Drawing; using System.Windows.Forms; using System.Globalization; namespace txtreader { class Program { static string ConvertStringArrayToStringJoin(string[] array) { // Use string Join to concatenate the string elements. string result = string.Join(".", array); return result; } public static string GetBetween(string strSource, string strStart, string strEnd) { if (strSource == null) { throw new ArgumentNullException(nameof(strSource)); } if (strStart == null) { throw new ArgumentNullException(nameof(strStart)); } if (strEnd == null) { throw new ArgumentNullException(nameof(strEnd)); } int Start, End; if (strSource.Contains(value: strStart) && strSource.Contains(value: strEnd)) { Start = strSource.IndexOf(value: strStart, startIndex: 0) + strStart.Length; End = strSource.IndexOf(value: strEnd, startIndex: Start); return strSource.Substring(startIndex: Start, length: End - Start); } else { return ""; } } //in string 1 > initial string to be searched //in string 2 > the value to search for //returns new string found after first instance of initial string public static string GetAfter(string strSource, string toBeSearched) { int ix = strSource.IndexOf(toBeSearched, StringComparison.InvariantCultureIgnoreCase); if (ix != -1) { string code = strSource.Substring(ix + toBeSearched.Length); return code; } return null; } static void Main(string[] args) { //intialize some variables double lowest_mdpth = 0; double lowest_ddpth = 0; double z_val_cur = 5; double x_val_cur = 0; double y_val_cur = 0; List<double> zval_rec = new List<double>(); List<double> xval_rec = new List<double>(); List<double> yval_rec = new List<double>(); List<string> list1 = new List<string>(); List<string> list2 = new List<string>(); List<string> list3 = new List<string>(); List<string> list4 = new List<string>(); List<string> list5 = new List<string>(); List<string> list6 = new List<string>(); List<string> list7 = new List<string>(); List<string> list8 = new List<string>(); List<string> list9 = new List<string>(); List<string> list10 = new List<string>(); List<string> list11 = new List<string>(); List<string> list12 = new List<string>(); List<string> list13 = new List<string>(); List<string> list14 = new List<string>(); List<string> list15 = new List<string>(); List<string> list16 = new List<string>(); int counter = 0; string line; long count = 0; long count2 = 0; long count3 = 0; long count4 = 0; long count5 = 0; long count6 = 0; long count7 = 0; long count8 = 0; long count10 = 0; long count11 = 0; long count12 = 0; long count13 = 0; long count14 = 0; long count15 = 0; double stk_thk = 0; double minus_stk_thk = 0; double thru_cut_depth; //create a new winform var f2 = new Form() { Text = "System " }; //create a new label Label lbl = new Label(); //create a point to assign label location lbl.Location = new Point(20, 0); //create a static text display (uneditable text) lbl.Text = "Program Name:"; //add label to winform f2.Controls.Add(lbl); Label lbl2 = new Label(); lbl2.Location = new Point(20, 100); lbl2.Text = "Stock Thickness:"; f2.Controls.Add(lbl2); Label lbl3 = new Label(); lbl3.Location = new Point(20, 200); lbl3.Text = "Tool Numbers:"; f2.Controls.Add(lbl3); Label lbl4 = new Label(); lbl4.Location = new Point(20, 300); lbl4.Text = "Lowest Z Mill Tool Depth:"; f2.Controls.Add(lbl4); Label lbl5 = new Label(); lbl5.Location = new Point(20, 400); lbl5.Text = "Lowest Z Drill Tool Depth:"; Label lbl6 = new Label(); lbl6.Location = new Point(20, 400); lbl6.Text = "Error Message:"; f2.Controls.Add(lbl6); TextBox txt = new TextBox(); txt.Name = "textBox1"; f2.Controls.Add(txt); txt.Location = new Point(20, 60); txt.Size = new Size(300, 100); txt.BorderStyle = BorderStyle.FixedSingle; TextBox txt2 = new TextBox(); txt2.Name = "textBox2"; f2.Controls.Add(txt2); txt2.Location = new Point(20, 150); txt2.Size = new Size(300, 100); txt2.BorderStyle = BorderStyle.FixedSingle; TextBox txt3 = new TextBox(); txt3.Name = "textBox3"; f2.Controls.Add(txt3); txt3.Location = new Point(20, 250); txt3.Size = new Size(300, 1000); txt3.BorderStyle = BorderStyle.FixedSingle; TextBox txt4 = new TextBox(); txt4.Name = "textBox4"; f2.Controls.Add(txt4); txt4.Location = new Point(20, 350); txt4.Size = new Size(300, 1000); txt4.BorderStyle = BorderStyle.FixedSingle; TextBox txt5 = new TextBox(); txt5.Name = "textBox5"; f2.Controls.Add(txt5); txt5.Location = new Point(20, 450); txt5.Size = new Size(300, 1000); txt5.BorderStyle = BorderStyle.FixedSingle; TextBox txt6 = new TextBox(); txt6.Name = "textBox6"; f2.Controls.Add(txt6); txt6.Location = new Point(20, 550); txt6.Size = new Size(300, 1000); txt6.BorderStyle = BorderStyle.FixedSingle; OpenFileDialog openFileDialog1 = new OpenFileDialog { //set the directory to load files from InitialDirectory = @"C:\Users\Public\Documents", Title = "Browse Text Files", CheckFileExists = true, CheckPathExists = true, //set default file type filter DefaultExt = "nc", Filter = "nc files (*.nc)|*.nc", FilterIndex = 2, RestoreDirectory = true, ReadOnlyChecked = true, ShowReadOnly = true }; if (openFileDialog1.ShowDialog() == DialogResult.OK) { var onlyFileName = System.IO.Path.GetFileName(openFileDialog1.FileName); System.IO.StreamReader file = //read file new System.IO.StreamReader(openFileDialog1.FileName); //loop through each line of the text file once while ((line = file.ReadLine()) != null) { double info = 0; double info2 = 0; double info3 = 0; double info4 = 0; double info5 = 0; double info6 = 0; double info7 = 0; double info8 = 0; double info10 = 0; double info11 = 0; double info12 = 0; double info13 = 0; double info14 = 0; double info15 = 0; //get some values from the database string input = "stock_thk:";//stock thickness declaration string code = GetStringAfter(ref count, input, line); counter++; if (count == 1) { info = SetStringToList(list1, out count, code, info); count = 0; stk_thk = info; minus_stk_thk = stk_thk * -1; if (code != null) { code = code.Trim(); list1.Add(code); txt2.Text = code; } } string input2 = "z"; string code2 = GetStringAfter(ref count2, input2, line); if (count2 == 1) { info2 = SetStringToList(list2, out count2, code2, info2); z_val_cur = info2; if (info2 < lowest_mdpth) { lowest_mdpth = info2; } } string input3 = "i-"; string code3 = GetStringAfter(ref count3, input3, line); if (count3 == 1) { info3 = SetStringToList(list3, out count3, code3, info3); count3 = 1; list3.Add(code3); } string input4 = "j"; string code4 = GetStringAfter(ref count4, input4, line); if (count4 == 1) { info4 = SetStringToList(list4, out count4, code4, info4); count4 = 1; list4.Add(code4); } string input5 = "g83"; string code5 = GetStringAfter(ref count5, input5, line); if (count5 == 1) { info5 = SetStringToList(list5, out count5, code5, info5); count5 = 0; list5.Add(code5); } string input6 = "g99"; string code6 = GetStringAfter(ref count6, input6, line); if (count6 == 1) { info6 = SetStringToList(list6, out count6, code6, info6); count6 = 0; list6.Add(code6); } string input7 = "x"; string code7 = GetStringAfter(ref count7, input7, line); if (count7 == 1) { info7 = SetStringToList(list7, out count7, code7, info7); count7 = 0; list7.Add(code7); x_val_cur = info7; } string input8 = "y"; string code8 = GetStringAfter(ref count8, input8, line); if (count8 == 1) { info8 = SetStringToList(list8, out count8, code8, info8); count8 = 0; list8.Add(code8); y_val_cur = info8; } string input11 = "g81"; string code11 = GetStringAfter(ref count11, input11, line); if (count11 == 1) { info11 = SetStringToList(list11, out count11, code11, info11); } //prefix of program name string input9 = ";program name :"; string code9 = GetAfter(line, input9); if (code9 != null) { code9 = code9.Trim(); list9.Add(code9); txt.Text = code9; } string input10 = "t"; string code10 = GetStringAfter(ref count10, input10, line); if (count10 == 1) { info10 = SetStringToList(list10, out count10, code10, info10); if (count10 == 1) { list10.Add(code10); } } string input12 = "m05"; string code12 = GetStringAfter(ref count12, input12, line); if (count12 == 1) { info12 = SetStringToList(list12, out count12, code12, info12); if (count12 == 1) { list10.Add(code12); } } string input13 = "m03"; string code13 = GetStringAfter(ref count13, input13, line); if (count13 == 1) { info13 = SetStringToList(list13, out count13, code13, info13); if (count13 == 1) { list13.Add(code13); } } string input14 = "g01"; string code14 = GetStringAfter(ref count14, input14, line); if (count14 == 1) { info14 = SetStringToList(list14, out count14, code14, info14); if (count14 == 1) { list14.Add(code14); } } string input15 = "g00"; string code15 = GetStringAfter(ref count15, input15, line); if (count15 == 1) { info15 = SetStringToList(list15, out count15, code15, info15); if (count15 == 1) { list14.Add(code14); } } count2 = 0; count3 = 0; count4 = 0; count10 = 0; count11 = 0; count12 = 0; count13 = 0; count14 = 0; count15 = 0; if (x_val_cur != 0 || y_val_cur != 0 || z_val_cur != 0) { xval_rec.Add(x_val_cur); yval_rec.Add(y_val_cur); zval_rec.Add(z_val_cur); string str = "X Value = " + x_val_cur + " Y Value = " + y_val_cur + " Z Value = " + z_val_cur; } } file.Close(); //check for duplicate tools in tool list List<string> distinct = list10.Distinct().ToList(); string toollist = ""; foreach (var tool in distinct) { toollist = toollist + "T" + tool + " ,"; } if (txt3 != null) { txt3.Text = toollist; } txt4.Text = "z-" + lowest_mdpth.ToString("0.######"); txt5.Text = "z-" + lowest_ddpth.ToString("0.######"); f2.StartPosition = FormStartPosition.Manual; Application.Run(f2); } } //convert string to double value private static double SetStringToList(List<string> firstlist, out long count, string code, double info) { try { info = Convert.ToDouble(code, CultureInfo.InvariantCulture); } catch (FormatException) { count = 0; return info; } count = 1; return info; } public static string GetStringAfter(ref long count, string input, string text) { string code = GetAfter(text, input); if (code != null) { count = count + 1; code = code.Trim(); code = code.IndexOf(" ") > -1 ? code.Substring(0, code.IndexOf(" ")) : code; return code; } return null; } } }
  11. peter ~

    VERISURF TOOLS for 2020

    I want to start my own business and I know it won't be profitable it to buy MCX for my personal right away, but there are affordable softwares like fusion 360 that can get the job done and have decent API's (even though they don't have dynamic xform tool ) .There's no excuse to be a crook. Seems like these companies are just greedy, bet weren't paying for their Microsoft office either!!!!
  12. peter ~

    VERISURF TOOLS for 2020

    I had a similar experience a long time ago... Did you report them in the end?
  13. peter ~

    Boolean op.

    Did you try performing the same boolean operation in an older version to validate that this is really a platform issue? I use Boolean a lot and 99 times out of a hundred the issues users in my company encounter are setup related. Could you provide some additional information please? Perhaps an Mcx FIle, stp file or a picture?
  14. I tested out the following code which will give you the ability to convert string values(text) to double values(decimal numbers) : Imports System.Windows.Forms Private Shared Function ConvertDoubletoString(ByVal text As String) As Double Dim number = 0.0 Try number = Convert.ToDouble(text, System.Globalization.CultureInfo.InvariantCulture) Catch __unusedFormatException1__ As FormatException MessageBox.Show("could not convert " & text & " to double") Return 0 End Try Return number End Function Sub ActiveReport_ReportStart Dim textboxvalue = ".4" Dim decimalvalue As Double = 0.0 If textboxvalue IsNot Nothing AndAlso textboxvalue <> "" Then decimalvalue = ConvertDoubletoString(textboxvalue) MessageBox.Show(decimalvalue.ToString() & Environment.NewLine & "second line") End If End Sub
  15. If your textDEPTH.text value is a string you will need to convert it to a double type variable before using in an equation. I will post an example of that when I get back to my computer(im on my phone rn).

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us