Newport ESP6000 User Manual page 177

Motion controller/driver
Table of Contents

Advertisement

5.4.4 Error Handling
The ESP6000 maintains a 10-word, First-In, First-Out (FIFO) buffer error
message. Errors encountered are stored in the order received along with
a 'servo tick' time-stamp. The default servo tick resolution is 409msec.
Most ESP6000 API function calls return a value, -1 (error exists) or 0 (no
error exists), which indicate whether an error has been detected or not.
However, because the ESP6000 board queues commands, the returned
value is not a direct indicator of function correctness. The returned value
only indicates that an unread error now exists in the error buffer. The
error may be the result of a previous function call.
NOTE
A returned -1 value only indicates that an unread error now exists in the
error buffer. The error may be the result of a previous API function call.
There are two (2) dedicated functions for checking errors. The first is
esp_get_error_string(char *Error, long *ErrorNum, long *ServoTick).
ErrorNum (if non-zero) will contain the error number that has occurred.
The ErrorString will contain a text message corresponding to the ErrorNum.
The tick count is the value of the Servo Clock counter at the time of the
error. The second function, esp_get_error_num(long *error, long
*ServoTick) works like the previous function without the text message.
Error checking should be done after critical API function calls within the
application program. Error checking is most commonly performed after
'block' API calls to verify that all commands were transmitted and
properly executed.
When an error is detected (i.e., ErrorNum equals non-zero) the application
should flush the error queue by calling the error-checking API functions
calls until ErrorNum equals 0.
Section 5 — Programming
5-111
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com

Advertisement

Table of Contents
loading

This manual is also suitable for:

Unidrive6000

Table of Contents