怎么得到电话按键值,要不就要被KKK了(100分)

  • 主题发起人 主题发起人 bbcoll
  • 开始时间 开始时间
to : Oldtiger
可以发个原代码过来看看吗,
我真的需要,
BBCOLL@163.COM
 
Tmsgvoc去搜索一下吧,默认设置对ROCKWELL系列有效
 
收!关键在ATCmd和SelectNumKay两点
 
to Oldtiger,
我是导入tapi3.dll的,
产生了一个tapi3lib_tlb的类库,
然后用哪些对象?tapi?
 
我没用Tapi,用的是Mscomm.ocx控件,直接通过串口对Modem进行操作,
我用的是Hayes336 Voice/Fax modem,标准的Hayes AT命令,
至于Mscomm.ocx则是从VB6上带来的,你只要安装一次VB6就有那些文件了
Mscomm.ocx是要注册的,因此你如果要在没安装VB6的机器上运行,
就要在安装过程中注册Mscomm.ocx及其相关文件,
Mscomm.ocx还带有一个Help文件,叫Comm98.chm,你可以参考一下的
 
我看没这么麻烦,用turbopower的TAPI控件确实很方便!
 
Unimodem has called VCOMM to open the correct serial port for this modem, and set its default COM port settings.

11-08-1995 14:49:29.52 - Initializing modem.
11-08-1995 14:49:29.52 - Send: AT
11-08-1995 14:49:29.52 - Recv: AT
11-08-1995 14:49:29.67 - Recv: OK
11-08-1995 14:49:29.67 - Interpreted response: Ok
11-08-1995 14:49:29.67 - Send: AT &F E0 V1 &D2 &C1 W2 S95=47
11-08-1995 14:49:29.68 - Recv: AT &F E0 V1 &D2 &C1 W2 S95=47
11-08-1995 14:49:29.82 - Recv: OK
11-08-1995 14:49:29.82 - Interpreted response: Ok
11-08-1995 14:49:29.82 - Send: ATS7=60S30=0L1M1/N3%C3&K3B0 N1X4
11-08-1995 14:49:29.98 - Recv: OK
11-08-1995 14:49:29.98 - Interpreted response: Ok
11-08-1995 14:49:29.98 - Waiting for a call.

Normal data init process.

11-08-1995 14:49:29.98 - Send: at#cid=1
11-08-1995 14:49:30.14 - Recv: OK
11-08-1995 14:49:30.14 - Interpreted response: Ok

EnableCallerID commands sent to modem.

11-08-1995 14:49:30.14 - Send: at-sdr=7
11-08-1995 14:49:30.27 - Recv: OK
11-08-1995 14:49:30.27 - Interpreted response: Ok

EnableDistinctiveRing commands sent to modem.

11-08-1995 14:49:30.27 - Send: ATS0=0
11-08-1995 14:49:30.41 - Recv: OK
11-08-1995 14:49:30.41 - Interpreted response: Ok

Monitoring command sent to modem.

11-08-1995 14:49:44.25 - Recv: RING1
11-08-1995 14:49:44.25 - Interpreted response: Distinctive Ring A

Incoming ring. Since distinctive ringing is enabled, distinctive ring is reported.

11-08-1995 14:49:46.90 - Answering the voice call.
11-08-1995 14:49:46.90 - Send: at#cls=8
11-08-1995 14:49:47.16 - Recv: OK
11-08-1995 14:49:47.16 - Interpreted response: Ok
11-08-1995 14:49:47.16 - Send: at#vls=0
11-08-1995 14:49:47.31 - Recv: OK
11-08-1995 14:49:47.31 - Interpreted response: Ok
11-08-1995 14:49:47.31 - Send: at#vbt=1
11-08-1995 14:49:47.45 - Recv: OK
11-08-1995 14:49:47.45 - Interpreted response: Ok
11-08-1995 14:49:47.45 - Send: at#vsr=7200
11-08-1995 14:49:47.59 - Recv: OK
11-08-1995 14:49:47.59 - Interpreted response: Ok
11-08-1995 14:49:47.59 - Send: at#vbs=4
11-08-1995 14:49:47.73 - Recv: OK
11-08-1995 14:49:47.74 - Interpreted response: Ok
11-08-1995 14:49:47.74 - Send: ats30=60
11-08-1995 14:49:47.88 - Recv: OK
11-08-1995 14:49:47.88 - Interpreted response: Ok
11-08-1995 14:49:47.88 - Send: ata

VoiceAnswer commands sent to modem. This happens in response to the TAPI function lineAnswer.

11-08-1995 14:49:48.11 - Recv: VCON
11-08-1995 14:49:48.11 - Interpreted response: Ok

Voice connect response. The voice connect response is normally mapped to an OK response.

11-08-1995 14:49:48.11 - Issuing Speakerphone command.
11-08-1995 14:49:48.11 - Send: at#vls=6
11-08-1995 14:49:48.26 - Recv: OK
11-08-1995 14:49:48.26 - Interpreted response: Ok

SpeakerphoneEnable commands sent to modem.

11-08-1995 14:49:48.26 - Send: at#vls=6
11-08-1995 14:49:48.41 - Recv: OK
11-08-1995 14:49:48.41 - Interpreted response: Ok
11-08-1995 14:49:48.41 - Send: at#spk=0,,,
11-08-1995 14:49:48.55 - Recv: OK
11-08-1995 14:49:48.55 - Interpreted response: Ok

SpeakerphoneMute commands sent to modem.

