Code covered by the BSD License  

Highlights from
Thar ABPR-20 RS232 communication via handheld emulation

Thar ABPR-20 RS232 communication via handheld emulation

by

 

20 May 2013 (Updated )

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

tharbprobjcurrenttemp.m
function currentTemp = tharbprobjcurrenttemp(serialObject)
% THARBPROBJCURRENTTEMP reads the current temperature of Thar BPRs
% currentTemp = tharbprobjcurrenttemp(serialObject) reads the current
% temperature of Thar BPRs. serialObject is the BPR serial object
% (generated by tharbprobj). The temperature is returned as a double
% precision scalar number in C.

% e.g. tharbprobjcurrenttemp(serialObject) - returns the current
% temperature of the BPR e.g. 49.6 (C)

% Range:

% serialObject = valid serial port object


% error handling
error(nargchk(1, 1, nargin))

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

% the set pressure is the first number on the 3rd line of the screen (if on
% the first F3 screen)
currentTemp = str2double(response{3}(17:19));

Contact us