• PHONE_PLAY_TONE

    ioctl(ixj, PHONE_PLAY_TONE, cToneIndex)

    Return Value

    None.

    Parameters

    cToneIndex - The Tone table entry to use.

    Remarks

    Plays the tone selected from the tone table. Please note the distinction between the tone index and its start and stop time values. The start and stop times apply to the tone playing, regardless of which tone is p laying.

    The default tone table is listed in the 8020/8021/8022 DSP documents. It is reproduced here for convenience.

    See Also:

    PHONE_SET_TONE_ON_TIME, PHONE_SET_TONE_OFF_TIME, PHONE_GET_TONE_ON_TIME, PHONE_CPT_STOP, PHONE_GET_TONE_STATE, IXJCTL_INIT_TONE,

    Example:

    for(digit = 1;digit < 13;digit++)
    {
      ioctl(ixj, PHONE_PLAY_TONE, digit);
      state = ioctl(ixj, PHONE_GET_TONE_STATE);
      printf("state = %d\t", state);
      fflush(stdout);
      cnt = 0;
      while(state)
      {
        cnt++;
        usleep(40);
        state = ioctl(ixj, PHONE_GET_TONE_STATE);
      }
      printf("cnt = %d\n", cnt);
      fflush(stdout);
    }


    ©1996-2001 Quicknet Technologies, Inc.