3

Want to write an auto-answering (GSM call) program around a gsm voice modem which can be controlled by AT commands.

Could you please suggest a nice Java API wrapper around GSM AT command.

Have never worked before on such applications so please let me know if you see any issue with this approach.

-ak

PS> Modem doesn't support TAPI

Rich
  • 5,603
  • 9
  • 39
  • 61
Ankur
  • 103
  • 2
  • 10

1 Answers1

1

I am not sure if you have a specific modem in mind or are thinking of a general purpose utility. if the latter bear in mind that different modems and phones will support different AT commands. See:

Question re AT command support

Either way some useful links (Google 'Hayes command api' or anything you might have tried before with 'AT' replaced with 'Hayes' and you will find others also):

http://en.wikibooks.org/wiki/Serial_Programming/Serial_Java

http://jcs.mobile-utopia.com/jcs/13774_AtParser.java

http://embeddedfreak.wordpress.com/2008/11/03/simple-hayes-at-command-parser/

If your application is very simple these may be overkill - the AT commands are really just text characters sent and received over the serial port so you can go with very simple code, but these links will probably give you enough ideas to decide anyway.

Community
  • 1
  • 1
Mick
  • 24,231
  • 1
  • 54
  • 120
  • I need to develop an auto answering (GSM call) Android application, I searched internet and learned that 3rd party applications do not have permission "android.permission.MODIFY_PHONE_STATE", because of which my application can not auto answer a call, now I am reading about these AT commands. Can you please tell me one thing, which I didn't find, can a 3rd party application use these AT commands, on rooted/unrooted phone...? – blackfyre Oct 24 '12 at 09:52
  • 1
    The AT commands, or Hayes command set, was created to allow 'intelligent' computers control 'dumb' modems by sending them a set of simple commands, and receiving simple replies from the Modem. If you take a look at the question and answer here you can see a way to 'loopback' from the Android part of the phone to the GSM modem part to do what you suggest: http://stackoverflow.com/questions/8284067/send-at-commands-to-android-phone Note that the phone needs to be rooted and that it is likely to behave differently on different phones. – Mick Oct 25 '12 at 09:39