output via serial com1
Simon Clubley
simon.clubley at googlemail.com
Tue Jun 30 13:23:21 UTC 2009
On 30/06/2009, Simon Clubley <simon.clubley at googlemail.com> wrote:
> On 30/06/2009, lee <funnyvoice at tlabs.ac.za> wrote:
> > Hi... Im trying to output my screen "output" to console via serial cable
> > on com1.
> >
> > Here is my Code:
> >
> > void testCom1(void) {
> > char buffer[256];
> >
> > printf("*** Simple COM1 Test (9600 8N1) ***\n");
> >
> > int fd = open("/dev/ttyS1", O_RDWR | O_NOCTTY | _FNDELAY);
> >
>
> That's COM2, not COM1. Try /dev/ttyS0.
>
It looks like I was wrong about that. I don't use termios, but I
thought I had seen documentation and code which showed the first
serial port in a BSP was /dev/ttyS0 (as it is in Linux), but while
looking for something else, I found a PC386 based code reference which
says otherwise.
Sorry for the misinformation.
Simon.
--
Simon Clubley
simon.clubley at googlemail.com
More information about the users
mailing list