This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

asm/io.h where can I find this ??


Hello and Thanks you for openning this message.

I'm working on a program which write to a serial port and reads from it.

works under linux red hat, using the command line :
-> gcc myprog.c -o myprog -O2
and
->/myrep/myprog

but when I try to compile it under cygwin )))-: it doesn't works and shows:-

asm/io.h: No such file or directory

this is the lib I need

ORIGINAL LINE     : #include <asm/io.h>

where can I find the the equivalent of red hat "asm/io.h"
and where sould I copy it under cygwin ?

The following is myprog.c (fastly commented) source it will be usefull to
understand what I say.

Thank you

Regards 
Abhishek

/*----Start of myprog source -------*/

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>
#define BASEPORT 0x378 

int main()
{
    int i=0;
    char c='A';
    ioperm (0x378,1,1);
    for (i;i<10;i++) {
       outb(c,0x378);
       printf("%c\n",inb(0x378));
       printf("%c\n",c);
       c++;
    }
    ioperm (i,1,0);
}  

/*----End of myprog source -------*/




 




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]