I have a Selective Radiation Meter SR-3000, which has serial
interface.
I am trying to get serial set/get with StreamDevice works, the
control/set commands works fine, but Query response commands are
not working yet.
Here are my protocol file, db, and error messages from IOC:
Protocol:
---------------------------------------------------------------------
locktimeout = 5000;
terminator = CR LF;
replytimeout = 1000;
readtimeout = 1000;
extrainput = Ignore;
@init{out " ";}
# set commands here works fine
# but get commands...
fmin_get { out "F_MIN?;"; in "\13, %f"; }
fmax_get { out "F_MAX?;"; in "\r, %f"; }
mode_get { out "MODE?;" ; in "%s" ; }
spectrum_get { out "SPEC?;" ; separator="\13"; in "spectrum = (%
f)";
---------------------------------------------------------------------
------------------
db:
------------------------------------------------------------
record(ai, "$(S)_$(SS):$(DEV)$(N):FMIN_Get") {
field(DESC, FMIN Reading")
# field(SCAN, "10 second")
field(DTYP, "stream")
field(INP, "@srm3000.protocol fmin_get $(PORT) 0")
field(PREC, "2")
field(HOPR, "")
field(LOPR, "")
field(EGU, "Hz")
}
record(ai, "$(S)_$(SS):$(DEV)$(N):FMAX_Get") {
field(DESC, "FMAX Reading")
# field(SCAN, "10 second")
field(DTYP, "stream")
field(INP, "@srm3000.protocol fmax_get $(PORT) 0")
field(PREC, "2")
field(HOPR, "")
field(LOPR, "")
field(EGU, "Hz")
}
record (waveform, "$(S)_$(SS):$(DEV)$(N):Spectrum_Get")
{
field (DTYP, "stream")
field(SCAN, "10 second")
field (INP, "@srm3000.protocol spectrum_get $(PORT) 0")
field (FTVL, "DOUBLE")
field (NELM, "10000")
}
--------------------------------------------------
error message from the IOC:
2008/04/16 16:38:49.592 SCL_HPRF:SRM1:FMIN: Timeout after reading
11 bytes "<0d>850000000;"