Solved

Modem initilization!

Posted on 1998-08-28
6
335 Views
Last Modified: 2013-12-05

 where is the modem initilization file in RedHat and Slackware? I have a 56k Flex modem on ttyS1 and I need to give him a initilization string before it dials the Internet ...
 
0
Comment
Question by:elvaaa
6 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 1637898
Modem intialization is done by the dialing program.
Which one are you using?
0
 

Expert Comment

by:jokan
ID: 1637899
In Redhat try

/etc/sysconfig/network-scripts/ifcfg-ppp0
0
 
LVL 1

Expert Comment

by:pestilence
ID: 1637900
If you use minicom (just type minicom as root), in the main screen type your initialitazion strings and then fire up a connection.

0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 

Expert Comment

by:graham_leach
ID: 1637901
This depends upon how you are dialing the internet.

Using MINICOM:  Type AT XX XX XX

Where XX is valid at commands.  See www.modem.com for a complete list of AT command switches and syntax.

Using PPP:

This is a little more complicated.  Most people use a program called CHAT to actually get the interface (MODEM) working before pppd is invoked.  CHAT uses a dialog (prompt/response) model to control the flow of execution.  Here is a sample CHAT script that programs the modem and then dials an ISP.  Note that the CHAT script is invoked from the call to pppd on the command line or (more usually) from a file in /usr/sbin called ppp-on or ppp-up

NOTE:  The line which has AT is where you would place your own initialization strings.  Remember to place all extended characters (%,$) in a line that has quotes (') around it.

CHAT:

#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the
# connection protocol for the desired connection.
#
exec chat -v                                                                    \
        TIMEOUT          3                                                    \
        ABORT              '\nBUSY\r'                                     \
        ABORT              '\nNO ANSWER\r'                         \
        ABORT              '\nRINGING\r\n\r\nRINGING\r'    \
        ''                         \rAT                                               \
        'OK-+++\c-OK'   ATH0                                             \
        TIMEOUT          30                                                  \
        OK                      ATDT$TELEPHONE                    \
        CONNECT         ''                                                    \
        ogin:--ogin:         $ACCOUNT                                   \
        assword:            $PASSWORD

0
 

Author Comment

by:elvaaa
ID: 1637902

pestilence,

I do not have minicom installed. I want my init string to go in modem before the ppp-on* script in Slackware dials internet ...
 
 
0
 
LVL 1

Accepted Solution

by:
fmismetti earned 20 total points
ID: 1637903
Usually, the ppp-on script calls a script named
/etc/ppp-on-dialer. Slackware does this way, at least (look in the contents of your ppp-on script to be sure)

In ppp-on-dialer you will see:
exec chat -v                                            \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         30                              \
        OK              ATDT$TELEPHONE                  \
        CONNECT         ''                              \
        ogin:--ogin:    $ACCOUNT                        \
        assword:        $PASSWORD

Change the line:

        ''              \rAT                            \

To

        ''              '\rAT XX XX XX XX XX'           \

Where XX are your modem commands. Then run ppp-on. You can execute "tail -f /var/adm/messages" to see the dialing process.

Hope it helps you.
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
Fine Tune your automatic Updates for Ubuntu / Debian
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question