Sequence of Events for Outgoing Calls

The exact sequence of events depends on whether the modem is calling out using data mode or audio mode.

Data Call

  1. The originating tag calls the Modem Manager's MakeCall() method.
  2. Immediately, the tag's DataPort variable is set to a valid value.
  3. Shortly after, DataPort becomes an integer value >=0.

Should the call fail in any way, then DataPort becomes negative. For further details of these values, see Call Progress and Error Codes.

  1. If the call setup completes successfully, then DataPort changes to a Stream value (ValueType(DataPort)==8).
  2. The call requester may now read and write to that stream to communicate with the called party.
  3. To hang-up the call, you may call CloseStream().

If the other end hangs-up or the call fails, then DataPort becomes Invalid.

If the call setup fails (Step 3), then the call is retried according to the configured retry settings. If the call is retried, then DataPort becomes an array pointer while the call is queued. DataPort will not go Invalid until the call has been abandoned.

Audio Call

  1. The originating tag calls Modem Manager's MakeCall() method with a media value mode indicating an audio call.
  2. Immediately, the tag's DataPort variable is set to a valid value.
  3. Shortly after, DataPort becomes a pointer to an array, indicating that the call is queued.
  4. After call setup is started, DataPort almost immediately becomes a valid stream value.

This is different from data call setup, in that there is no progress indication. Also, although DataPort is a stream value, the call has not actually connected at this stage. This anomaly arises because a modem operating in voice mode cannot acquire and interpret the various tones that indicate the progress of the call - the modem returns connected status as soon as dialing is complete.

The only practical action the caller can invoke is to operate a time-out that allows a typical connect time, before starting to use the stream.

Any data written to the stream is converted to speech using the voice identified when the discriminator was registered. The speech device is initialized using the string defined by the DialerSpeechInit application property. Data written may include any escape sequences meaningful to the TTS engine.

If a bookmark is set, when the bookmark is reported back to the Modem Manager, a single character equal to 0x45+Bookmark Number is inserted into the stream and may be read by the tag.

The only other data that can be received are DTMF tones input at the remote device. In order to receive such tones, this requirement must have been specified in the media mode supplied to MakeCall(). This data appears in the stream as the digits 0..9, or as the number-hatch (#) or asterisk (*) character.

To shut down a call, you can call the CancelCall() method. If the other end hangs up, DataPort will become invalid.