MATLAB REAL-TIME WORKSHOP 7 - TARGET LANGUAGE COMPILER Manuel de service Page 60

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 282
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 59
2
Working with the Target Language
2-40
This produces:
Figure 2-2: Creating Multiple Records
Adding Parameters to an Existing Record
You can use the %assign directive to add a new parameter to an existing
record. For example,
%assign N = 500
%assign x = Block[Idx] + N /% Adds N with value 500 to Block %/
%assign myn = Block[Idx].N /% Gets the value 500 %/
Rec1 {
Rec2 {
Name "Name0"
Type "t0"
}
Rec2 {
Name "Name1"
Type "t1"
}
Rec2 {
Name "Name2"
Type "t2"
}
.
.
}
First New Record
Existing Record
Second New Record
Vue de la page 59
1 2 ... 55 56 57 58 59 60 61 62 63 64 65 ... 281 282

Commentaires sur ces manuels

Pas de commentaire