• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Java Telephone API (JTAPI)

 
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok , I know in C/C++ you can use the TAPI to write a computer answering machine program.
What I am curious of is can I use this java api to do the same thing.

I don't have PBX boxs or anything hi-tec.
But I do have a V.92 data/fax/voice modem in my computer.
One day I installed the fax component of the windows xp components from install cd.
All I had to do to fax was run a rj11 line from my modem to my phone wall jack.
It works fine!
I looked and all microsoft fax/dialer.exe ..etc software uses the TAPI functions for phone ...etc .
So I thought their should be a java equivalent to this since I am better at coding with java.

But I am curious do you need special hardware or software like asterisk ...etc to use the JTAPI.
I am kind of looking for a way to use the TAPI but just in java not in C/C++. I am not willing to start creating JNI functions for this purpose. So I hope JTAPI is what will work with my V.92 modem.

Basically I want to create a answering machine program in java that play's a different greeting message based on the caller id.

I also saw in device manager that my V.92 modem is using com3 I don't get this because the V.92 modem is plugged in to the PCI 2 slot (also listed in device manager)??? So I guess I don't know what the com0 to com255 means ? thought com meant serial port i.e the one or two serial pins on the back of the computer???

If com3 is some type of virtual port then maybe I could use java communication api to communicate with it and send/recieve AT commands to the V.92 modem. Bypassing the whole JTAPI thing.

Any help would be great.
Since I am kind of lost in the dark to the above questons.

The Java Telephone api makes me think that this api was just the function names of things that the providers of the deviceswill use to have their product supported by a java api. Not an already functioning telephone api like TAPI but maybe I am wrong?
 
Marshal
Posts: 28177
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Sam Doder wrote:The Java Telephone api makes me think that this api was just the function names of things that the providers of the deviceswill use to have their product supported by a java api. Not an already functioning telephone api like TAPI but maybe I am wrong?


No, I think you are right about that. JTAPI is just a spec and Sun didn't write a reference implementation for the spec. Other people have, though, I believe, so you should be able to find JTAPI implementations. Theoretically you could write your own implementation, but that would be a lot of work. A lot. You don't want to do that.
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The Java Telephone api makes me think that this api was just the function names of things that the providers of the deviceswill use to have their product supported by a java api. Not an already functioning telephone api like TAPI but maybe I am wrong?


This isn't unprecedented. JDBC is an API where Sun didn't ship an implementation before JavaDB -a.k.a. Apache Derby- came along (disregarding the ODBC/JDBC bridge). And for JSAPI (the Java Speech API) Sun never shipped any implementation - it has always been up to 3rd party vendors to do that.
 
Sam Doder
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well , yes I am not willing to write it from scratch. Also not willing to use the JNI nd write wrapper class for a java version of TAPI.

So the question then becomes does anybody know of a implementation of JTAPI that works for most V.92 data/fax/voice modems?
My V.92 came with my dell dimension 8100 around 2003 I bought it?

I found this link but I am unsure if this will work
http://gjtapi.sourceforge.net/

If I cann't find a version for it to work.

Then I am wondering if I use the java comm api and issue AT command thru com3 (com3 is where it say's in device manager that the V.92 modem is using As well as in PCI slot 2 device 0 function 0)

If anything if I cann't get a version of the java comm to work then I can create a one function wrapper class for CREATEFILE c++ to open \\?\com3 ,...etc.

Curious the if I have all the functionality provided by the modem doing it this way.
I know their is AT commands to get the caller id info ,...etc

Thanks for any help.
Seems though their should be a working api for sending/recieveing faxes from a V.92 modem in java?
And if that is the case the it stands to reason since these modems are also voice seems their should be a java equivalent to get caller id ,...etc etc

In C++ you can do it thru the TAPI but it is a pain, and I would much rather do it in java and beable to provide a quick GUI interface. Win32 api gui stuff is a pain for me to try and do. Did it once don't really want to do it again
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This may be a starting point: http://xtapi.sourceforge.net/ You said you have TAPI installed, right?
 
Sam Doder
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok , forget JTAPI or TAPI for a second.
I opened hyperterminal and issued the command At Dt = phone number to dial
And it dials fine and answers fine using these commands.
I know my modem is using com3.
So I thought writing a program using the javax.comm package would do the same thing that hyperterminal does.
In Hyperterminal I seleted com3 so the only thing is am I sending the data in the wrong format or something?

Heres my code
When I run it, it echos back what I typed so the java app is not failing to run however I should here the modem dialing a number when I issue the At DT = command. Maybe hyperterminal is sending other data to the modem with every command i send. Just don't know wish somebody could tell my what is going wrong?
Please feel free to compile/run my program to test it out. (note you will need the java.comm package ,...etc to run it, also you will probably have to change the com port to a different com port if your modem is not on COM3 , remember capitial letters makes a differents when typeing COM3 or com3 in the program)

 
Normally trees don't drive trucks. Does this tiny ad have a license?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic