esp_set_soft_limits Define Software Travel Limits
esp_get_soft_limits Report Software Travel Limits Setting
Synopsis:
Arguments:
Library Location:
Description:
Returns:
Usage Example:
See Also:
Section 5 — Programming
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com
#include "esp6000.h"
int esp_set_soft_limit(long axis, double negative, double positive)
int esp_get_soft_limit(long axis, double *negative, double *positive)
double leftpos
left software travel limit absolute position in user units
double rightpos
right software travel limit absolute position in user units
\esp6000.dll
esp_set_soft_limit() defines the right and left software travel limit for the specified axis.
Software travel limits are referenced to absolute position zero(0), or home position after
homing has been performed.
Normally, after a system reset, the stage is first homed so that software travel limits are
referenced to a known, repeatable location.
Software limits help prevent inadvertent travel into stage hardware limits.
esp_get_soft_limit() reports the right and left software travel limit setting for the
specified axis.
Software travel limits are ignored during homing mode.
ESPOK, ESPERROR
Hint:
#include "esp6000.h"
main()
{
long error, servotick;
if (!esp_init_system())
{
printf("ESP6000 Not Initialized! \r\n");
exit(-1);
}
/* Define Axis 1 Software Travel Limits */
esp_set_soft_limit(1, -100.0, +100.0);
/* Abort Motion & Flag Error On Software Limit */
esp_set_softlimit_config(1, 0x0000000d);
/* Save Parameters To ESP6000 Flash EPROM */
esp_save_parameters();
/* check error status */
esp_get_error_num(&error,&ServoTick) ;
if (error) printf("Error %d Reported!\r\n", error);
}
esp_set_softlimit_config(), esp_find_home()
NOTE
5-67