Elmomc Multi-Axis Motion Controller-Maestro Manual do Utilizador Página 71

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 313
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 70
type name
argument-list , type name
type-specifier:
int
float
Examples:
int a,b // declaration global variables
function run() // begin function declaration
global int a // global variable declaration inside body of function
int c // local variable declaration in function run()
c=56
a=b+c // !!!error!!! variable b not declared in this function
a=c+17
end function // end of function declaration
5.2.1.2
Maestro Software Manual MAXL Program Language
MAN-MASSW (Ver. Q)
Array Declarations
An "array declaration" names the array and specifies the type and the number of its
elements. The current release of MAXL supports only global arrays.
Syntax
array-declaration:
type-specifier array-name [define-dimension]
type-specifier:
int
float
define-dimension:
integer-constant
define-dimension , integer-constant
Examples:
int a[10],b[5] // declare global arrays
int xy_positions[100, 2] // declare multi dimensional array
function run() // begin function declaration
global int a[] // global array declaration inside of function
global int xy_positions[100,2]
a[0]=56 // define value of first element
end function // end function declaration
5-9
Vista de página 70
1 2 ... 66 67 68 69 70 71 72 73 74 75 76 ... 312 313

Comentários a estes Manuais

Sem comentários