Skip to content Skip to navigation Skip to collection information

Connexions

You are here: Home » Content » Toma de decisiones en un VI » VI Control de Temperatura

Navigation

Recently Viewed

This feature requires Javascript to be enabled.
 

VI Control de Temperatura

Module by: Juan Martínez. E-mail the author

Based on: Temperature Control VI by National Instruments

Summary: In this exercise, the objective is to use the Case structure in a VI. Complete the following steps to build a VI that allows the user to analyze data for limit testing and to determine the highest value.

Exercise 1

1.a) Panel Frontal

  1. Abrir el VI Promedio de temperatura.
  2. Modificar el panel frontal según se muestra en la Figure 1.
    Figure 1
    Figure 1 (tempcontrol.png)
    1. Colocar en el panel frontal una caja con los bordes izquierdo y derecho suaves (horizontal smooth box), situada en la paleta Controls>>All Controls>>Decorations. Este objeto decorativo agrupa los elementos de Analysis.
    2. Crear un duplicado del interruptor booleano Power. Etiquetar el nuevo interruptor como ANALYSIS. Hacer clic con el botón derecho sobre el interruptor y seleccionar en el menú desplegable Mechanical Action>>Switch When Pressed.
    3. Colocar en el panel frontal un control numérico, situado en la paleta Controls>>Numeric Controls. Etiquetar el control High Limit.
    4. Colocar un LED redondo en el panel frontal, situado en la paleta Controls>>LEDs. Etiquetar el indicador como Warning.
    5. Colocar también en el panel frontal un indicador numérico situado en la paleta Controls>>Numeric Indicators. Etiquetar este indicador como High Value.
    6. Hacer clic con el botón derecho sobre la pantalla del visualizador y seleccionar en el menú contextual Visible Items>>Digital Display para mostrar los valores digitales.
  3. Seleccionar File>>Save As para salvar el instrumento virtual como Control de Temperatura.vi en el directorio C:\Exercises\LabVIEW Basics I.

1.b) Diagrama de Bloques

  1. Modificar el Diagrama de Bloques como se muestra en la Figure 2. Agrandar el While Loop para crear espacio donde insertar los elementos nuevos.
    Figure 2
    Figure 2 (tempcontrolbd.png)
    1. case.png Colocar en el diagrama de bloques la estructura Case, situada en la paleta Functions>>Execution Control. Conectar el control Analysis al terminal selector terminal. Hacer clic en el botón decrement o increment para elegir el case True.
    2. greaticon.png Colocar en el diagrama de bloques dos funciones Greater?, situadas en la paleta Functions>>Arithmetic & Comparison>>Express Comparison. La primera función Greater? devuelve True si la temperatura rebasa High Limit. En cualquier otro caso, la función devuelve False.
    3. selecttherm.png Colocar en el diagrama de bloques la función Select situada en la paleta Functions>>Arithmetic & Comparison>>Express Comparison. Esta función devuelve el mayor de los dos valores.
    4. Completar el caso True de la Estructura Case como se muestra en la Figure 2.
    5. Hacer clic en el botón decrement o increment para elegir el case False.
  2. Completar el caso False de la Estructura Case, mostrado en la Figure 3.
    Figure 3
    Figure 3 (tempcontrolfalse.png)
    1. Hacer clic con el botón derecho sobre el túnel que conecta con el Warning Indicator y seleccionar en el menú que aparece Create>>Constant. Usar la herramienta Operating para cambiar la constante a False.
    2. Hacer clic con el botón derecho sobre el túnel que conecta con el indicador High Value y seleccionar en el menú que aparece Create>>Constant. Escribe -99999 como valor de la constante.
  3. Salvar el VI. Este VI se volverá a usar más adelante a lo largo del curso.

1.c) Ejecutar el VI

  1. Mostrar el Panel Frontal, escribir 80 en High Limit, y ejecutar el VI. Si ANALYSIS está apagado, el VI apaga el LED Warning y muestra un valor de -99999 en High Value. Si ANALYSIS está encendido, el VI enciende el LED Warning cuando la temperatura se encuentre por encima del valor High Limit y muestra el valor de temperatura actual High Value.
  2. Cerrar el VI.

Collection Navigation

Content actions

Download:

Collection as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Module as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Add:

Collection to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks

Module to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks