# Ubuntu Modemsimulator gesucht



## msimpr (16. Juli 2010)

Guten Morgen zusammen,

Ich bin auf der Suche nach einem Modemsimulator für Ubuntu  der das ATA/RING/ATA Protokoll abhandeln
kann.



Danke für eure Hilfe und nen schönen Arbeitstag


----------



## Bauer87 (16. Juli 2010)

Es wurde im Internet schon so viel danach gefragt, aber nichts gefunden, wahrscheinlich gibt es etwas in der Richtung einfach nicht mehr.


----------



## msimpr (16. Juli 2010)

Hallo

Und warum gibs sowas dann für Windows und net für Linux?


----------



## amdfreak (16. Juli 2010)

msimpr schrieb:


> Hallo
> 
> Und warum gibs sowas dann für Windows und net für Linux?



keine Ahnung

Könnte es nicht auch mit einem Modemsimulator für Windows funktionieren (mit Wine emuliert) ?


----------



## msimpr (16. Juli 2010)

Nein weil WINE immer wieder abstürzt

Aber könnte es damit gehen?

Download t38modem from SourceForge.net

Könnte man das t38modem irgendwie unter Linux als normales virtuelles Modem einrichten?

wo ich dann per terminalprogramm at befehle senden kann und ein Terminalprogramm sendet mir dann OK usw aus?


Denn in der README vom t38modem steht folgendes leider nur für Windows


 * README
 *
 * T38FAX Pseudo Modem
 *
 * Original author: Vyacheslav Frolov
 *
 */
1. Introduction
---------------
What is t38modem?
From your fax or voice application view point it's a fax/voice modem pool.
From IP network view point it's a H.323/SIP endpoint with T.38 fax support.
From your view point it's a gateway between an application and IP network.
The homepage for t38modem project is http://t38modem.sourceforge.net/.
2. Building
-----------
2.1. Building for Unix
----------------------
Building with Open H323 Library:
  $ export PWLIBDIR=$path_to_libs/pwlib
  $ export OPENH323DIR=$path_to_libs/openh323
  $ make NO_PBOOLEAN=1 opt
Building with H323 Plus Library:
  $ export PTLIBDIR=$path_to_libs/ptlib
  $ export OPENH323DIR=$path_to_libs/h323plus
  $ make opt
Building with Open Phone Abstraction Library (OPAL):
  $ export PTLIBDIR=$path_to_libs/ptlib
  $ export OPALDIR=$path_to_libs/opal
  $ make USE_OPAL=1 opt
2.2. Building for Windows
-------------------------
Building with Open H323 Library:
  Start Microsoft Visual C++ 2005 with h323lib\t38modem_2005.vcproj file.
  Set Active Configuration to "t38modem - Win32 Release".
  Add "PBoolean=BOOL" to
  [Project]->[t38modem Properties]->[Configuration Properties]->
  [C/C++]->[Preprocessor]->[Preprocessor Definitions].
  Change "h323plus.lib" to "openh323.lib" in
  [Project]->[t38modem Properties]->[Configuration Properties]->
  [Linker]->[Input]->[Additional Dependensies].
  Build t38modem.exe.
Building with H323 Plus Library:
  Start Microsoft Visual C++ 2005 with h323lib\t38modem_2005.vcproj file.
  Set Active Configuration to "t38modem - Win32 Release".
  Build t38modem.exe.
Building with Open Phone Abstraction Library (OPAL):
  Start Microsoft Visual C++ 2005 with opal\t38modem_2005.vcproj file.
  Set Active Configuration to "t38modem - Win32 Release".
  Build t38modem.exe.
3. Examples
-----------
To get info about t38modem command line syntax enter:
  $ t38modem --help

3.1. Starting
-------------
Starting with Open H323 Library or H323 Plus Library:
  $ t38modem -n -o trace.log -p ttyx0,ttyx1 --old-asn \
                               --route 0@127.0.0.1 --route all@172.16.33.21
