Syntax | LONG TSPI_phoneGetDevCaps(dwRequestID, dwDeviceID, dwTSPIVersion, lpPhoneCaps) |
This function queries a specified phone device to determine its telephony capabilities. | |
Parameters | DRV_REQUESTID dwRequestID Specifies the identifier of the asynchronous request. The Service Provider returns this value if the function completes asynchronously. |
DWORD dwDeviceID Specifies the phone device to be queried. | |
DWORD dwTSPIVersion Specifies the negotiated TSPI version number. This value has already been negotiated for this device through the TSPI_phoneNegotiateTSPIVersion function. | |
LPPHONECAPS lpPhoneCaps Specifies a far pointer to a variable sized structure of type PHONECAPS. Upon successful completion of the request, this structure is filled with phone device capabilities information. | |
Return Value | Returns zero if the function is successful, the (positive) dwRequestID value if the function will be completed asynchronously, or a negative error number if an error has occurred. Possible error returns are: |
PHONEERR_INVALPOINTER The specified pointer parameter is invalid. | |
PHONEERR_BADDEVICEID The specified device ID is out of range. | |
PHONEERR_NODRIVER The driver was not installed. | |
PHONEERR_INCOMPATIBLEVERSIONS The app requested a version range that cannot supported by the Telephony API implementation and corresponding service provider version. | |
PHONEERR_OPERATIONFAILED The specified operation failed for unspecified reasons. | |
Call States | Not applicable. |
Comments | Phone device ID numbering for a Service Provider is sequential from the value set by the function TSPI_phoneSetDeviceIDBase. |
The dwExtVersion field of lpPhoneCaps has already been filled in to indicate the version number of the Extension information requested. If it is zero, no Extension information is requested. If it is non-zero it holds a value that has already been negotiated for this device with the function TSPI_phoneNegotiateExtVersion. The Service Provider should fill in Extension information according to the Extension version specified. | |
Comparison | This function differs from the corresponding TAPI function in the following ways: |
No application identifier is passed to the Service Provider | |
The SPI version has already been negotiated between the TAPI DLL and the Service Provider. The final result of the negotiation is passed as a parameter to this function. The Service Provider must preserve the value that is present in the dwTAPIVersion field of the PHONECAPS structure. | |
The Extension version number has already been negotiated, with the dwExtVersion field containing the negotiated value. The Service Provider must preserve the value in this field and fill in the DevSpecific portion of the data structure according to that Extension version requested (regardless of any currently selected Extension version). The special version number 0 indicates that no DevSpecific data is requested and the Service Provider may avoid filling it in. | |
See Also | Data Types: PHONECAPS Functions: TSPI_phoneSetDeviceIDBase, TSPI_phoneNegotiateExtVersion |
Fields: | The following table indicates which fields of the PHONECAPS data structure are filled in by the Service Provider and which fields are filled in by the TAPI DLL. The Service Provider must preserve (i.e., must not overwrite) the values filled in by the TAPI DLL. |
Field Name | TAPI DLL | Service Provider |
dwTotalSize; | X | |
dwNeededSize; | X | |
dwUsedSize; | X | |
dwAPIVersion; | X | |
dwExtVersion; | X | |
dwExtensionID0; | X | |
dwExtensionID1; | X | |
dwExtensionID2; | X | |
dwExtensionID3; | X | |
dwProviderInfoSize; | X | |
dwProviderInfoOffset; | X | |
dwPhoneInfoSize; | X | |
dwPhoneInfoOffset; | X | |
dwPermanentPhoneID; | X | |
dwPhoneNameSize; | X | |
dwPhoneNameOffset; | X | |
dwStringFormat; | X | |
dwPhoneStates; | X | |
dwHookSwitchDevs; | X | |
dwHandsetHookSwitchModes; | X | |
dwSpeakerHookSwitchModes; | X | |
dwHeadsetHookSwitchModes; | X | |
dwVolumeFlags; | X | |
dwGainFlags; | X | |
dwDisplayNumRows; | X | |
dwDisplayNumColumns; | X | |
dwNumRingModes; | X | |
dwNumButtonLamps; | X | |
dwButtonModesSize; | X | |
dwButtonModesOffset; | X | |
dwButtonFunctionsSize; | X | |
dwButtonFunctionsOffset; | X | |
dwLampModesSize; | X | |
dwLampModesOffset; | X | |
dwNumSetData; | X | |
dwSetDataSize; | X | |
dwSetDataOffset; | X | |
dwNumGetData | X | |
dwGetDataSize; | X | |
dwGetDataOffset; | X |