Rockwell-automation 1747-PCIS API Software - Open Controller Manual de usuario Pagina 95

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 174
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 94
Publication 1747-UM002A-US-P - June 2000
Library of Routines 6-35
Return Value:
Considerations:
Supported in the DOS API library and the Windows NT API library
Example:
HANDLE Handle;
BYTE sw_pos;
int retcode;
retcode = OC_GetSwitchPosition( Handle, &sw_pos );
if ( sw_pos == SWITCH_BOTTOM )
OC_SetScanMode ( Handle, SCAN_IDLE );
OC_GetTemperature
OC_GetTemperature reads the current temperature of the 1746 I/O
PCI Interface’s built-in thermometer.
Syntax:
int OC_GetTemperature(HANDLE handle, BYTE*temp);
Parameters:
Description:
The temperature is updated every 10 seconds by the scanner.
The optimal operating temperature range for the 1746 I/O PCI
Interface is 0° to 60°C. When OC_GetTemperature returns a value of
75_ C or higher, the 1746 I/O PCI Interface is operating beyond its
optimal operating temperature range and you need to correct the
situation.
The scanner must be initialized before you can monitor the
temperature.
Name: Value: Description:
SUCCESS 0 switch position was read successfully
ERR_OCACCESS 2
handle does not have access to scanner
ERR_OCINIT 5 scanner has not been initialized, see OC_InitScanner
Parameter: Description:
handle Must be a valid handle returned from OC_OpenScanner
temp Returns the temperature in degrees Celsius
Vista de pagina 94
1 2 ... 90 91 92 93 94 95 96 97 98 99 100 ... 173 174

Comentarios a estos manuales

Sin comentarios