*BSD News Article 39710


Return to BSD News archive

Newsgroups: comp.os.386bsd.questions
Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!msunews!uwm.edu!vixen.cso.uiuc.edu!news.uoregon.edu!netnews.nwnet.net!ns1.nodak.edu!plains.NoDak.edu!ortmann
From: ortmann@plains.NoDak.edu (Daniel Ortmann)
Subject: Re: internal modems
Sender: usenet@ns1.nodak.edu (Usenet login)
Message-ID: <D10wvM.Hpu@ns1.nodak.edu>
Date: Sun, 18 Dec 1994 20:28:34 GMT
References: <Roy-1612940005100001@adept.cts.com>
Nntp-Posting-Host: plains.nodak.edu
Organization: North Dakota Higher Education Computing Network
Lines: 80

In article <Roy-1612940005100001@adept.cts.com>,
Roy Lovejoy <Roy@AdeptSolutions.com> wrote:
>This may seem like an ignorant-of-pc question, (sue me, I'm a mac developer), 
>but do the internal pc modems on the market today emulate COM ports? E.G.
>are they transparent to BSD, so they JUST WORK? (I know that's a rare
>concept on the pc)

They are visible to the machine as a "com port".  Usually you have to
set a jumper or a dip switch to set the port AND the irq.  Let's call
them "sio" instead of "com".  :-)

The default configuration the GENERIC kernel uses are:
- sio0 on irq4
- sio1 on irq3
- sio2 on irq5
- sio3 on irq9

If you want to use a different port/irq combination you have to
configure and compile your own kernel.

>Considering most 288 INTERNAL modems these days are around $80 to $90
>CHEAPER being internal, it would seem like a smart choice... unless it
>doesn't work with FreeBSD..
>
>Do they?????

Yes they work, but all modems are not created equal.

Think of the "modem card" as having two parts:
1) the modem chip
2) the UART serial port

The "modem" part is actually part of the communications LINE, while
the UART is actually part of the COMPUTER.  The terminology gets fuzzy
here because the word modem is used both for the chip and the internal
board, as well as for external modems.  :-)

Even though you don't see an actual cable between the modem chip and
the UART on the modem board, there are circuit traces that act every
bit the same as a cable connecting a serial port to an external modem.

The purpose of UART's is to handle the EIA-232 (formerly RS-232)
interface to the peripheral.

There are several parts to the communications link:
1) The processor hardware
2) The sio device driver os software
3) The UART
4) The modem (chip)
5) The modem on the remote system (the one to which you are connected).
6) The communications channel between the two modem chips (BIS or CCITT)
7) The communications channel between the modem chip and the UART (EIA-232)
8) The software that writes control codes and data two and from the
sio device driver.

You don't have to worry about handshaking/flow control on 6) since the
modems take care of that automatically.  (Handshaking today is
basically the same as flow control.  Consider them the same.)

You DO have to worry about flow control between YOUR modem chip and
your UART, whether or not they are on the same card!  Hardware RTS/CTS
flow control is best because it is "out of band", i.e. does not use
the data communications channel is controls, and because it is
therefor faster.

Note: the communications channel between the modems will rarely be the
same as the channel between the modem chip and the UART.  That isn't a
problem if the flow control is set up correctly.

You *must* make sure that the modem chip is using the same flow
control and speed as the UART.  You can achieve this by using "stty -f
/dev/cua00 crtscts speed 38400".  (Your communications software may do
this for you.)  Note that you have to have the cua00 device actually
open for stty to change the settings.  The modem-modem connection
speed is generally automatically negotiated to the fastest possible
rate.

Well, that is about all the basics.  Please, gurus, no flames, but
corrections are welcome.