Verified Members
  • Content count

  • Joined

  • Last visited

Community Reputation

106 Excellent


About Zaffin

  • Rank

Recent Profile Visitors

924 profile views
  1. I looked over the thread where you detail the issue and I do see a few odd things in the managed code. Is the entire Visual Studio solution available some where? I'd like to see if I can duplicate the behavior.
  2. I wouldn't say I'm advanced; I have so much to learn it's crippling at times. I'm extremely fortunate to work with great people that are willing to share the knowledge they have amassed over the years. I have done several C++/C# interop hooks and I've never had an issue. I wouldn't expect F# to make any difference; doesn't it compile to the same intermediate language as C#?
  3. Yes, you can do whatever you want; that's why it's up there.
  4. I think this is a good idea, but the code leaves a bit to be desired. In an effort to help you out I created a more organized example. It's not 100% yet, but you can read in an .NC file and obtain a tool list and the min and max X,Y,Z values. I hope it helps.
  5. Yes.* NET-Hook's are not version dependent like C-Hooks. *NETHOOK_3.dll changes between Mastercam versions, so sometimes functions are deprecated or updated.
  6. Zaffin

    Buffer help, I think?

    Download it from Mastercam's tech exchange; that way you can review the entire post.
  7. Zaffin

    Buffer help, I think?

    Hi Brad, If you're using the enhanced tool table that was introduced in Mastercam 2017 check out the Techno Titan post on the Mastercam tech exchange. The Titan post has a postblock to output the tools minium Z.
  8. That's not surprising, strictly speaking the answer to your question is no; MP.dll can not make changes to the Mastercam file.* However, if a Mastercam Add-in is created, the post can call that and it can be used to do all sorts of things to the Mastercam file. Just so you're aware, the help your looking for likely will not be free. *Prior to Mastercam X8, MP.dll could draw basic geometry in the Mastercam file, but the functions have since been deprecated.
  9. Not exactly. The post can access the tools slot ID, so we can look up and modify the tool using a NET-Hook and ToolNetApi.dll. However, this would not effect the NCI file that's currently being processed, only the source files tool system. What you're asking for is possible, have you contacted your reseller or CNC's post department for help? That would be my first stop.
  10. I'm allergic to VB.Net's syntax; below is a (very) basic c# example. namespace ToolNetApiExample { using Mastercam.App; using Mastercam.App.Types; using Cnc.Tool.Interop; public class Main : NetHook3App { public override MCamReturn Run(int param) { var toolSystem = TlToolFunctions.GetToolSystem(); var endMill = new TlToolEndmill() { Name = "Example .5in Reduced Shank Tool", OverallDiameter = .5, TruePhysicalLength = 4, CuttingDepth = .375, ShoulderLength = 2.0, ShoulderDiameter = .375, ArborDiameter = .5, IsMetric = false }; var toolAssembly = new TlAssembly() { MainTool = endMill, }; toolSystem.Add(toolAssembly); return MCamReturn.NoErrors; } } }
  11. Have you looked at the ToolNetApi.dll that ships with the newer versions of Mastercam?
  12. Zaffin

    Buffer Problems

    What version of Mastercam are you using?
  13. Source can be found on my GitHub.
  14. I'm posting just to remind myself to put the NET-Hook I use to trace geometry up on GitHub. It's just a modal dialogue that lists the levels used in the selected operation. Nothing fancy, but it handles most operation types.
  15. You're likely not linking the library when building. You need to tell the linker to link the library that contains the create_point_ent function you're trying to use.

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