|
发表于 2003-5-5 23:37:13
|
显示全部楼层
---------------
CLModem README
---------------
This is CLModem-0.3.0, a Linux kernel module driver for the Cirrus Logic
(Ambient) CL-MD5620DT DSP-based controller-less modem (but maybe it works
with some other models; if you try this driver with another model please
tell me if it worked).
This driver is ALPHA software. USE IT AT YOUR OWN RISK!
Currently this driver can do the following:
- reset the modem
- get the modem off/on hook
- dial a number using DTMF or Pulses
- monitor Call Progress (dialtone, answer & Ring detection, etc)
- originate a V.34 connection up to 33600bps
- check modem status
- send and receive data
- behave like a normal Serial TTY device
- understands some commands (not AT commands!!) [SEE NOTE]
- works with minicom, pppd, asmodem, etc.
From version 0.3.0 the driver is a kernel module that can be inserted or
removed at any time (maybe from some initialization script). This change was
necessary for fixing some problems the user-space driver couldn't address.
As this is an ALPHA driver it's incomplete and has bugs, so it COULD block
your computer or leave your modem in an unsafe state under certain conditions.
NOTE
----
I, Gabriel Gambetta, included very basic AT command support and error messages, so
the driver can be used directly from KPPP.
I couldn't contact the author to submit the changes, so I'm posting this version
so you can use it. If you are able to contact the author, please tell him to contact
me at ggambett@internet.com.uy
The driver understands ATZ, ATR, ATI, ATDT, ATDP, ATM, and ATL. It returns CONNECT,
BUSY, NO DIALTONE, NO CARRIER and NO ANSWER.
Install
--------
First you must gather some information about your modem and be completely sure
of this information. What you need is your Modem Base IO address and IRQ number
which can be obtained from "/proc/pci" e.g: cat /proc/pci and looking for
something like:
Bus 0, device 13, function 0:
Communication controller: Cirrus Logic Unknown device (rev 1).
Vendor id=1013. Device id=4000.
Medium devsel. IRQ 10.
Non-prefetchable 32 bit memory at 0xebffe000 [0xebffe000].
I/O at 0xde00 [0xde01].
or you can obtain them from within Windoze.
Next you MUST edit "clm_config.h" and configure CLM_BASE_IO_ADDRESS and
CLM_IRQ, for example:
#define CLM_BASE_IO_ADDRESS 0xde00
#define CLM_IRQ 10
NOTE: This driver will try to find a PCI modem and will compare its settings
with those provided, so they must match.
Once you have edited "clm_config.h" just run "make" and the module will be
compiled.
$ make
NOTE: the kernel module is "clm.o"
Usage
------
First you must create a character special device file to access the modem, so
you should type:
$ su
# mknod /dev/clm c 121 0
Next you must load the CLM module
# /sbin/insmod clm.o
Now you can use minicom and test your modem. See Modem Commands below.
Note: you must configure minicom first to use /dev/clm or symlink
/dev/modem to /dev/clm.
Using PPP
----------
For configuring PPP I suggest you use linuxconf (rp3 & wvdial don't work well)
setting the modem port to "/dev/clm" and using the included "chat-ppp0" after
changing the phone number to call.
The " PP" script starts a PPP connection; but you must edit it first to suit
your specific needs. It uses "chat-ppp0" as the connection script
# ./PPP
to stop PPP you can type "killall pppd" as root.
Modem Commands
--------------
The CLM device undertands some commands, that you can test using minicom.
command description
------- ----------------------
INIT Initializes the modem
SPKR ON turns on the speaker
SPKR OFF turns off the speaker
SPKRVOL n sets speaker volume to n (0-2)
DIAL phone dials phone number and originates a data modem connection
However, to hangup the modem you'll have to quit minicom.
Note: If you have problems establishing a connection take a look at your log
files (e.g /var/log/messages)
Bugs
-----
- Using V.34 increments RX errors too much depending on the line quality
and there's no Error Correction protocol implemented yet.
- The driver doesn't detect a remote hangup properly and if a retrain is
started the driver will hangup the modem.
To Do
------
- V.90 & X2
- voice stuff
- V.42 LAPM (for error correction)
- test line quality during connection
- retrains, rate renegotiations, etc
About CLModem
--------------
This driver was written by Mikhail Moreyra <mmv@Phreaker.net>
and is licensed under the terms of the GNU General Public License. See LICENSE.
Copyright (C) 2000 Mikhail Moreyra
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|