Computer-aided Design for the Route of the Test Waveguides

With the rapid development of China's space industry, digitization and intelligent is the tendency of the future. The applications of the waveguide are gradually widespread. During the thermal test phase, the routes of the test waveguides are similar for each spacecraft. Although the waveguides are highly standardized, so far it needs engineers to design the particular route of the test waveguidess, then map the engineering drawing for every test. In order to efficiently design the route of waveguide, it needs to design an application to help the engineers. With the help of the MFC(Microsoft Foundation Classes) and the pro/toolkit, it is easily to do the modeling and simulation. After automatic design the particular the route of the waveguide, the API of AutoCAD type library is used to help to modify the engineer drawing. Engineers can supervise every step of this application, and easily to modify the key parameters.


Introduction
Waveguides are widely used in spacecraft such as satellites, space station and so on.Just like coaxial cables, the function of the waveguide is to transmit the signal.Compare with the coaxial cable, the advantage of waveguide is lower attenuation and high power [1].Especially in the high frequency the above two advantages are obvious.The standing wave and the insertion loss of the waveguide are good.
To ensure the spacecraft can work normally, before the launch of the spacecraft, it needs to be test.During the test, the spacecraft is deposited in a sealed container.To receive the signal of the spacecraft, waveguides need to be applied.There are dozens of test every year, the waveguide path needs to be redesigned for each test.It will consume engineers a lot of time and effort to design the test waveguides route and engineer drawings.The waveguide is highly standardized and the routes of the waveguide are similar, so the computer-aided design technology can be used to help engineers design the routes of the test waveguides.This report is present a foundation research about the computer-aided design technology which based on the Pro/E secondary development tool (Pro/toolkit) and AutoCAD secondary development API (AutoCAD type library), with the help such technologies the route of waveguides can be automatic designed easily, in a result of labour saving.

Design preparation
Computer-aided design technology will liberate engineers from a lot of repetitive work.It can improve the design efficiency and reduce wasted time greatly.In this paper, engineers set some boundary conditions and parameters.Then the program runs automatically according to the above conditions and interact with the model library.Afterward it will design and assemble the test waveguides with the help of Pro/Toolkit.Finally, it will mapping the engineer drawings.The system architecture is shown in Figure .1.

Pro/E secondary development
Pro/Engineer provides powerful three-dimensional geometric modelling capabilities that creates complex models.Sometimes these features can't suit the design requirements.For example the standard parts, their structure is the similar, the difference is only their size.The most effective method is to use the similarity of standard parts and Take advantage of its parametric design.Using the secondary development tool such as Pro/toolkit to improve design efficiency [2].
There are several methods to realize Pro/Engineer secondary development, the most popular method is using Pro/toolkit.To interact with Pro/Engineer, the specific version of Visual Studio need to correspond to the specific version of Pro/E, otherwise the built DLL file can't interact with Pro/E.In this paper the programing environment is Visual Studio 2008, programing language is C++.Using the function of MFC DLL to build DLL file and dynamic link with Pro/E.Microsoft Foundation Classes(MFC) is a class libraries, it encapsulate Windows API, it Contains an application framework to reduce the workload for application developers.The version of Pro/E is Creo Element Pro/E 5.0, and the revision is 18.
When doing spacecraft experiments, the spacecraft is fixed on a bracket and deposited in a sealed container.The test waveguidess need to connect to the spacecraft and pass through the sealed flange.As it is shown in the figure 2 that the translucent part is the sealed container, the red colour part is test waveguides, the blue colour part is a bracket, and the grey colour part is sealed flange.The test waveguidess are standard parts, their structure and route are the similar.This paper will present a method to help engineers to design this test waveguides path easily.To fulfil this goal, some factors need to be sure.Firstly, the coordinate relationship of sealed flange, the bracket and the test waveguides connection point.Secondly the number and type of waveguides.Lastly, the route of the test waveguides.
The structure of Pro/toolkit program begin with 'int user_initialize()', it is the initializing program of the Pro/toolkit program, users can create the interactive interface in this function such as creating menu.The function 'int user_terminate()' invocated when users terminate synchronized mode [3].
To create a friendly human-machine interface (HMI), the menus are essential.The menu is created by the function ProMenubarMenuAdd () in the Pro/toolkit.The action is defined in the function ProCmdActionAdd () [3].With the help of such functions, users can create a friend HMI and interact with Pro/E.
To generate the test waveguides path, engineer needs to know the coordinates of the sealed flange and the test waveguides connection point.The function ProSelect() is an interface function when user select a part this function return a mark to the program.Then the function ProAsmcomppathTrfGet() will be used, the capabilities of this function is get the correspondence relation between part coordinate system and component coordinate system, the return value of this function is a matrix (ProMatrix()),a four-order matrix, The first three lines of the matrix describes the relative orientation of the two coordinate systems, the last line describe the translation of the two coordinate systems.ProMatrix()41, ProMatrix()42, ProMatrix()43 represents the translation of the x,y,z axis, respectively [4].
To calculating the number of the test waveguides, the function ProAsmcompMdlGet() can be used.The main program will use this function to traverse the whole assembly model, then output the name of each part in the assembly model.Then the number of test waveguidess can be calculated by looping method [5].
To realize the goal of designing the test waveguides path, parts assembly is necessary.The assembling matrix ProMatrix() is also needs to be used to define the boundary condition such as translation distance , rotation angle and so on.The function ProAsmcompconstraintAsmreferenceSet() is used to define the reference assembly.The constrain type can be defined by the function ProAsmcompconstraintTypeSet() such as point constrain, linear constrain, plane constrain, axis constrain and coordinate constrain and so on [6].With help of the functions above, the test waveguides can be assembled according the route design algorithm.

MATEC Web of Conferences
Usually the test waveguidess is divided into five sections, each section is a strict line, so the route of the waveguides can be simplified by a mathematical model.The functions of the route design algorithm is described below.
In the above functions S1X is the first section X coordinate position, S1Y is the first section Y coordinate position, S1Z is the first section Z coordinate position.WX is the X coordinate position of test waveguides connection point, WY is the Y coordinate position of test waveguides connection point, WZ is the Z coordinate position of test waveguides connection point.BZ is the Z-direction length of the bracket.L1 is the length of the first section of the test waveguides.
In the above functions S5X is the fifth section X coordinate position, S5Y is the fifth section Y coordinate position, S5Z is the fifth section Z coordinate position, S4X is the fourth section X coordinate position, S4Y is the fourth section Y coordinate position, S4Z is the fourth section Z coordinate position.FX is the length of the bracket X-direction.L5 is the length of the first section test waveguides.
The other three sections are similar to the two sections presented above.

AutoCAD development
As it is shown in the figure 3 that the engineer drawing of the waveguide isn't complicated.Because the waveguides are standard parts, so if the type of the waveguide can be definite.Then the engineer drawing template can be chosen according to the specific type of waveguide.The geometric tolerance, surface roughness, constraint, the size of flange and waveguide wall are same for different engineer drawing.The different parts are length of the waveguide, the quantity text and the length text in the table text.
There are many methods to do AutoCAD secondary development, such as VB, ObjectARX For AutoCAD R14, Auto Lisp, ADS and .Net.Because of its simplicity, high fault-tolerant rate and friendly HMI, VB is widely used.
When the windows form application is designed completive then it needs to connect to the AutoCAD.
Adding the reference of AtuoCAD 2014 Type Library and AutoCAD/ObjectDBX Common 19.0 Type Library in the COM menu.Using the function Acaddoc.ModelSpace.AddText() to add the text of quantity and length in the template form [7].

Conclusion and improvement
During the study of this project, the basis of computer-aided design for the route of the test waveguides has been outlined.With the help of this research the design efficiency of engineers can be improved greatly and the repetitive works can be reduce greatly.Some basic concept about the Pro/E secondary development has been elaborated.Also, there a lot of things can be improved about this research.For example, the path of the test waveguides which connected to the hydro-cooling load, such path needs to install closely to the spacecraft surface, there are a lot of protuberance on the spacecraft surface, so the obstacle avoidance algorithm can to be added.The hydro-cooling load automatic assemble algorithm can be add.These will be improved in the later works.

Figure 2 .
Simulating Test waveguides Assembly

Figure 3 .
Engineer Drawing template of Waveguides