You should simplify your problem and short the rx to the tx on each individual port.  Test them individually.  This will tell you if the kernel is still hanging on to one of them for its console.


On Mon, May 14, 2012 at 6:09 AM, Patrick Maheral (DWI - CA/Ottawa) <Patrick.Maheral@dragonwaveinc.com> wrote:
Do you have a getty running on either of those ports?  Is
You kernel using one of the serial ports as its console (for
debug messages)?  I've been frustrated several times when
I've forgotten to change the kernel console, or disable a
getty on the serial ports I have connected to peripherals.

Patrick

> -----Original Message-----
> From: James Linder [mailto:jam@tigger.ws]
> Sent: May 9, 2012 19:51
> To: gumstix-users@lists.sourceforge.net
> Subject: Re: [Gumstix-users] Serial Port Hell!!! Please help!
>
>
> On 10/05/2012, at 1:12 AM,
> gumstix-users-request@lists.sourceforge.net wrote:
>
> > I'm in serial port hell.  I have been trying for days using
> various examples
> > on the internet to open a serial port for read/write of
> binary data.  I'm
> > trying to connect to a device that wants 8bits, no parity,
> one stop bit.
> > Very standard stuff.  I'm running a Overo Fire and Tobi
> board.  I've got
> > pins 9 & 10 crossed with 21 & 22 to create a null modem.
> I'm using 2 simple
> > programs.  One writes bytes and the other reads and prints
> every byte that
> > comes in.  I'm using a .39 build of linux (if I remember
> correctly).  I seem
> > to be able to write bytes, but I can't read without putting
> a decimal 13 at
> > the end of the bytes.  It won't read without it, but that
> is only part of
> > the time.  I rarely get it to work at all.  I am COMPLETELY
> BAFFLED!  This
> > should be easy.  Please help me figure out what is wrong.
> Below is some
> > code to show how I'm opening the file and such...
> >
> > int fdL = open(dev_name,O_RDWR | O_NOCTTY | O_NONBLOCK, 0);
> > fcntl(fdL,F_SETFL,0);
> > struct termios termL;
> > cfmakeraw(&termL);
> > termL.c_cflag |= (CLOCAL | CREAD);
> > cfsetospeed(&termL,B115200);
> > cfsetospeed(&termL,B115200);
> > tcflush(fdL,TCIOFLUSH);
> > tcsetattr(fdL,TCSANOW,&termL);
> >
> > I actually check for errors on each of the calls and I am
> getting none.  I
> > use the same code to open devices /dev/ttyS0 and
> /dev/ttyS2.  I look for
> > available bytes to read using
> >
> > ioctl(fdL,FIONREAD,&num_bytesL);
> >
> > I'm currently reading/writting one byte at a time.
> >
> > I also went into /etc/inittab and commented out the console
> line that used
> > ttyS2 and set the respawn of ttyS0 and ttyS2 to use 115200
> >
> > Any help would be greatly appreciated.
>
> Check the settings that you have got by: stty -a </dev/ttyWHATEVER
> I must say VT to output looks strange.
> I set everything in the termios structure not with ioctls but
> everything seems to work ok.
> Mail me and I'll drop you some code that works for me.
> OH BTW I do not think the serial is bizare or hard
> (purposefully hellish)
>
> James
> --------------------------------------------------------------
> ----------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond.
> Discussions
> will include endpoint security, mobile security and the
> latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> gumstix-users mailing list
> gumstix-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gumstix-users
>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
gumstix-users mailing list
gumstix-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gumstix-users