:: View topic - Customizing AutoCad (scripts/vba, etc...)
Posts: 15 · 15 posts
unknownSat Aug 04, 2012 11:41 pm
Hi,
I was wondering if anyone had any experience customizing AutoCAD to better suite ski design and machining. I am very familiar with using the AutoCAD command lines, and pretty familiar with using the software. I have never created a script, or a macro to run in the program. I know it can be done and is based off the command prompts.
I am interested in writing code to generate core files, template files, etc.. off of a ski outline. I am interested in doing something similar to the Solidworks add-ins described in this thread. http://skibuilders.com/phpBB2/viewtopic.php?t=3265
I know it is possible to customize AutoCAD to do just about anything, I am wondering if anyone has done this before or has any advice.
Thanks
unknownSun Aug 05, 2012 4:08 am
It is possible, but it is kind of a lost art. What you describe is basically Snocad, do you have it?
unknownSun Aug 05, 2012 11:58 am
I have SnoCAD. I'm not looking to automate the ski design process, rather the work that must be done after a ski is designed. Mainly making a core and base template file. I know its really simple, which is why it should be fairly straight forward to write a program to do this for me from my file.
unknownSun Aug 05, 2012 3:34 pm
An Excel spreadsheet could accomplish what you're looking for although it won't give a pictorial view. That's what I use, I plug in the final ski dims and it gives me the core, sidewall and shape dims. Let me know if this is what you're looking for and I'll send it to you.
unknownSun Aug 05, 2012 4:40 pm
I'd like a copy of that. Check your messages.
unknownMon Aug 06, 2012 10:05 am
Here's a Excel spreadsheet I've been using to help me figure out the dimensions for ski building, cost of materials and profit/loss calcs. Feel free to download and modify it to suite your needs.
The ski core calculator is the second sheet. Enter your finished ski/board dims in the yellow area. The rest is calculated for you. I also have some default numbers I use that are in blue. Yours maybe different.
Email me any question you may have about it.
https://docs.google.com/spreadsheet/ccc?key=0AudcfxPSiyTWdG5Ib3l6Z3RIYjg0UUNNcURvNFZuaHc
unknownMon Aug 06, 2012 4:19 pm
Wow man, pretty awesome, love the cost figuring. Awfully cool of you to share!
unknownMon Aug 06, 2012 6:19 pm
Thats the 333 speadhseet right?
kirol i think is talking about tool paths so you dont have to reprogram for every new core profile i think?
i have no idea how to ddo that
unknownTue Aug 07, 2012 2:45 am
unknownThu Aug 09, 2012 5:22 am
Yup, 333. I unprotected the cells so it's more flexible and tweaked it a bit.
btw- Was it Rich who was creating a more versatile version of SnoCAD-X?
unknownWed Aug 15, 2012 9:34 pm
Hey guys,
Thanks for the help and the spreadsheet.
What I am trying to do is automate the AutoCAD process. With every ski that is designed, a few other files are generated based off the ski file. I follow basically the exact same steps every time I make a supporting file (ie core, template, etc.
There are ways to make applications that run within AutoCAD that could automatically make all other template files by running an application or a script within the file. The problem is I don't know how to program user input from a mouse. Scripts are basically set up as a screen of keyboard commands. For actions like offset and trim that require the user to click a point or a line I am not sure how to do that with keyboard input. I consider myself to be pretty competent in AutoCAD and I feel like with some sort of example or tutorial I could figure out how to do the task I am trying to complete. I have looked at a few tutorials but none of them perform very complex tasks, they were mostly for plotting or inserting blocks. I couldn't find any tutorials or examples similar to my application.
unknownWed Sep 05, 2012 9:10 am
What you are asking is a fairly heavy coding job, not simply a string of commands.
Your best bet is to post your question on the Autodesk customization forum:
http://forums.autodesk.com/t5/AutoCAD-Customization/ct-p/1002
unknownThu Sep 06, 2012 9:36 am
They are called LISP routines. This looks to be fairly promising:
http://www.draftsperson.net/index.php?title=AutoLISP_Lesson_1_-_Introduction_to_Lisp_Programming
I have some co-workers that have created routines for monotonous tasks. I haven't completely looked through the link above, but I'll give it a read tomorrow at work and see what I can find and touch base with a few co-workers. I've been working with CAD for 10 years or so now. I've actually thought of doing a similar thing. The tough part will be the program design to break it down to its simple command forms. Could be the next revolution??! Maybe.
Thanks for the spreadsheet SD! I love me some excel.
I hope to post some progress before the snow flies!
unknown
Kirol-
Ive got some basic routines from coworkers, and some advice from them...depending on what you want to do, it could be a little complicated. Pm me if you want to talk specifics.
unknown
TahoePowder-
Thanks for the links, research and help. I plan to further pursue this later in the fall when I have more time out side of work. I have been buried lately. I read the tutorials and they seem fairly straightforward, I just need to dedicate a large block of time to this. I am definitely interested in seeing what your co workers have to say.
Thanks