Linear Gauges
Library Overview
The Linear Gauges library contains controls that show their
input values graphically along a linear scale. Blocks in the library
differ from each other in their numerical ranges and in their use
of pointers, numerical labels, text captions, and tick marks.
The blocks in this library fall into two categories, as listed
below:
| Pointer Linear Gauges | Bar Gauges |
| Generic Linear Gauge | Generic Bar Gauges |
| Min-Max Thermometer | Reverse Sliding Scale |
| Mixer | Scaled Bar Gauge |
| Mixer Scale | Tank |
| Multiple Scales | Thermometer |
Blocks in the two categories have slightly different interfaces,
capabilities, and appearances. Pointer linear gauges use one or more
pointers to indicate values. Bar gauges use a level indicator or a
two-color bar to reflect a single value or level.
Back to Top
Customizing Linear Gauges
This section describes how to customize linear gauges by making
changes that are specific to the Linear Gauges library. For changes
that apply to multiple categories of blocks, see these sections:
Customizing Pointer Linear Gauges
The table below lists some common customizations involving
the ActiveX Control Properties dialog box that are specific to pointer
linear gauges in the Linear Gauges library.
| Task | Description |
| Change the shape or size of a pointer | On the Pointers panel, set PointerID to
the ID of the pointer you want to change (0 if
there is exactly one pointer). Then use the Style property
to choose the shape, the Inner and Outer properties
to determine the length, and the Width property
to determine the thickness. |
| Label a pointer by displaying the corresponding number | On the Digital panel, set PointerID to
the ID of the pointer you want to label and check the PointerDigital check
box. |
| Change the appearance of a pointer label | On the Digital panel, first set PointerID to
the ID of the pointer whose label you want to change. Then use Decimals to
set the number of digits after the decimal point, PointerDigitalColor to
set the color of the number, and FontID to refer
to a previously defined font (on the Fonts panel). |
| Move a pointer label to a fixed position | On the Digital panel, first set PointerID to
the ID of the pointer whose label you want to change. Clear the PointerDigitalAttach check
box and use PointerDigitalX and PointerDigitalY to
set the fixed position for the label. |
| Move a pointer label to a position relative to the pointer | On the Digital panel, first set PointerID to
the ID of the pointer whose label you want to change. Check the PointerDigitalAttach check
box. For a vertical linear scale, use PointerDigitalX to
set the independent coordinate for the label. For a horizontal linear
scale, use PointerDigitalY to set the independent
coordinate for the label. |
Customizing Bar Gauges
The table below lists some common customizations involving
the ActiveX Control Properties dialog box that are specific to bar
gauges in the Linear Gauges library.
| Task | Description |
| Change the range of values along the bar | On the General panel, use the Min
Value and Max Value properties to
define the range. |
| Change the orientation or direction of the bar | On the General panel, use Orientation to
determine whether the bar is horizontal or vertical. Use Direction to
determine which end of the bar corresponds to the minimum value. |
| Change the size or position of the bar | On the Bar panel, use the BarInner and BarOuter properties
to define the width and position of the bar in the direction perpendicular
to the linear scale. Use the BarStart and BarStop properties
to define the length and position of the bar in the direction of the
linear scale. These properties do not affect the numerical values
associated with the bar, only the graphical depiction of the bar. |
| Change the colors of the portions of the bar on either side
of the indicated level | On the Bar panel, use the OnColor and OffColor properties
to define the colors associated with values below and above, respectively,
the indicated level along the bar. |
| Change the shape or size of the level indicator | On the Knob panel, use the Style property
to choose the shape. Use the Inner Value and Outer
Value properties to determine the thickness and position
in the dimension perpendicular to the linear scale. Use the Width property
to determine the width along the linear scale. |
| Label the indicated level using a number | On the Digital panel, check the Enabled check
box. |
| Change the appearance of the label | On the Digital panel, check the Enabled check
box. Then use Decimals to set the number of digits
after the decimal point, Color to set the color
of the number, and FontID to refer to a previously
defined font (on the Fonts panel). |
| Move the label to a fixed position | On the Digital panel, clear the Attach check
box. Then use X Position and Y Position to
set the fixed position for the label. |
| Move the label to a position relative to the level indicator | On the Digital panel, check the Attach check
box. For a vertical (respectively, horizontal) linear scale, use X
Position (respectively, Y Position)
to set the independent coordinate for the label. |
Combining Multiple Pointers in One Display
To display multiple pointers on a pointer linear gauge, see
the customizations in the table below. To learn how to control multiple
pointers simultaneously, see Controlling Multiple Graphical Elements.
| Task | Description |
| Add another pointer to the display | On the Pointers panel, increase the Pointers property.
The ID of the new region is the Pointers property
value minus one. To specify properties of the new pointer, set PointerID to
that ID and then set the remaining properties on the dialog box panel
accordingly. |
| Delete the most recently added pointer from the display | On the Pointers panel, decrease the Pointers property.
This deletes all properties associated with the pointer, such as its
color and shape. |
Back to Top
 | LEDs | | Numeric Displays |  |
Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
Get this Simulink Kit