neodd70 Posted April 27, 2018 Share Posted April 27, 2018 Its a complicated question, is it comparing one object or all Objects to each other ? BIGAL .... thanks for the quick response. It would be comparing all the objects to each other. What we have is a nest of parts to be cut on a CNC Router. All the objects are at the same elevation and they all need to be separated from each other with a minimum spacing of .625 otherwise while cutting one part the router bit could cut into another part. Just looking at the screen doesn't work because you can't tell the difference between .625 and .5 just by looking at it in a sea of parts and measuring each part to a part it's next to is very time consuming. The minDist Lisp is a step in the right direction but comparing the distance between only 2 parts at a time could also become time consuming and you could possibly miss 2 parts when there are say 30 parts on the screen parts in the nest. Being able to window select all the parts and run the Lisp once would be ideal. Also having a default dim to check against but being able to enter an alternate dimension would be also very helpful. Quote Link to comment Share on other sites More sharing options...
pendean Posted April 27, 2018 Share Posted April 27, 2018 It would be comparing all the objects to each other. Post sample DWG file please Quote Link to comment Share on other sites More sharing options...
neodd70 Posted April 27, 2018 Share Posted April 27, 2018 Here is one of our moderate size files. They get more and less complicated from here. sample.dwg Quote Link to comment Share on other sites More sharing options...
MikeScott Posted April 28, 2018 Share Posted April 28, 2018 My programming is weak, but one thing which might help would be to offset the profile by .3125 (half of the allowed distance) and then use something to detect collisions between them? Never tried using AutoCad to nest before.. I usually have the CAM do that. (JetCam, Radan, etc). You might want to check out a CNC forum site to see if there's a free or cheap one. I believe there's some for routing. There's another post here, with ReMark throwing some good advice around on the subject, along with links. http://www.cadtutor.net/forum/showthread.php?66294-cnc-nesting Quote Link to comment Share on other sites More sharing options...
neodd70 Posted April 28, 2018 Share Posted April 28, 2018 My programming is weak, but one thing which might help would be to offset the profile by .3125 (half of the allowed distance) and then use something to detect collisions between them? Never tried using AutoCad to nest before.. I usually have the CAM do that. (JetCam, Radan, etc). You might want to check out a CNC forum site to see if there's a free or cheap one. I believe there's some for routing. My programming is very weak so not sure how I would do that. We actually do allow the CAM software to do some of the nesting but the rest is done by the Engineers. The CAM software we use is an AutoCAD Plugin called RouterCIM. All the shapes of each part get assigned a specific uniquely named layer whether it be for a drill, mill, pocket, outside cut or inside cut plus many others. Each layer tells RouterCIM what bit to use and what the speeds and feeds are plus other info. There are so many parts being cut every night that 1 person wouldn't be able to program them all so all of our Design Engineers are also programmers. Each job that we work on requires the parts for that job to be nested together in their appropriate materials. Each job could have between 1 and a dozen different programs depending on how many different materials are in that specific job. Then each of those nests are handed off to another person that runs RouterCIM and all the different nests of the same material are then nested together by RouterCIM to fill 1 or multiple sheets. We have 9 Design Engineers all designing and programming sometimes up to 10 to 15 jobs a day and one of the things that gets overlooked or programmed incorrectly is the clearance between parts. I have pieced together some simple Lisp routines to help in speeding up some of the items on our programming check list but this one seems to be a hard one to resolve without having a routine handle it. Quote Link to comment Share on other sites More sharing options...
BIGAL Posted April 29, 2018 Share Posted April 29, 2018 Like mikescott two offsets and use Intersectwith if true then to close. example of intersectwith (setq intpt1 (vlax-invoke obj2 'intersectWith obj1 acExtendThisEntity)) so if intpt1 is false then ok. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.