Omega Speaker Systems TC-08 manual Temp, Filtered

Page 40

36

TC-08 User's Guide

3.3.4.3usb_tc08_legacy_get_temp

short usb_tc08_legacy_get_temp

(

long * temp, short handle, short channel, short filtered

)

Once you open the driver and define some channels, you can call the

usb_tc08_legacy_run routine. The driver will then constantly take readings from the USB TC-08. Temperatures are returned in hundredths of a degree Celsius and voltages are returned in microvolts.

Arguments

channel

Specifies from which channel to read temperature. Should

 

 

be 0 for CJC, 1 for Channel 1, 2 for Channel 2 and so on.

 

temp

Pointer to a location where readings are to be placed. Each

 

 

reading should be compared with 2147483647L or

 

 

LONG_MAX (include limits.h) to check for overflows. An

 

 

overflow occurs when the input signal is higher than the

 

 

measuring range of the USB TC-08.

 

filtered

Specifies whether or not to filter the data. The readings

 

 

are median filtered if set to 1. 0 causes the unfiltered

 

 

temperature to be stored in temp. The filter has a depth

 

 

defined by the filter factor, set during a

 

 

usb_legacy_set_channel call.

 

 

 

Returns

0

Use usb_tc08_get_last_error.

 

1

Temperature retrieval successful.

Note: Do not call this function unless you are operating the USB TC-08 in legacy

mode, having called usb_tc08_legacy_run.

Image 40
Contents User’s Guide Servicing North America Contents Page Installing the driver Connecting the USB TC-08 OverviewTC-08 Users Guide RefreshTC-08 Channels window, double-click on Channel 1 unused Safety warning Safety groundingMaximum input range Mains voltagesSpecifications How a thermocouple works Modes of operation IntroductionIntroduction Streaming mode Example ==================================================Get Single mode Usbtc08setmains handle, 0 // use 50Hz mains noise rejection Legacy mode Now do something with the cold junction temperature Routine Description New USB and serial mode New USB mode onlyLegacy mode only Driver routinesNew USB mode and legacy mode Short usbtc08openunit voidNone ArgumentsPositive short ReturnsStore the handle in an array handlearrayi = newhandle Short usbtc08openunitasync void Arguments None ReturnsHandle any error conditions if result == Handle ProgressShort tc08closeunit Short handle Arguments handleShort usbtc08stop Short handle Short usbtc08setmains Short handle, short sixtyhertz SixtyhertzMinimum Long usbtc08getminimumintervalms Short handleInterval Short usbtc08getunitinfo Shorthandle, USBTC08INFO * info InfoStringlength Short usbgetformattedinfo Handle Char UnitinfoUSBTC08MAXINFOCHARS characters long Short usbtc08getlasterror Short handle User/Developer error codes Error Further information CodeReserved error codes ErrorCode Channel New USB mode onlyTctype Long usbtc08run Short handle, long interval Overflowflags TempUnits Long usbtc08gettemp Short Handle Float * tempbuffer TempbufferTimesmsbuffer Overflow Long usbtc08gettempdeskew Short Handle Float * temp Times Short Channel Units FillmissingLegacy mode only Short usbtc08legacyrun Short handleFilterfactor Filtered Short usbtc08legacygetcoldjunction Long * temp, short handle Short usbtc08legacygetdriverversion Void Driver version NumberShort usbtc08legacygetversion Short * version, short handle VersionShort usbtc08legacygetcycle Long * cycle, short handle CycleC++ ProgrammingDelphi Excel LabVIEWVisual Basic Agilent VEETroubleshooting KeyGlossary Cold junction compensation. See CJCTechnical reference Page Index TC-08 Users Guide WARRANTY/DISCLAIMER Shop online at omega.com