Updated to send Jz prior to any voltage setting command

r2721 | rdd | 2008-10-14 11:35:35 +1100 (Tue, 14 Oct 2008) | 3 lines
This commit is contained in:
Rodney Davies
2008-10-14 11:35:35 +11:00
committed by Douglas Clowes
parent 0adecdcec9
commit 8f95806ecc

View File

@@ -644,6 +644,10 @@ static int ORHVPSGetValue( pEVDriver self, float* fPos) {
* Set the current value from SICS
*/
static int ORHVPSSetValue( pEVDriver self, float fPos) {
char reply[CMDLEN];
int rep_len = CMDLEN;
pORHVPSDriv priv = NULL;
assert(self);
assert(self->pPrivate);
@@ -656,6 +660,9 @@ static int ORHVPSSetValue( pEVDriver self, float fPos) {
priv->iErrorCode = ORHVPS_ERR_RANGE;
return 0;
}
AsyncUnitTransact(priv->asyncUnit, "Jz", 2, reply, &rep_len);
priv->fTarget = fPos;
priv->bRunFlag = true;
return 1;