Component: Analogue Temp Sensors (Environmental)

From Flowcode Help
Revision as of 16:06, 5 January 2022 by BenR (talk | contribs) (XML import)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
Author Medelec35
Version 1.0 (Release)
Category Environmental


Image Analogue Temp Sensors component

A range of the most popular temperature analogue sensors which are: AD22100, AD22103, LM135, LM235, LM335, LM35, LM36, LM37, LM60, MCP9700., MCP9701, TC1047, TMP35, TMP36, TMP37 & TSIC301. Uses a single ADC pin which will allow you to display the temperature in C or F. If your sensor is not listed, there is a Custom option. You will be able to enter the scale factor, offset voltage, min and maximum temperatures If the temperature is outside the min and max values, then 999.9 will be displayed.

Examples

No additional examples


Downloadable macro reference

VoltageADC

Calculates what the approximate voltage should be based on Vref, Scale factor, Offset.

For TSIC301, based on Max temp and Min temp only.

Parameters

This macro has no parameters


Return value

FLOAT


GetTempFloatF

Value of the temperature in deg F

Parameters

This macro has no parameters


Return value

FLOAT


GetTempFloatC

Value of the temperature in deg C

Parameters

This macro has no parameters


Return value

FLOAT


Simulation macro reference

This component does not contain any simulation macros


Property reference

Select Sensor

This property is of type Fixed list of ints and can be referenced with the variable name SensorType.

No additional information


Channel

This property is of type Single analog pin and can be referenced with the variable name adc_base1::channel.

Analogue Input Channel - Which pin is the analogue input connected to?

Vref (mV)

This property is of type Unsigned integer and can be referenced with the variable name VRef.

No additional information


VRef option

This property is of type Fixed list of ints and can be referenced with the variable name adc_base1::vrefop.

Defines what is used as the ADC maximum reference. ADC Range = GND to VRef Voltage

VDD - Defines the microcontrollers power supply pin as the max reference,

VREF+ Pin - Dedicated pin on the microcontroller to allow for a variable reference voltage.

Conversion speed

This property is of type Fixed list of ints and can be referenced with the variable name adc_base1::convspd.

Clock setting to select how fast the ADC peripheral will perform an ADC conversion.

The FRC setting is based on a RC time base and so will vary with temperature and pressure.

Other settings are generally based on divisions of the master clock.

Acquisition cycles

This property is of type Signed integer and can be referenced with the variable name adc_base1::actime.

Number of micro seconds to wait for the ADC input to charge before starting the analogue sample.

Scale factor (mV x100)

This property is of type Unsigned integer and can be referenced with the variable name Resolution.

for a scale factor of 22mv/C or 22mV/F it's 2200

Scale factor is set for you automatically.

It can only be adjusted with the Custom option.

Offset (mV)

This property is of type Unsigned integer and can be referenced with the variable name Offset.

Offset is set for you automatically.

It can only be adjusted with the Custom option.

Tot Avage Samples

This property is of type Unsigned integer and can be referenced with the variable name TotAvSamples.

No additional information


Max Temp

This property is of type Signed integer and can be referenced with the variable name Max0.

Max Temp the sensor can reach is set for you automatically.

It can only be adjusted with the Custom option.

Min Temp

This property is of type Signed integer and can be referenced with the variable name Min0.

Max Temp the sensor can reach is set for you automatically.

It can only be adjusted with the Custom option.

Label

This property is of type Line of text and can be referenced with the variable name label.

A text label to help you identify the component on the panel.

temperature

This property is of type Floating point and can be referenced with the variable name temperature.

No additional information