Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Easy way to change baudrate of serial interface?

Status
Not open for further replies.

alcyone

Programmer
Sep 6, 2000
33
Hi people,

In my SUN fire V240 (running Solaris 10) I have a pci-card with 16 serial RS422 interfaces on it. An application written in C reads and writes to those interfaces, but it seems that baudrates higher than 9600 don't work correctly. To be sure that the problem isn't in my appplication, I am trying to test the interfaces with "cat" and "echo".
How I can easily change the baudrates of the interfaces? I think it has something to do with stty, but the manpage says this is only for stdin.
Thanks in advance for any answers!
 
Thank you for your reply, cndcadams.
I'm still not able to manage it, when I use this command (smserialport list), it shows only the 2 ports ttya and ttyb, but not the interfaces on the PCI-card (tty0 - tty15).
I noticed a 'mset' command, which came together with the driver for the card, so probably that will work.
Thanks again.
 
Bad luck, the mset command does not do what I am looking for. Are there any other ideas, please?
 
alcyone;

If you can give me the part# and who makes the card I will look around for you.

This card came with its own software pkg correct?

If so then is there a configuration file that is created for it?

Any info you think is pertinent post it.

I know you can control serial management port through the /etc/remote file. If you look at that is there any reference to your card/ports?

Thanks

CA
 
Hi cndcadams,

The card is a Aurora Aries 16000P, information can be found at
The exact problem I have with higher baudrates than 9600 is the following:
When I try to send a message to one of the ports, sometimes it goes ok, at other times, the last 1, 2 or 3 characters are missing. But when I send another message after it, I first see the characters which were missing before, so nothing is lost. I am sure the characters were sent correctly because I connected a V520 terminal between the input and output, and saw all the output I sent directly. So to me, it looks like the driver uses an internal buffer for the message and keep some characters until a next message arrives. This is my experience with the c application (I use the select() and read() function), and now I like to test it with echo/cat commands.
Thank you so far, I really appreciate your help.
 
alcyone;

You said mset does not do what you want.

Looking at the user guide it shows how to set a baudrate with mset, but I am not clear on if you can set it port specific. Also it says to use stty or admintool to set baudrates but Admintool is no supported is Solaris 10.

Did you take a look at /etc/remote to see if there is any entries in there for your card?

I also saw something about dropped characters but 1. it pertains to lack of memory and 2. yours does not actually seem to be dropping them from your earlier statement.

I will continue to look.

Have you contacted the vendor at all?


Thanks

CA

 
Thanks for your help.
I took a look at /etc/remote, but found nothing about the card in it.
I haven't contact the vendor yet, because I first want to be sure that it has nothing to do with the application (maybe I am doing something wrong?), so that's why I like to try different communication settings with echo/cat.
I made a little test application but still have the same problems. I'll have to experiment with it.
Thanks again!
 
try 'man /etc/ttydefs', Although they made a lot of Changes in Solaris 10 and I don't have a Sol10 box handy to double check.. I believe it still has the /etc/ttydefs and you should be able to tweak the settings in there, you may have to add the list of ports created by your serial port card from scratch. But it should work. If not, I'll see if I can get my hands on another Sol10 box.
 
Hi,
Sorry for my late reply. In the meantime we solved the problem, which was a bug in the C application. We used the termio struct, which gave the problem mentioned above, but when we changed this to the termios struct, all worked fine. So it has nothing to do with the card.
Thank you all for your help, I appreciated it very much!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top