MATLAB REAL-TIME WORKSHOP 7 - TARGET LANGUAGE COMPILER Manuel d'utilisateur Page 275

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 408
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 274
Examples of MAT-Files
6-19
if (pmat == NULL) {
printf("Error reopening file %s\n", file);
return(1);
}
/* Read in each array. */
printf("\nReading in the actual array contents:\n");
for (i=0; i<ndir; i++) {
pa = matGetNextArray(pmat);
if (pa == NULL) {
printf("Error reading in file %s\n", file);
return(1);
}
/* Diagnose array pa. */
printf("According to its contents, array %s has %d
dimensions\n", mxGetName(pa),
mxGetNumberOfDimensions(pa));
if (mxIsFromGlobalWS(pa))
printf(" and was a global variable when saved\n");
else
printf(" and was a local variable when saved\n");
mxDestroyArray(pa);
}
if (matClose(pmat) != 0) {
printf("Error closing file %s\n",file);
return(1);
}
printf("Done\n");
return(0);
}
int main(int argc, char **argv)
{
int result;
if (argc > 1)
result = diagnose(argv[1]);
Vue de la page 274
1 2 ... 270 271 272 273 274 275 276 277 278 279 280 ... 407 408

Commentaires sur ces manuels

Pas de commentaire