Erik said:
Hey,
Does anyone know if there is something in C that can read the data transfer
in the serial/paralel-port?
Or can't that be done with C?
THX, Erik
Reading from the serial, parallel, USB, I2C, and Firewire ports can
be read from C and C++ with a little help from platform specific
functions.
Reading from the serial port could be as easy as:
char read_serial_port(void)
{
volatile char * Uart_rx_reg = (volatile char *)(0x43000);
return *Uart_rx_reg;
}
But then, it could be more complicated, especially if your
platform doesn't have a serial port.
By the way, some serial ports are different than the
parallel ports.
--
Thomas Matthews
C++ newsgroup welcome message:
http://www.slack.net/~shiva/welcome.txt
C++ Faq:
http://www.parashift.com/c++-faq-lite
C Faq:
http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.learn.c-c++ faq:
http://www.raos.demon.uk/acllc-c++/faq.html
Other sites:
http://www.josuttis.com -- C++ STL Library book