Page 18
(b)
Output current readings repeatedly – ‘rp’
The CCD is also able to report the current readings repeatedly, at a given interval. This
command starts and stops this repeat activity by setting the parameter accordingly:
0 = Repeat off
1 = Repeat every 100ms
2 = Repeat every 500ms
3 = Repeat every second
4 = Repeat every minute
The timing commences from the point at which the ‘rp’ command is entered.
NOTE for 100ms repeat readings
: The data output is effectively lots of small data
packets. On TCP networks this can cause problems when communicating with front end
software running on MS Windows. It has been found that the Winsock control commonly
used in TCP comms development on Windows does not handle lots of small data packets
very well, coming in at speeds of around 10Hz or faster. As such it has been decided that
when 100ms repeated output is used, the data will be taken every 100ms and buffered up,
to be sent out every 500ms in blocks of 5 readings. This has proven to be a more robust
output method. For consistency, the output from serial comms also works in the same
way.
(c)
Setpoint value – ‘spv’
This command is used to set the value of the command setpoint. The command takes one
parameter which is the actual value to set.
The current value of the setpoint can be retrieved using the query ‘spv?’. Returned data is:
SP VALUE:
<setpoint value>
(d)
Setpoint mode – ‘spm’
This command sets the mode for the command setpoint. The command takes one
parameter which is a number between 0 & 2, identifying the mode, as follows:
0 = Auto mode
1 = Open mode
2 = Closed mode
(For more information on setpoint modes, see the Principles section - 7.4(a)).
The current mode of the setpoint can be retrieved by using the query ‘spm?’. The returned
data is:
SP MODE: (
<x>
)
<mode string>
… where …
<x> =
0
,
1
, or
2
and <mode string> =
AUTO
,
OPEN
, or
CLOSED
respectively.