?
Solved

modem commands

Posted on 1998-01-14
3
Medium Priority
?
251 Views
Last Modified: 2010-04-16
I need some modem commands in anyone knows of any.
In particular I need.

how to initialize a modem through turbo pascal.
how to dial a modem through turbo pascal.
how to hang up a modem through turbo pascal.
how to right text over the modem using turbo pascal.
0
Comment
Question by:isilver
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Expert Comment

by:mitchell042997
ID: 1217125
One way you can do this is through interrupts (I assume).  If you can get your hands on a copy of Ralph Brown's Interrupt List, that may help.

I know to initialize a modem, it's
ATZ

ATDT xxx-xxxx, to dial
ATH to hang up
and then you just write to the com port to write out.

You may be able to use the port command if you know the modems port number (COM1 may be something like 0x38F, for example.  I don't know if you can or cannot directly open up a COM port or LPT port in pascal.  Perhaps try something like this, although I doubt it will work:

var t:text;
begin
  assing(t,'COMx');  {whatever COM port your modem's on}
  writeln(t,'ATZ');

...

end;

Give that a shot and let me know what happens.
0
 
LVL 1

Accepted Solution

by:
olas earned 100 total points
ID: 1217126
Given modem-commands are correct but transfering data in
a robust way can not be done by simply writing to ports.
You can, if You are willing to learn about UARTS and
various registers manipulate and transfer data using your own
code. If your software is anything more than just a code snippet for fun, you should consider getting all the information
about how serial I/O is defined by the PC-standard and then
build a unit yourself using several modules of low-level access
to ports that handles connection, transfers, errors and allows
for future changes in configuration.

The alternative that I propose(after using many hours building my own COMM-unit) is:
1. Get a software toolbox for this purpose
2. If your're making a commercial software or if someone is
paying You: check out Asynch tools from Turbopower.
www.turbopower.com
3. If you're just doing it for fun: there are millions of lines
of source code and precompiled units on the net. Many of
them are freeware. Use your favorite searchengine to find:
source pascal.

Really, this is the way to go unless You want to learn all about
UARTS, RS232 and LOTS about error handling.
Good Luck!


PS. You may open devicenames such as LPTs but you can only do
a limited number of things.
0
 
LVL 2

Expert Comment

by:mitchell042997
ID: 1217127
I've got a neat book about error handling.  A lot of math involved (it seems like a lot even to me, an engineering student, who has haid his fair share of math (calc., diff eq, etc.)).

Have fun with it though.  If math is fun for you, error detection and correction is a good place to start.


0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

An introduction to the wonderful sport of Scam Baiting.  Learn how to help fight scammers by beating them at their own game. This great pass time helps the world, while providing an endless source of entertainment. Enjoy!
The top devops trends for 2017 are focused on improved deployment frequency, decreased lead time for change and decreased MTTR.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

777 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