Send data using parallel port...
Hello,
I have some doubts about how to use parallel port to send data.
I have a program with easy code that I download.
#define base 0x378
// Access parallel port
//*************************************************
if (ioperm(base,5,1)){
fprintf(stderr, "Error open parallel port\n");
exit(0);
}
iopl(3);
//*************************************************
valor = 0;
outb(valor, direccion);
s_strobe = 1;
outb(s_strobe, direccion+2);
s_strobe = 0;
outb(s_strobe, direccion+2);
Well, with this easy code I can to send data using parallel port, but strobe signal does not change when I send data, so I use two more instruction to generate strobe impulse.
But, I am interesting in send data using parallel port and strobe signal change state automaticly. is there any mode that parallel port send data and strobe signal change state when I send data??
best regards
|