Accurate direct cylindrical gear automation preset system for drawing software


As the flagship product of CAD, AutoCAD has been adopted by design engineers all over the world because of its unique advantages. It has become a popular drawing tool in the world today. However, due to the lack of parametric design functions, the software cannot parametrically design and draw parts, which results in a large workload for designers and difficulty in improving design efficiency. In this paper, the standard spur gear of the reducer is taken as an example to illustrate the method and steps of applying the VisualBasic language to the secondary development of AutoCAD to realize the parameter design of the gear.
1VB on the principle of secondary development of AutoCAD AutoCAD has an open structure system and powerful user customization functions, providing users with a variety of secondary development tools and methods, to facilitate users to solve practical problems according to their own ideas. Based on AutoCAD ActiveX automation technology, VB language can easily realize the access and control of AutoCAD objects, so that it can efficiently and quickly develop an application software system with powerful functions and rich graphical interfaces in Windows environment.
All the hierarchies that AutoCAD uses for VB objects are defined in the AutoCAD object model. Application is the basis of the object model. The Application object accesses the AutoCAD drawing through the Documents collection, accesses the AutoCAD menu through the MenuBar collection, accesses the AutoCAD toolbar through the MenuGroups collection, and accesses the settings in the AutoCAD Options dialog box in the registry through the Preferences object.
2 Gear mechanical design method Gears are widely used in engineering. Considering that the gears in common gear reducers are usually the case of closed transmissions, the design calculation of the gears can be divided into two types: 1) soft toothed closed gear transmission. The main failure mode of the gear is the tooth surface fatigue pitting. The design should first calculate the pinion diameter according to the tooth surface contact fatigue strength, and then use the root bending fatigue strength to check.
2) Hard toothed closed gear transmission. The main failure mode of the gear is the bending and fracture of the tooth root. The design should first calculate the modulus according to the bending fatigue strength of the tooth root, and then check the fatigue strength of the tooth surface contact.
3 system composition and user interface 3.1 system workflow According to the gear design steps, the system completes the parametric design of the gear according to the process.
3.2 User Interface To facilitate user interaction with the system, the system has the user interaction interface shown.
The initial design condition function module adopts the text library form for the user to input the known parameters, including the transmission power, the rotational speed, the number of teeth, the transmission ratio, etc.; the combo box control is used to list the common gear materials, the heat treatment process parameters optimization method and the hardness of the heat treatment gas furnace For user convenience.
According to the material selected by the user and the hardness of the gear, two functional modules are designed through the tooth surface contact fatigue strength design and the root bending fatigue strength to realize the design of the soft tooth surface gear and the hard tooth surface gear. The geometric size function module outputs the basic size parameters of the drive gear and the driven gear. Click the Draw button to automatically create an AutoCAD file and output a 2D drawing of the gear.
4 Gear Parametric Design Implementation 4.1 Creating References to AutoCAD Component Objects When using VB to redevelop AutoCAD, first create a reference to the AutoCAD component object. Implementation steps: 1) Reference AutoCAD type library. Open the project menu, select the reference command, and select AutoCAD2006TypeLibrary in the dialog box.
2) Declare the object variable. Write the following statement at the general declaration section of the program: DimAcadAppAsAcadApplication.
3) Assign object references to variables.
4.2 Data Processing Gear geometry calculation is one of the key steps to achieve parametric design. Detailed calculation procedures and calculation formulas can be found in the relevant manuals and literature. In the process of gear design, you need to find a large number of charts. According to whether the data source is a discrete table or a continuous curve, the system uses different algorithms to realize the automatic query function of parameters. The following is an example of the design of the relevant parameters by taking the design of the tooth surface contact fatigue strength as an example.
Calculate the formula of the pinion index circle diameter d1 according to the tooth surface contact fatigue strength [5]: d1=Kd3T1KdH2u1u where the tooth width coefficient d is a discrete table, see the value. For discrete data, first store the data in the table in a static array, and then write the program in VB language to realize the query of the table and directly call the relevant data. The load concentration factor K is a continuous curve. For such continuous curves, first discretize them, and d takes a value of 0.1 for each interval and stores it in a static array. In the actual programming implementation, the interpolation is used according to the specific value of d.
4.3 Drawing of the part drawing In the click event of the drawing button, add the following statement: SetAcadApp=CreateObject(AutoCAD.Application) creates a new AutoCAD file and assigns the object reference 30 to the object variable. Continue writing code to complete the following functions: set the layer and color, line type and line width; draw the center line; create and edit optimized multi-line segments to form the gear profile; create a pattern fill object; create and edit the dimension.
5 Application example Design a gear structure in a standard spur gear reducer. It is known that the transmission power is 4kW, the driving gear speed is 960r/min, the transmission ratio is 3, the arrangement is symmetrical, the load is stable, the daily work is 8h, the work is 300 days per year, and the service life is 10 years.
1) Select the gear material. Select input gear material is 45 steel, quenching and tempering treatment, hardness 300HBS; output gear material is 40Cr, surface quenching, hardness 48HBC. Input drive gear shaft diameter 20mm, joint flat key size is 6mm6mm and the above known parameters, the system prompts soft Tooth surface gear, designed according to the tooth surface contact fatigue strength.
2) Click the calculation button in the tooth surface contact fatigue strength design frame to output the contact stress of the two gears and the geometric parameters of the two gears.
Output gear geometry mm geometry parameter drive gear driven gear index circle diameter 39117 tooth root circle diameter 37.75113.75 tooth tip circle diameter 41.6119.6 gear width 4139 modulus 1.33) Click the check button, the system according to the above calculation results The bending stress is checked to obtain a conclusion that the bending strength is sufficient.
4) Click the Draw button to draw the structure of the drive gear as shown.
Gear structure 6 concludes with Visual Basic as a development tool, and secondary development of AutoCAD to achieve parametric design of gear parts. Practice has proved that by making full use of object-oriented development technology and AutoCAD and Windows resources, it is possible to develop application software that is more suitable for the industry, to achieve parametric design of parts, thereby improving design efficiency.

Stainless Steel Nuts

Stainless Steel T Nut,Stainless Steel Hex Nut,Stainless Steel Butterfly Nut

Lug Nuts,Bolts,Screws,Nuts Co., Ltd. , http://www.nswheelnuts.com