11-08-1995 14:49:48.55 - Send: at#vls=6
11-08-1995 14:49:48.69 - Recv: OK
11-08-1995 14:49:48.69 - Interpreted response: Ok
11-08-1995 14:49:48.69 - Send: at#spk=,0,3
11-08-1995 14:49:48.84 - Recv: OK
11-08-1995 14:49:48.84 - Interpreted response: Ok

SpeakerphoneSetVolumeGain commands sent to modem

The preceding commands (SpeakerphoneEnable, SpeakerphoneMute, and SpeakerphoneSetVolumeGain) are sent in response to the TAPI call phoneSetHookSwitch(hPhone, PHONESHOOKSWITCHDEV_SPEAKER, PHONEHOOKSWITCHMODE_SPEAKER), which takes the speakerphone off hook, and mutes it.

11-08-1995 14:49:48.84 - Voice Modem Wave Open.

waveOutOpen/waveInOpen called

11-08-1995 14:49:48.85 - Setting wave format.
11-08-1995 14:49:48.85 - Send: at#vls=0
11-08-1995 14:49:48.99 - Recv: OK
11-08-1995 14:49:48.99 - Interpreted response: Ok

LineSetPlayFormat commands sent to modem.

11-08-1995 14:49:48.99 - Starting wave play/record.
11-08-1995 14:49:48.99 - Send: at#vtx
11-08-1995 14:49:49.17 - Recv: CONNECT
11-08-1995 14:49:49.17 - Interpreted response: Connect

StartPlay commands sent to modem.

11-08-1995 14:49:49.40 - Received DLE Raw=117, Translated=255.

DLE received from modem. The Raw value is the actual value received, and the Translated value is the value Unimodem has mapped it to. See the DLE translation table in Interpreting Modem Event Logs. In this example, the DLE is translated to 255, which means that Unimodem/V ignores this DLE.

11-08-1995 14:49:54.78 - Ending wave play/record.
11-08-1995 14:49:54.78 - Voice Modem Wave Close.

waveInClose/waveOutClose has been called.

.
.
.
11-08-1995 14:50:41.48 - Received DLE Raw=49, Translated=1.

DLE received from modem. This is translated to the DTMF digit 1.

11-08-1995 14:50:41.51 - Ending wave play/record.
11-08-1995 14:50:41.51 - Voice Modem Wave Close.

waveInClose/waveOutClose has been called.

11-08-1995 14:50:41.94 - Received DLE Raw=35, Translated=15.

DLE received from modem. This is translated to the DTMF digit #.
Interpreting Modem Event Logs
Two sample modem event logs produced by LOGWIN.EXE are shown in the following, one for a data modem session and the other for a voice modem session. In order to interpret the event logs, you need to understand the following about how LOGWIN.EXE and Unimodem/V work together to produce the logs.

When Unimodem/V receives a DLE from the modem, the DLE is translated to a standard event. Following is the table that maps the translated value to the event. The modem log displays the actual DLE received and it's translated value.

Translated DLE value Description
0 DTMF 0
1 DTMF 1
2 DTMF 2
3 DTMF 3
4 DTMF 4
5 DTMF 5
6 DTMF 6
7 DTMF 7
8 DTMF 8
9 DTMF 9
10 DTMF A
11 DTMF B
12 DTMF C
13 DTMF D
14 DTMF *
15 DTMF #
16 DTMF Start
17 DTMF End
32 End of Transmit
33 Handset off hook
34 Handset onhook
35 Ring
36 Ringback
37 Answer tone (CCITT - V.25/T.30 2100 Hz)
38 Busy
39 Fax CNG Tone
40 Dialtone
41 Silence
42 Quiet
43 Data calling tone (V.25 1300 Hz tone)
44 Bell answer tone (2225 Hz tone)
255 Don't care - Unimodem ignores DLE


 
用Tapi确实是很方便,Delphi也有支持Tapi的,
但是,Tapi不支持多路响应,
好比说,你有若干条线路需要同时响应时,
Tapi就只能响应一条线路,因为那是单线程的!
所以才只好用串口直接控制Modem!
 
谁说TAPI只能响应一条线路,TAPI是微软提供的一套API,如何实现是你自己的事情。
 
to:我是帅哥,你试过一台机上挂8个Modem吗?成功了吗?
我不但没成功,就是安装了8个Modem后再安装Symentic WinFax 8.0也不成功
它那TAPI就只能在一个Modem上工作,其他Modem都睡觉去了
唉,我水平低呀,你帮帮我?
 
谁说不支持多个Modem,tapi是支持绑定一个设备的
 
-) Oldtiger
先说说你怎么挂8个Modem的?
TAPI是和设备无关的。
用TAPI3.0构建呼叫中心都可以,何况...
我试过一台机器直接接两个Modem,并用多串口卡连过多个Modem,没有任何问题。
 
to:我是帅哥,
我是用Moxa C218Turbo/Pci八串口卡带八个Hayes 336 Voice/Fax Modem的,
原来是想用Win98带的Tapi实现语音/传真功能,
但是Tapi需要Modem的Voice驱动支持,
我在安装Voice驱动的时候发现8个Modem只能自动识别第一个Modem的Voice,
其余的7个都需要手工加上去,
而手工加上去之后Tapi就不能正常工作,情形就是如此。

to:bbcoll,
我给你的信收到了吗?今天我竟然收到163的退信,怎么回事?
 
来自http://wenjinshan.yeah.net或wenjinshan.mycool.net的
《Delphi串口及语音传真编程》已出版
 
后退
顶部