Altera DE2-115 Guide de l'utilisateur Page 66

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 107
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 65
SFSU - Embedded Systems Tutorial Nano- Electronics & Computing Research Lab
65
sprintf (text,"%d & %d = %d ",number1,number2,number1 & number2);
}
else
{
sprintf( text_top_VGA, "My ALU");
sprintf (text,"%d | %d = %d ",number1,number2,number1 | number2);
}
Characters are written on the screen through “VGA_text” function.
void VGA_text(int x, int y, char * text_ptr)
{
int offset;
volatile char * character_buffer = (char *) 0x00101000; // VGA character buffer
offset = (y << 7) + x;
while ( *(text_ptr) )
{
*(character_buffer + offset) = *(text_ptr); // write to the character buffer
++text_ptr;
++offset;
}
}
You can obtain the software code by opening the main.c file which is attached with this
tutorial.
Vue de la page 65
1 2 ... 61 62 63 64 65 66 67 68 69 70 71 ... 106 107

Commentaires sur ces manuels

Pas de commentaire