Home · All Classes · Annotated · Functions

Tutorial: Dialing a Number

To dial a number, the application:

  1. creates an instance of the PhoneLine class
  2. calls the PhoneLine::createCall method to retrieve an instance of the PhoneCall class that represents the call
  3. calls the PhoneCall::dial method to dial the number
  4. uses PhoneCall::dial to transmit the request to the phone server.

Usually there is only one instance of the PhoneLine class per application. However, there may be multiple instances of PhoneCall if calls are on hold or a multi-party conference call is in progress.

The phone library transmits the dial request to the phone server using QCop, the phone server then:

  1. obtains an instance of PhoneLineAt, which represents the AT command handler for the phone line
  2. calls the PhoneLineAt::createCall method to create an instance of the PhoneCallAt class
  3. calls the PhoneCallAt::dial method to dial the number
  4. uses PhoneCallAt::dial and then sends the ATD command to the phone device to effect the dial request.

The sequence of operations mirrors the sequence in the application with the only difference being in the final step where:

If the device does not support AT commands, new handler classes need to be written, modeled on the structure of PhoneLineAt and PhoneCallAt.

Note: Details of how the device effects the dial command is beyond the scope of this document.


Copyright © 2006 Trolltech Trademarks
Qtopia 4.1.7