Lenze PLC Designer PLC Designer (R2-x) Manual de usuario Pagina 513

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 844
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 512
L-force | PLC Designer
Operands in PLC Designer
DMS 3.2 EN 02/2011 TD29 511
See in the following examples for such a bitaccess on a variable resp. a structure
variable:
Declaration in global variables list for both examples:
Variable enable defines which bit should be accessed:
VAR_GLOBAL CONSTANT
enable:int:=2;
END_VAR
Example 1, Bitaccess on an integer variable:
Declaration in POU:
VAR
xxx:int;
END_VAR
Bitaccess:
xxx.enable:=true; -> the third bit in variable xxx will be set TRUE
Example 2, Bitaccess on an integer structure component:
Declaration of structure stru1:
TYPE stru1 :
STRUCT
bvar:BOOL;
rvar:REAL;
wvar:WORD;
{bitaccess enable 42 'Start drive'}
END_STRUCT
END_TYPE
Vista de pagina 512
1 2 ... 508 509 510 511 512 513 514 515 516 517 518 ... 843 844

Comentarios a estos manuales

Sin comentarios