×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

screw threads or other spirals

screw threads or other spirals

screw threads or other spirals

(OP)
I am relatively new to using AutoCAD, and have come across a couple things that I can't find in the user's guide and have me stumped. Main question for today: how do I make screw threads? I've assumed that it needs do some sort of revolving and extruding at the same time but I am completely at a loss as to where to start. Any advice is greatly appreciated...

Version is AutoCAD 2000 if that matters

RE: screw threads or other spirals

I have typically done threads or springs by drawing a 3d polyline and then extruding the profile along the polyline.  However, you cannot extrude around a splined or fit 3d polyline, only the original 3d poly with straight line segments.  To draw the 3d polyline, I typically calculate the coordinates in Excel, then export them in comma separated value (CSV) format to MS Word.  In Word, on the first line add the 3dpoly command.  Save as plain text format with .scr file extension.  Then from withing Autocad type script, and select the file.  The script will run and draw your 3d polyline.

RE: screw threads or other spirals

THREADS FROM 3D SOLIDS

The following Lisp routine illustrates the procedure or combining the usual solids (cone, cylinder) to produce a 3D thread. The sequence illustrates how other solids may similarly be produced. I tested it and found OK.

Hope this is useful.

;-------------------------------------------------------------------
; THREAD.LSP   Creates 3D solid (ACIS) threads.          
; written by: Jim Fitzgerald
;-------------------------------------------------------------------
; This is a way to make 3D solid external threads in
; AutoCAD R13 and R14. Just so you know, it's not
; geometrically correct, but it's pretty darn close.
; There is no error trapping or anything like that.
;
; You are prompted for the Nominal thread size
; (actual size like .190 or .112, not #10, #4, etc..),
; threads per inch (tpi), the total length of the thread, and a
; center point. The program works by creating a single thread
; and then arraying it out to the proper length. The threads are
; drawn a little long and then sliced off to the correct length.
; This program only draws the thread, you're on your own drawing
; the rest of the screw. For internal threads, just subtract this from
; another solid.
;
; Note, the threads created by this can make for some rather big files,
; so make sure your system is up to it. Also, it might take a while
; to union all of the single threads together so be patient.
;
;-------------------------------------------------------------------
; This is freeware. Do what you want with it. If you modify it,
; please take my name off of it so I don't have to support your
; software.
;
; All the typical legal stuff applies. I make no claims that
; this actually works. Use it at your own risk. You can't sue me
; for any problems that you have as a result of using this
; (either personal or professional). Don't drink and
; drive. Eat your vegetables, and call your mother.
;-------------------------------------------------------------------

(defun c:thread ( / nom pitch length cpt total pt1 pt1z pt2 pt3 ang pt1a
pt1az pt3a pt1b pt1bz pt3b pt4 pt4 pt6 pt7 pt8 pt9 pt10 pt11 pt12 ss
osm)

   ;-------------------------------------------------------------------
   ; Gets the nominal size, tpi, and total length
   ; then calculates a bunch of geometry points.
   ; All running osnaps are turned off as well.
   ;-------------------------------------------------------------------

   (setq nom (getdist "\nNominal size: ")
      pitch (/ 1.0 (getreal "\nThreads per Inch: "))
      length (getdist "\nTotal thread length: ")
      cpt (getpoint "Center point: ")
      total (+ (fix (/ length pitch)) 2)
      pt1 (list (- (car cpt) (/ nom 2.0)) (cadr cpt))
      pt1z (list (- (car cpt) (/ nom 2.0)) (cadr cpt) 1.0)
      pt2 (polar pt1 (/ (* 30.0 pi) 180.0) 0.1)
      pt3 (list (+ (car pt1) nom) (+ (cadr pt1) (/ pitch 2.0)))
      ang (angle pt1 pt3)
      pt1a (polar pt1 (+ ang (/ pi 2.0)) pitch)
      pt1az (list (car pt1a) (cadr pt1a) 1.0)
      pt3a (polar pt1a ang nom)
      pt1b (polar pt1 (- ang (/ pi 2.0)) pitch)
      pt1bz (list (car pt1b) (cadr pt1b) 1.0)
      pt3b (polar pt1b ang nom)
      pt4 (polar pt3 (/ (* 150.0 pi) 180.0) 0.1)
      pt5 (inters pt1 pt2 pt3 pt4 nil)
      pt6 (list (car pt5) (cadr cpt))
      pt7 (polar pt1 (/ (* 330.0 pi) 180.0) 0.1)
      pt8 (polar pt3 (/ (* 210.0 pi) 180.0) 0.1)
      pt9 (inters pt1 pt7 pt3 pt8 nil)
      pt10 (list (car pt9) (cadr pt3))
      pt11 (polar cpt (/ pi 2.0) pitch)
      pt12 (polar pt11 (/ pi 2.0) length)
      osm (getvar "osmode")
   )
   (setvar "osmode" 0)

   ;-------------------------------------------------------------------
   ; Draws two cones which are inverted and offset 1/2 the pitch.
   ; The cones are each sliced at the angle of the crest line
   ; and then unioned together
   ;-------------------------------------------------------------------
   (princ "\nCreating thread...this might take a while.")
   (command "pline" pt1 pt5 pt6 "c")
   (command "revolve" "l" "" pt5 pt6 "")
   (command "slice" "l" "" pt1 pt3 pt1z pt5)
   (command "slice" "l" "" pt1a pt3a pt1az pt3)
   (setq ss (ssadd (entlast)))
   (command "pline" pt3 pt9 pt10 "c")
   (command "revolve" "l" "" pt9 pt10 "")
   (command "slice" "l" "" pt1 pt3 pt1z pt9)
   (command "slice" "l" "" pt1b pt3b pt1bz pt3)
   (setq ss (ssadd (entlast) ss))
   (command "union" ss "")
   ;-------------------------------------------------------------------
   ; This above solid is sliced in half and then mirrored. This
   ; creates the "helix" in the thread. The height of the single
   ; thread is actually equal to twice the pitch, but the
   ; excess is either absorbed or cut off in the last step
   ;-------------------------------------------------------------------

   (command "slice" ss "" "xy" cpt "b")
   (setq ss (ssadd (entlast) ss))
   (command "mirror" "l" "" pt1 "@10<0" "y")
   (command "union" ss "")
   ;-------------------------------------------------------------------
   ; The thread is arrayed and then unioned together (this part can
   ; take a while). The resulting solid is cut to the specified length.
   ;-------------------------------------------------------------------
   (setq e (entlast))
   (command "array" ss "" "r" total 1 pitch)
   (repeat (1- total)
      (setq e (entnext e)
         ss (ssadd e ss)
      )
   )
   (command "union" ss "")
   (command "slice" "l" "" "zx" pt11 pt12)
   (command "slice" "l" "" "zx" pt12 pt11)
   (princ "\nDone")
   (setvar "osmode" osm)
   (princ)
)

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources