<!DOCTYPE html
  PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<!--
Copyright (c) 2006 UGS Corp.

All Rights Reserved.

This software and related documentation are proprietary to UGS Corp.
-->
<html>
   <head>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <title>User Defined Events</title>
      <script language="javaScript">
        abridged="false";
        displayConditions=new Array();
      </script>
      <link type="text/css" href="../css/main_styles.css" rel="stylesheet">
   </head>
   <body class="bodydocs" onload="top.pageLoader()" bgcolor="#FFFFFF">
      <div class="title_topic3" id="xps10_pagetitle">User Defined Events</div>
      <hr noshade="true">
      <p class="para_topic">User Defined Events (UDEs) provide a way to capture information in a tool path, for use in the postprocessor. They can be placed at the start or end of any tool path or on an object. The most common use is in an operation, to produce post commands during output to the CLS or postprocessor. The system provides several pre-defined events for this purpose. </p>
      <p class="para_topic">You can also add your own UDEs, or modify those provided by the system, by customizing the user defined event file.</p>
      <p class="para_topic">The main steps involved in the use of UDEs are:</p>
      <ul>
         <li>
            <p class="para_item"> <a class="links" href="javascript:void(0)" onclick="top.openFile('mfggeneral/cust_user_def_ev_struc_def.html');return(false);">Defining the event structure</a> (in the ude.cdl file). 
            </p>
         </li>
         <li>
            <p class="para_item"> <a class="links" href="javascript:void(0)" onclick="top.openFile('mfggeneral/cust_def_data_events.html');return(false);">Defining the data of the event</a> (in CAM). 
            </p>
         </li>
         <li>
            <p class="para_item"> <a class="links" href="javascript:void(0)" onclick="top.openFile('mfggeneral/cust_interpr_ev_dur_outpt.html');return(false);">Interpreting the events when they are output</a> (in the postprocessor).
            </p>
         </li>
      </ul>
      <table border="0">
         <tr>
            <td valign="top" align="left"><img align="left" src="../graphics/note.gif" alt="Note" title="Note"></td>
            <td valign="bottom" align="left" width="100%">
               <div class="para_note">
                  <p class="para_note_body">If you add a UDE, you must also add the corresponding Event Handler to your postprocessor. The UDE is used to gather information inside of CAM, and the postprocessor is used to format that information for output.</p>
               </div>
            </td>
         </tr>
      </table>
      <p class="para_topic">The defining of the event structure is done as a part of defining the overall context in which machining has to take place. The events that have been specified as a part of the definition of one machine can be inherited by other machines, which use this definition, because the Machine definition file has the capability of inheritance. This is done with the INCLUDE command in the definition file. </p>
      <p class="para_topic">Using the event's structure description the event is presented wherever required during the specification of the operation parameters. When data has been specified for the events the description and the data of the event is stored. </p>
      <p class="para_topic">When the operations are posted the Machine Control UDEs specified for that operation would be output in a generic manner so that the interpretation of the events are simple.</p>
      <div class="title_division">User Defined Event File</div>
      <p class="para_division">The keyword USER_DEFINED_EVENTS in the configuration file determines the default file to be used for UDEs. This is usually ${UGII_CAM_USER_DEF_EVENT_DIR}ude.cdl.</p>
      <p class="para_division">If a library machine tool is used, then the definition file for that machine's default postprocessor can replace the default UDE file, using the following command:</p><pre class="indent">INCLUDE { $UGII_CAM_USER_DEF_EVENT_DIR/ude.cdl }</pre></body>
</html>