Created
April 25, 2012 16:16
-
-
Save yesidays/2491011 to your computer and use it in GitHub Desktop.
Leer y escribir en display de 7 segmentos
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <conio.h> | |
int main(void){ | |
int i,j,k,cont; | |
char c; | |
int x[]={6,91,79,102,109,124,7,127,103,63}; | |
int y[]={119,124,57,94,121,113,125,118,6,14,56,63,115,109,62,110}; | |
char user[]={'a','b','c','d','e','f','g','h','i','j','l','o','p','s','u','y'}; | |
char aux[5]; | |
char cam[5]; | |
clrscr(); | |
printf("Ingresa una palabra\n"); | |
printf("A,B,C,d,E,F,G,H,I,J,L,O,P,S,U,Y\n\n"); | |
c = getchar(); | |
while (c!='0'){ | |
c = getchar(); | |
for(k=0;k<=15;k++){ | |
if (c==user[k]){ | |
cont=y[k]; | |
} | |
} | |
for (j=0;j<=15;j++){ | |
for(i=0;i<=50;i++){ | |
outportb(0x3BC,cont); | |
} | |
} } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment