16 #ifndef usertempcontrolH
17 #define usertempcontrolH
19 #include "tempcontrol.h"
20 #include "oxforddriver.h"
21 #include "chardevicedriver.h"
26 XITC503(
const char *name,
bool runtime,
27 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
32 virtual double getRaw(shared_ptr<XChannel> &channel);
34 virtual double getTemp(shared_ptr<XChannel> &channel);
37 virtual double getHeater(
unsigned int loop);
44 virtual
void onPChanged(
unsigned int loop,
double p);
45 virtual
void onIChanged(
unsigned int loop,
double i);
46 virtual
void onDChanged(
unsigned int loop,
double d);
47 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
48 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
49 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
50 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
51 virtual
void onPowerMaxChanged(
unsigned int,
double v) {}
52 virtual void onPowerMinChanged(
unsigned int,
double v) {}
53 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
55 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
63 XAVS47IB(
const char *name,
bool runtime,
64 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
69 virtual double getRaw(shared_ptr<XChannel> &channel);
71 virtual double getTemp(shared_ptr<XChannel> &channel);
74 virtual double getHeater(
unsigned int loop);
83 virtual
void onPChanged(
unsigned int loop,
double p);
84 virtual
void onIChanged(
unsigned int loop,
double i);
85 virtual
void onDChanged(
unsigned int loop,
double d);
86 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
87 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
88 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
89 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
90 virtual
void onPowerMaxChanged(
unsigned int,
double v) {}
91 virtual void onPowerMinChanged(
unsigned int,
double v) {}
92 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
94 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
97 double read(
const char *str);
99 void setTemp(
double temp);
100 void setHeaterMode(
int ) {}
103 int setRange(
unsigned int range);
107 int setBias(
unsigned int bias);
108 void setPowerRange(
int range);
110 int m_autorange_wait;
118 virtual void send(
const XString &str)
throw (
XCommError &) { ::msecsleep(20); XCharInterface::send(str);}
119 virtual void send(
const char *str)
throw (
XCommError &) { ::msecsleep(20); XCharInterface::send(str);}
120 virtual void write(
const char *sendbuf,
int size)
throw (
XCommError &) { ::msecsleep(20); XCharInterface::write(sendbuf, size);}
126 XCryocon(
const char *name,
bool runtime,
127 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
133 virtual double getRaw(shared_ptr<XChannel> &channel);
135 virtual double getTemp(shared_ptr<XChannel> &channel);
138 virtual double getHeater(
unsigned int loop);
145 virtual
void onPChanged(
unsigned int loop,
double p);
146 virtual
void onIChanged(
unsigned int loop,
double i);
147 virtual
void onDChanged(
unsigned int loop,
double d);
148 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
149 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
150 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
151 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
152 virtual
void onPowerMinChanged(
unsigned int loop,
double v) {}
153 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
155 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
157 void setTemp(
unsigned int loop,
double temp);
159 void setHeaterMode(
unsigned int loop);
160 void getChannel(
unsigned int loop);
163 double getInput(shared_ptr<XChannel> &channel);
164 int setHeaterSetPoint(
unsigned int loop,
double value);
166 virtual const char *loopString(
unsigned int loop) = 0;
173 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
180 virtual void onPowerMaxChanged(
unsigned int loop,
double v);
181 virtual const char *loopString(
unsigned int loop) {
182 return (loop == 0) ?
"LOOP 1" :
"LOOP 2";
190 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
197 virtual void onPowerMaxChanged(
unsigned int loop,
double v) {}
198 virtual const char *loopString(
unsigned int loop) {
199 return (loop == 0) ?
"HEATER" :
"AOUT";
207 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
212 virtual double getRaw(shared_ptr<XChannel> &channel);
214 virtual double getTemp(shared_ptr<XChannel> &channel);
217 virtual double getHeater(
unsigned int loop);
224 virtual
void onPChanged(
unsigned int loop,
double p);
225 virtual
void onIChanged(
unsigned int loop,
double i);
226 virtual
void onDChanged(
unsigned int loop,
double d);
227 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
228 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
229 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
230 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
231 virtual
void onPowerMaxChanged(
unsigned int loop,
double v) {}
232 virtual void onPowerMinChanged(
unsigned int loop,
double v) {}
233 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
235 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
237 double parseResponseMessage();
244 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
249 virtual double getRaw(shared_ptr<XChannel> &channel);
251 virtual double getTemp(shared_ptr<XChannel> &channel);
254 virtual double getHeater(
unsigned int loop);
261 virtual
void onPChanged(
unsigned int loop,
double p);
262 virtual
void onIChanged(
unsigned int loop,
double i);
263 virtual
void onDChanged(
unsigned int loop,
double d);
264 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
265 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
266 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
267 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
268 virtual
void onPowerMaxChanged(
unsigned int loop,
double v);
269 virtual
void onPowerMinChanged(
unsigned int loop,
double v) {}
270 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
272 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
286 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
294 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
298 virtual double getRaw(shared_ptr<XChannel> &channel);
300 virtual double getTemp(shared_ptr<XChannel> &channel);
303 virtual double getHeater(
unsigned int loop);
310 virtual
void onPChanged(
unsigned int loop,
double p);
311 virtual
void onIChanged(
unsigned int loop,
double i);
312 virtual
void onDChanged(
unsigned int loop,
double d);
313 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
314 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
315 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
316 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
317 virtual
void onPowerMaxChanged(
unsigned int loop,
double v);
318 virtual
void onPowerMinChanged(
unsigned int loop,
double v) {}
319 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
321 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
328 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
333 virtual double getRaw(shared_ptr<XChannel> &channel);
335 virtual double getTemp(shared_ptr<XChannel> &channel);
338 virtual double getHeater(
unsigned int loop);
345 virtual
void onPChanged(
unsigned int loop,
double p);
346 virtual
void onIChanged(
unsigned int loop,
double i);
347 virtual
void onDChanged(
unsigned int loop,
double d);
348 virtual
void onTargetTempChanged(
unsigned int loop,
double temp);
349 virtual
void onManualPowerChanged(
unsigned int loop,
double pow);
350 virtual
void onHeaterModeChanged(
unsigned int loop,
int mode);
351 virtual
void onPowerRangeChanged(
unsigned int loop,
int range);
352 virtual
void onPowerMaxChanged(
unsigned int loop,
double v) {}
353 virtual void onPowerMinChanged(
unsigned int loop,
double v) {}
354 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch);
356 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc);
364 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
369 virtual double getRaw(shared_ptr<XChannel> &channel);
371 virtual double getTemp(shared_ptr<XChannel> &channel);
374 virtual double getHeater(
unsigned int loop);
381 virtual
void onPChanged(
unsigned int loop,
double p) {}
382 virtual void onIChanged(
unsigned int loop,
double i) {}
383 virtual void onDChanged(
unsigned int loop,
double d) {}
384 virtual void onTargetTempChanged(
unsigned int loop,
double temp) {}
385 virtual void onManualPowerChanged(
unsigned int loop,
double pow) {}
386 virtual void onHeaterModeChanged(
unsigned int loop,
int mode) {}
387 virtual void onPowerRangeChanged(
unsigned int loop,
int range) {}
388 virtual void onPowerMaxChanged(
unsigned int,
double v) {}
389 virtual void onPowerMinChanged(
unsigned int,
double v) {}
390 virtual void onCurrentChannelChanged(
unsigned int loop,
const shared_ptr<XChannel> &ch) {}
392 virtual void onExcitationChanged(
const shared_ptr<XChannel> &ch,
int exc) {}