GMServer - This is the TCP/IP server which dynamically loads the third party DLLs that communicate with the hardware (interface-supported devices). The ManualCMM.dll behaves as a TCP/IP client to this server.
Configuration of GMServer - GMS.XML
INTERFACE - This is a mandatory section of the XML file. The supported interfaces are:
ENC7360
ENC7480
SCAZONPCI
SIMULATOR
TECH80PCI
XNPCI
TCPPortNumber - This parameter is optional. It defines the TCP port that the GMS uses to communicate with the ManualCMM.dll. The default port is 1390.
WINDOW_HIDE_SHOW - This parameter shows or hides the GMServer dialog box. You can use this parameter to test if you set this parameter to SHOW.
POLL_TIME - This parameter sets the time interval for when the GMServer executes. It polls the status of hardware. The default value is 50ms.
HitBeepFrequency - This parameter sets the frequency of the sound in hertz. The valid values for this parameter is 37 through 32,767 (0x25 through 0x7FFF) inclusive. Set it to 0 to switch off the sound.
HitBeepDurationMS - This parameter sets the duration of the sound in ms after you take the hit. It uses the Windows API call Beep.
Example of a complete GMS.XML file using HitBeepFrequency and HitBeepDurationMS
DEBUG - This parameter defines the name of the file with information you can use to troubleshoot.
INTERFACES - This parameter defines the following:
Type - one of SIMULATOR, ENC7480, ENC7360, TECH80PCI, SCAZONPCI, XNPCI
Config - GMS7480.XML for ENC7480 card
DLL - ENC7480.DLL for ENC7480 card
Axis - for each number defines X, Y, Z, or W. This definition allows 2 different cards
Example for ENC7480 With a Main Window Visible (Debugging Mode)
<GMS>
<!--Server listens on this TCP port-->
<TCPPortNumber>1390</TCPPortNumber>
<!--HIDE or SHOW GMServer window-->
<WINDOW_HIDE_SHOW>SHOW</WINDOW_HIDE_SHOW>
<!--POLL_TIME poll time of the card (default 250ms)-->
<POLL_TIME>20</POLL_TIME>
<!--INTERFACES -SIMULATOR,ENC7480,ENC7360, TECH80PCI, SCAZONPCI, XNPCI-->
<INTERFACES>
<Interface>
<Type>ENC7480</Type>
<Config>GMSENC7480.XML</Config>
<Dll>ENC7480.DLL</Dll>
<Axis number="0">X</Axis>
<Axis number="1">Y</Axis>
<Axis number="2">Z</Axis>
<Axis number="3">W</Axis>
</Interface>
</INTERFACES>
<DEBUG>gm_debug.txt</DEBUG>
</GMS>
Based on the value, INTERFACE various DLLs which interface to devices are expected and configuration XML files are processed:
Interface |
DLL |
ENC7360 |
ENC7360 |
ENC7480 |
ENC7480.dll |
SCAZONPCI |
SCAZONPCI |
SIMULATOR |
GmsSimulator.dll |
TECH80PCI |
TECH80.dll |
XNPCI |
XNPCI09.DLL |
Command Line Options for GMServer.exe
/R or /r was added in version 1.0.15 for resetting the counters to zero. The ManualCMM.dll displays the dialog box which also calls the GMServer.exe with the parameter /R.
1.1. GmsSimulator.XML
Implemented and tested the ability to define BUTTONS for the GmsSimulator. For details, see "ManualCMM.dll Configuration GMICONFIGDATA.XML for ENC7480 and GmsSimulator".
1.2. GmsENC7480.XML
Hardware group:
The first five options are hardware related. The default values are the bold values that follow the options. For detailed information on how to use the ENC7480 and the Demo software, please see “User’s Manual for the ENC7480”. You can find this on the manufacturer’s website (http://www.leadshine.com).
Use ENC7480.exe to establish and test/debug the settings for the ENC7480. The PC-DMIS interface directly maps the settings from DEMO software.
SetTriggerLogic - RISING_EDGE or FALLING_EDGE
CountConfig - MODE_PULSE_DIRECTION (general mode) or MODE_ONE_AB_PHASE or MODE_TWO_AB_PHASE or MODE_FOUR_AB_PHASE.
EZLogic - DISABLED or ENABLED
SetEZLogic - ACTIVE_LOW or ACTIVE_HIGH
TriggerChannel - TR_1 or TR_2
Counts group:
The encoder card returns distance in counts, which have to be converted to millimeters. The sign of this value is used to set up the correct axis orientation:
X+ back to front
Y+ left to right
Z+ down to up.
You can use the GMServer.exe dialog box to establish these values. To do this, from the dialog box, select the Always monitor hits check box, then take hits on a qualification sphere of known diameter.
The dialog box displays the positions for the hits and the corresponding vectors. Rotary table support adds the W_COUNT_PER_TURN parameter which is the number of counts for a 360-degree turn.
X_COUNTS_PER_MM
Y_COUNTS_PER_MM
Z_COUNTS_PER_MM
W_COUNTS_PER_TURN
Point history group:
POINT_HISTORY - This parameter is the number of points kept by GMSServer for the ENC7480 last 20 positions. The default is 20.
CAL_VEC_DEPTH - This parameter is the offset point history which is used to calculate the vector. The default is 5.
VECTOR_SENSITIVITY - When the distance (in millimeters) between current position and the point taken from the point history on CAL_VEC_DEPTH is smaller than VECTOR_SENSITIVITY, the first point in the history which satisfies this distance condition is used for the vector calculation. The default is 0.0 mm.
Example:
<GmsENC7480>
<Card number="0">
<SetTriggerLogic>RISING_EDGE</SetTriggerLogic>
<CountConfig>MODE_FOUR_AB_PHASE</CountConfig>
<EZLogic>DISABLED</EZLogic>
<SetEZLogic>ACTIVE_LOW</SetEZLogic>
<TriggerChannel>TR_1</TriggerChannel>
<X_COUNTS_PER_MM>-2500</X_COUNTS_PER_MM>
<Y_COUNTS_PER_MM>2500</Y_COUNTS_PER_MM>
<Z_COUNTS_PER_MM>2500</Z_COUNTS_PER_MM>
<W_COUNTS_PER_TURN>3600</ W_COUNTS_PER_TURN>
<POINT_HISTORY>20</POINT_HISTORY>
<CAL_VEC_DEPTH>5</CAL_VEC_DEPTH>
<VECTOR_SENSITIVITY>0.5</VECTOR_SENSITIVITY>
</Card>
</GmsENC7480>