- modified and improved various env. drivers

- implemented string array object
This commit is contained in:
zolliker
2006-06-20 13:29:32 +00:00
parent 8b12033cb2
commit c1bbdb935e
19 changed files with 1495 additions and 499 deletions

View File

@ -31,6 +31,7 @@ Markus Zolliker, May 2005
#include "fsm.h"
#include "initializer.h"
#define OLDIGH -8
#define SORBS_FLAG 1
#define MIXP_FLAG 2
#define STILL_FLAG 3
@ -93,11 +94,11 @@ static void IghParDef(void *object) {
ParFloat(&drv->sorbS, PAR_NAN);
ParName("Tmix");
ParTail("K"); ParFmt("%.3f");
ParTail("K"); ParFmt("%.4f");
ParFloat(&drv->mixT, PAR_NAN);
ParName("T1K");
ParTail("K"); ParFmt("%.3f");
ParTail("K"); ParFmt("%.4f");
ParFloat(&drv->onekT, PAR_NAN);
ParName("Tsorb");
@ -270,6 +271,20 @@ static long IghRead(long pc, void *object) {
if (EaseCheckDoit(eab)) goto quit;
if (eab->syntax == OLDIGH) {
EaseWrite(eab, "R3");
} else {
EaseWrite(eab, "R32");
}
return __LINE__; case __LINE__: /**********************************/
if (eab->syntax == OLDIGH) {
drv->mixT = OxiGet(eab, 3, NULL, drv->mixT);
} else {
drv->mixT = OxiGet(eab, 4, NULL, drv->mixT);
if (drv->mixT < 0) drv->mixT += 6.5536; /* correct a bug in firmware < 3.03 */
}
if (EaseCheckDoit(eab)) goto quit;
EaseWrite(eab, "R1");
return __LINE__; case __LINE__: /**********************************/
drv->sorbT = OxiGet(eab, 1, NULL, drv->sorbT);
@ -282,12 +297,6 @@ static long IghRead(long pc, void *object) {
if (EaseCheckDoit(eab)) goto quit;
EaseWrite(eab, "R3");
return __LINE__; case __LINE__: /**********************************/
drv->mixT = OxiGet(eab, 3, NULL, drv->mixT);
if (EaseCheckDoit(eab)) goto quit;
if (EaseGetUpdate(drv, MIXP_FLAG)) goto skip4;
EaseWrite(eab, "R4");
return __LINE__; case __LINE__: /**********************************/
@ -382,7 +391,11 @@ static long IghStart(long pc, void *object) {
EaseStop(eab);
goto quit;
}
eab->syntax = -8; /* special value for communication error correction */
if (strstr(eab->version, "2.01") != NULL) {
eab->syntax = OLDIGH; /* includes communication error correction */
} else {
eab->syntax = 0;
}
ParPrintf(drv, eStatus, "connected to %s", eab->version);
FsmCall(IghRead);
return __LINE__; case __LINE__: /**********************************/