I am using Julmar's ATAPI Class in my program.
At the start of the program I create one instance of TapiManager to
monitor a single line to show who is calling.
When a telefon-nubmer shall be called from the software, I create a
second instance of TapiManger, get the line for making the call, make
the call, close the line and shutdown this instance of TapiManager.
The first instance shows the changing status of the Line till it gets
idle again and from then no further event is raised. Why? Is there
anything that I am doing wrong?
The Instance for monitoring the line:
myTAPI = New JulMar.Atapi.TapiManager("ProjectX")
If Not myTAPI.Initialize Then
MsgBox("Fehler beim Initialisieren der TAPI-Schnittstelle",
MsgBoxStyle.Exclamation Or MsgBoxStyle.OkOnly, "TAPI-Fehler")
Exit Sub
End If
myTapiLine1 = myTAPI.GetLineByName(My.Settings.TAPI_Line1, True)
AddHandler myTAPI.CallStateChanged, AddressOf TAPI_OnCallStateChanged
AddHandler myTAPI.NewCall, AddressOf TAPI_OnNewCall
AddHandler myTAPI.CallInfoChanged, AddressOf TAPI_OnCallInfoChange
myTapiLine1.Monitor()
The Instance for making a call:
Dim cTapiMgr As New JulMar.Atapi.TapiManager("ProjectX_Anwahl")
cTapiMgr.Initialize()
Try
Dim cLine As
JulMar.Atapi.TapiLine=TapiMgr.GetLineByName(My.Settings.TAPI_Line1, True)
cLine.Open(cLine.Capabilities.MediaModes)
Dim cAddress As JulMar.Atapi.TapiAddress = cLine.Addresses(0)
Dim cCall As JulMar.Atapi.TapiCall =
cAddress.MakeCall(My.Settings.TAPI_Amtskennziffer &
CTelefonData.nummer_normalized)
cLine.Close()
Finally
cTapiMgr.Shutdown()
End Try
Gottfried,
why are you using two instances?
I guess you are monitoring and makeCall on the same line device?
I suggest not to initialite, open, close shutdown for each and every makeCall,
but to use a single instance for all your operations from the start of you app
till exit.
BTW what device / TSP are you using?
--
Best Regards
Andreas Marschall
Microsoft MVP for TAPI / Windows SDK / Visual C++
TAPI / TSP Developer and Tester
My TAPI and TSPI FAQ:
http://www.I-B-A-M.de/Andreas_Marschall's_TAPI_and_TSPI_FAQ.htm
My Toto� Tools (a collection of free, mostly TAPI related tools):
http://www.i-b-a-m.de/Andreas_Marschall's_Toto_Tools.htm
TAPI development around the world (Frappr! map):
http://www.frappr.com/TAPIaroundTheWorld
* Please post all messages and replies to the newsgroup so all may
* benefit from the discussion. Private mail is usually not replied to.
* This posting is provided "AS IS" with no warranties, and confers no rights.
In data 27 maggio 2009 alle ore 16:38:01, Andreas Marschall [MVP TAPI]
<Andreas....@i-b-a-m.de> ha scritto:
> "Gottfried Pauler" <NOSPAMgottf...@aon.atNOSPAM> schrieb im
> Newsbeitrag news:f067c$4a1cedf7$557c9759$25...@news.inode.at...
>> I am using Julmar's ATAPI Class in my program.
>> At the start of the program I create one instance of TapiManager to
>> monitor a single line to show who is calling.
>>
>> When a telefon-nubmer shall be called from the software, I create a
>> second instance of TapiManger, get the line for making the call, make
>> the call, close the line and shutdown this instance of TapiManager.
>> The first instance shows the changing status of the Line till it gets
>> idle again and from then no further event is raised. Why? Is there
>> anything that I am doing wrong?
>
> Gottfried,
> why are you using two instances?
> I guess you are monitoring and makeCall on the same line device?
>
> I suggest not to initialite, open, close shutdown for each and every
> makeCall,
> but to use a single instance for all your operations from the start of
> you app
> till exit.
>
> BTW what device / TSP are you using?
>
--
"No One Ever Told Computers Were Going To Be Polite"
> why are you using two instances?
The main reason is that I am using an own threat for monitoring the line
and an own threat for making calls so that the GUI-thread is not blocked.
> I guess you are monitoring and makeCall on the same line device?
Yes, it is the same line.
>
> I suggest not to initialite, open, close shutdown for each and every makeCall,
> but to use a single instance for all your operations from the start of you app
> till exit.
I will redesign my programm to only use one instance.
>
> BTW what device / TSP are you using?
>
Auerswald ETS4308 is connected by RS232 to a Win2000 Server with
TAPI-Server running.
The TAPI-Events are comming rather slow/late over the net and MakeCall
takes two to three seconds so I decided to put the TAPI-handling into
own threads.
Regards,
Gottfried
you can still use several threads when you use a single instance.
Why does lineMakeCall take so long "over the net" when you
are using RS232 to connect?
Best regards,
Matthias Moetje
-------------------------------------
TAPI WIKI: http://www.tapi.info
-------------------------------------
TERASENS GmbH
Augustenstra�e 24
80333 Munich, GERMANY
-------------------------------------
e-mail: moetje at terasens dot com
www: www.terasens.com
-------------------------------------
"Gottfried Pauler" <NOSPAMgottf...@aon.at> wrote in message
news:4a1e1f20$0$11923$91ce...@newsreader04.highway.telekom.at...
>
> Why does lineMakeCall take so long "over the net" when you
> are using RS232 to connect?
>
I really do not know where the delay comes from - maybe it is the
switchboard itself. The network is 100Mbit and there is very low
traffic; so the communication between the TAPI-Server and client can not
be the problem.
Every software shows that delay - not only my program.
When you lift the handset it takes about one second till the
StatusChange is reported. What is the typical delay for such an event
with a professinal / new switchboard?
Regards,
Gottfried
usually this should be much faster.
To eliminate network issues (consider not only the physical bandwidth but
also such things as wrong DNS or authentication configuration) you should
first test with a TAPI application directly on the server that is connected
to the PBX.
Best regards,
Matthias Moetje
-------------------------------------
TAPI WIKI: http://www.tapi.info
-------------------------------------
TERASENS GmbH
Augustenstra�e 24
80333 Munich, GERMANY
-------------------------------------
e-mail: moetje at terasens dot com
www: www.terasens.com
-------------------------------------
"Gottfried Pauler" <NOSPAMgottf...@aon.at> wrote in message
news:4a23e166$0$2298$91ce...@newsreader01.highway.telekom.at...
Gottfried,
are you using the MS TAPI client/server architecture (i.e. Remnote TSP) ?
See my TAPI and TSPI FAQ:
Q: What is the Microsoft� TAPI client / server architecture ?
http://www.i-b-a-m.de/Andreas_Marschall's_TAPI_and_TSPI_FAQ.htm#_Q:_What_is_10
If so, then this may be the cause of the issue:
http://groups.google.com/group/microsoft.public.win32.programmer.tapi/browse_thread/thread/0af738caeb40dbdc/fc0893ac5ac1e8ee?hl=en#fc0893ac5ac1e8ee