This will create two modems (/dev/ttyx0 and /dev/ttyx1) and H.323 endpoint.
If dialed number begins with '0' then it will be routed to a local host
(leading '0' will be discarded). Other dialed numbers will be routed to
172.16.33.21.
Starting with OPAL:
  $ t38modem -n -o trace.log -p ttyx0,ttyx1 \
                               --route "modem:0.*=h323:<dn!1>@127.0.0.1" \
                               --route "modem:1.*=sip:<dn>@172.16.33.20" \
                               --route "modem:2.*=h323:<dn>@172.16.33.21" \
                               --route "h323:.*=modem:<dn>" \
                               --route "sip:.*=modem:<dn>"
This will create two modems (/dev/ttyx0 and /dev/ttyx1) and H.323 and SIP endpoints.
If dialed number begins with '0' then it will be routed to a local host.
If dialed number begins with '1' then it will be routed to SIP endpoint 172.16.33.20.
If dialed number begins with '2' then it will be routed to H.323 endpoint 172.16.33.21.
Leading '0', '1' and '2' will be discarded.
Q. I try to use T38modem, but after run "t38modem -p ttyx0" I get a message
   "Could not open /dev/ptyx0: No such file or directory".
A. Looks like you don't have legacy PTY devices compiled in your kernel.
   You need to re-compile the kernel with 'Legacy PTY Support'.
   Alternatively, you can build t38modem with USE_UNIX98_PTY=1 option and use
   -p +/dev/ttyx0,+/dev/ttyx1 instead of -p ttyx0,ttyx1.
FreeBSD Users: You need to use  -p ttypa,ttypb instead of -p ttyx0,ttyx1.
               Remember to replace ttyx0 with ttypa and ttyx1 with ttypb
               when following the rest of these instructions.
               This will create two modems /dev/ttypa and /dev/ttypb.
Windows Users: You need two COM ports connected via Null-modem cable to create one modem.
               If your COM1 connected to COM2 and COM3 connected to COM4 you need to use
               -p \\.\COM2,\\.\COM4 instead of  -p ttyx0,ttyx1.
               This will create two modems COM1 and COM3.
               Q. How to use t38modem without additional COM port hardware on Windows?
               A. Replace a pair of physical COM ports with a pair of virtual COM ports.
                  See http://com0com.sourceforge.net/ project for details.
               Q. What model of modem to select in Add Hardware Wizard?
               A. Select "Standard 1440 bps Modem".
Cisco Users:   Possible additionaly you will need to use --h245tunneldisable option.
3.2. Testing (you need two consoles)
------------------------------------
(FreeBSD users - remeber to use /dev/ttypa and /dev/ttypb with 'cu -l')
(Windows users - use COM1 and COM3 with HyperTerminal)
$ cu -l /dev/ttyx0     $ cu -l /dev/ttyx1
Connected.      Connected.
<-- at              <-- at
--> OK                      --> OK
                            (wait at least 10 secs)
<-- atdt012345
                            -->
                            --> RING
                            -->
                            --> RING
                            <-- ati9
                            --> NDID = 12345
                            --> OK
                            -->
                            --> RING
                            -->
                            --> RING
                            <-- ata
--> CONNECT                 --> CONNECT
<-- x
--> OK
<-- ath
--> OK
                            -->
                            --> ERROR
<-- at
--> OK
                            <-- at
                            --> OK
...                         ...


----------



## lazy (20. Juli 2010)

Wie sieht es denn bei dir mit einer VM aus? Ich meine da könntest du einfach Windows XP einfach rein installieren, die Netzwerkverbindung freigeben und dann dein ding da installieren


----------



## msimpr (29. Juli 2010)

Hm habe für Ubuntu irgendwie noch nichts richtiges gefunden vllt kann mir ja jemand helfen beim Suchen


----------



## msimpr (30. Juli 2010)

So bingo88 ich hab was gefunden per Google

                                                                  Inzwischen habe ich per Google auch etwas schönes herausgefunden.

Und zwar dieses Softwaremodem

A generic Linux Soft Modem

Nunja in der Readme steht das hier:


