Code covered by the BSD License  

Highlights from
Thar ABPR-20 RS232 communication via handheld emulation

Thar ABPR-20 RS232 communication via handheld emulation



20 May 2013 (Updated )

Controls and reads from a Thar ABPR-20, by emulating the handheld controller.

function status = tharbprobjreadextheaterstatus(serialObject)
% THARBPROBJREADEXTHEATERSTATUS reads the status of ext. temp. of Thar BPRs
% status = tharbprobjreadextheaterstatus(serialObject) reads the current
% status of the external heater control of Thar BPRs. serialObject is the
% BPR serial object (generated by tharbprobj). The status is returned as 1
% (on) or 0 (off).

% e.g. status = tharbprobjreadextheaterstatus(serialObject) - returns
% the external heater control status of the BPR e.g. 0.

% Range:

% serialObject = valid serial port object

% check the number of arguments
error(nargchk(1, 2, nargin))

% navigates to second display menu and fetches contents of screen
response = tharbprobjdisplaymenu2(serialObject);

% the set pressure is the on the 2nd line of the screen (if on
% the second F3 screen)
status = onoff(strtrim(response{2}(16:18)));

% presses F3 again to go back to the first display menu
tharbprobjcomm('write', serialObject, 19)

Contact us