I am trying to write a number to the parallel port data lines and when I use the following code, my program crashes.
#include <conio.h>
#define data 0x378
scanf("%i",&bits);
_outp(data,bits);
Any ideas?
I am trying to write a number to the parallel port data lines and when I use the following code, my program crashes.
#include <conio.h>
#define data 0x378
scanf("%i",&bits);
_outp(data,bits);
Any ideas?
Wow. You're lucky it compiles. You don't even have a main function...Originally posted by samuraijack
I am trying to write a number to the parallel port data lines and when I use the following code, my program crashes.
#include <conio.h>
#define data 0x378
scanf("%i",&bits);
_outp(data,bits);
Any ideas?
Quzah.
Hope is the first step on the road to disappointment.
I do have a main function, I just didn't think that I needed to put that in aswel.
#include <conio.h>
#define data 0x378
int main(void)
{
scanf("%i",&bits);
_outp(data,bits);
}
Any ideas?
Last edited by samuraijack; 01-27-2003 at 03:18 AM.
I have been looking into this one and have found out that because I am using Windows NT 4 I can not just use the windows drivers and must make my own with windows DDK.
Before I begin does anybody know of a way around this?