We are always interested in what our customers would like to see! To request any new examples or supported languages, please email suppo.nosp@m.rt@g.nosp@m.alil..nosp@m.com.
A Galil controller is required for this example.
`*****************************************************************************`
`************************** GCmdT() example *****************************`
`*****************************************************************************`
GCmdT() will return a trimmed response of GCommand()
The command 'PR ?,?' will return the relative position of the A and B axes
<<PR ?,? with GCommand(): 0, 10000
:>>
<<PR ?,? with GCmdT(): 0, 10000>>
`*****************************************************************************`
`************************** GCmdI() example *****************************`
`*****************************************************************************`
GCmdI() will return the value of GCommand() parsed as an int
The command 'MG _LMS' will return the available space in the vector buffer of the S plane.
MG _LMS with GCmdT(): 511.0000
MG _LMS with GCmdI(): 511
`*****************************************************************************`
`************************** GCmd() example ******************************`
`*****************************************************************************`
GCmd() will execute the given command but does not return a value.
GCmd is useful for basic operations such as beginning motion or setting speed
GCmd(g, "BG A");
GCmd(g, "SP 5000");
`*****************************************************************************`
`************************** GCmdD() example *****************************`
`*****************************************************************************`
GCmdD() will return the value of GCommand parsed as a double
The command 'MG @AN[1]' will return the value of Analog Input 1
MG @AN[1] with GCmdD(): 9.7726
`*****************************************************************************`
`************************ Galil Double Format ***************************`
`*****************************************************************************`
Galil Controllers expect double values to be formatted to 4 decimal places
Unformatted double value: 0.00235
Formatted double value rounded to 4 decimal places: 0.0024
`*****************************************************************************`
`******************* G_UTIL_ERROR_CONTEXT example ***********************`
`*****************************************************************************`
GUtility() with G_UTIL_ERROR_CONTEXT: Broken Pipe