Here is the generic Linux Modem. This modem is totally software,
it means that all the DSP stuff is done by the main CPU, as in some so
called "winmodems". See the main project page at
http://www.enst.fr/~bellard/linmodem.html. 

Linmodem is also a research project. It contains all the necessary
stuff to test new digital communication algorithms. The line simulator
and the X11 interface can be used to simulate a complete communication
chain.

Linmodem is the first modem to integrate a graphical user interface
which show the data transmitted graphically (QAM constellation, real
time FFT of the received signal, etc...) and which will allow you to
monitor the line quality.

What's done:
-----------

- V34 modulator (sampling rate of 8000 Hz)
- V34 demodulator (sampling rate of 8000 Hz), but no echo cancellor.
- Algebraic part of V90.
- DTMF dialing/receive.
- V8 protocol.
- V21 modulation & demodulation
- V23 modulation & demodulation
- sample code to test the protocol.
- sample code to test V21, V22, V23, V34 and V90 independently from the modem.
- a basic phone line simulator (with echos & typical line
  amplitude/phase distortion).
- an X11 interface (see README.x11)
- soundcard interface.
- AT command parser & sample tty simulator.
- asynchronous protocol.

See the homepage of the project at
http://www.enst.fr/~bellard/linmodem.html to know what are the tasks
you could do.

Read the file README.arch to know the details of the
implementation. Next versions will contain the first draft on the
algorithms which are implemented.

Testing:
-------

Yes, you can already hear the modem !

compile everything, then type: 

lm -sv

You will see a lot of debug stuff. Then you can press Control C to
stop the call. If you play the files 'ans.sw' and 'cal.sw' on your
soundcard (16 bit, signed 8kHz), you will hear the DTMF pulses, the V8
negociation, and a sample V21 connection. The X11 interface allows you
to see the signals exchanged.

Data pump testing:
-----------------

With the option '-m modulation_name', you can test the V21, V22, V23,
V34 and V90 data pumps.  You can understand what's going on in this
test only if you have a basic knowledge of the modulations.

The X11 interface can be used to monitor all the main data pump
parameters, except for V90 which is not yet completely integrated in
the tests (see README.x11).

Real modems:
-----------

Linmodem won't contain any
hardware modem to support modems directly, but it will use kernel
drivers which give a unified API to every driver (see README.arch to
have an idea of the API)

Some test code is included in lmreal.c to work with the LTModem stuff
available at Richard's LTmodem Page. However, it was
not tested so don't expect it to work in this version.

Soundcard testing:
-----------------

If you have two PCs connected by soundcards (connect line in -> line
out), you may try the soundcard support of linmodem (not tested now,
but should work):

'lm -tv' launches linmodem on your soundcard (device '/dev/dsp'). Then
you can type 'ATDTxxx' to compose a number and launch a connection. On
the other PC, type 'ATA' to receive the connection. It should work in
V23 (or V21 if you change the defaults modulations in lm.c).

With 'lm -t', linmodem simulates a serial line on '/dev/ttyz0'. You
can use minicom or any other terminal emulator to send AT commands.

Enjoy http://www.dslteam.de/forum/images/design/smilies/laugh.gif

Fabrice Bellard - bellard@email.enst.fr - http://www.enst.fr/~bellard


Kannst Du mir das Ganze unter Ubutntu kompelieren sodass ich dann diesen Abschnitt mal testen kann

With 'lm -t', linmodem simulates a serial line on '/dev/ttyz0'. You
can use minicom or any other terminal emulator to send AT commands.

Danke Dir

Achso und kann dieses ttyz0 wirklich sein oder heißt es eigentlich ttys0?


----------



## bingo88 (30. Juli 2010)

Das ist wieder nicht was du suchst:


> Linmodem will work with any "winmodem" hardware, provided that we know how to make it send and receive samples (as a soundcard) to the telephone line.



Das ist ein generischer Test-Treiber für sogenannte WinModems, meist PCI-Karten oder USB-Modems die eigentlich nur unter Windows funktionieren (daher der Name).

Hol dir Hardware oder gib es auf...


----------



## msimpr (30. Juli 2010)

Hm schade....


----------

