API Guide Home (Online version only) |

# HsPhoneMisc.h File Reference

## Detailed Description

Header File for Phone Library API ---- MISC CATEGORY.

Notes: All implementations of the Handspring Phone Library support a common API. This API is broken up into various categories for easier management. This file defines the Miscellaneous category. These API calls are Miscellaneous calls that don't fit into any other category. Many of them are device control.

Definition in file HsPhoneMisc.h.

Include dependency graph for HsPhoneMisc.h:

Go to the source code of this file.

## Functions

- Err PhnLibGetLineState (UInt16 refNum, UInt16 line, PhnLineStatePtr lineState)
    Retrieve the Line state.
- Err PhnLibGetRadioState (UInt16 refNum, PhnRadioStatePtr radioState)
    Retrieve state information about the radio.
- Boolean PhnLibCardInfo (UInt16 refNum, CharPtr *manufacturer, CharPtr *model, CharPtr *version, CharPtr *serial)
    Parameters:

      | refNum,: | IN:

- Err PhnLibConnectionAvailable (UInt16 refNum, PhnConnectionEnum connection, Boolean *pAvailable)
    Checks to see if a connection can be made.
- Err PhnLibStartVibrate (UInt16 refNum, Boolean pulse, Boolean repeat)
    This API have been deprecated. Please use “HsIndicatorState.”.
- Err PhnLibStopVibrate (UInt16 refNum)
    This API have been deprecated. Please use “HsIndicatorState.”.
- Err PhnLibErrorRate (UInt16 refNum, WordPtr errorRate)
    Parameters:

      | refNum,: | IN:

- void PhnLibGetErrorText (UInt16 refNum, Err error, CharPtr buffer, UInt16 bufferLen)
    Parameters:

      | refNum,: | IN:

- UInt16 PhnLibGetCallCountByService (UInt16 refNum, PhoneServiceClassType service)
    Locate the call item that has the specified service if such item exists return the total number of call items that has the same service.
- Err PhnLibGetEchoCancellation (UInt16 refNum, Boolean *echoCancellationOn)
    Parameters:

      | refNum,: | IN:

- Err PhnLibSetEchoCancellation (UInt16 refNum, Boolean echoCancellationOn)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetEquipmentMode (UInt16 refNum, PhnEquipmentMode *equipmentMode)
    Parameters:

      | refNum,: | IN:

- Err PhnLibSetEquipmentMode (UInt16 refNum, PhnEquipmentMode equipmentMode)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetHeadsetConnectedInfo (UInt16 refNum, Boolean *headsetConnected)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetMicrophone (UInt16 refNum, Int16 *gain)
    Parameters:

      | refNum,: | IN:

- Err PhnLibSetMicrophone (UInt16 refNum, Int16 gain)
    Parameters:

      | refNum,: | IN:

- Boolean PhnLibCardInfoEx (UInt16 refNum, CharPtr *manufacturer, CharPtr *model, CharPtr *modemSWRev, CharPtr *esn, CharPtr *prlRev, CharPtr *hostSWRev, CharPtr *modemHWRev, CharPtr *priChecksum, Word *eriVer, Boolean *isEriSet)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetPhoneCallStatus (UInt16 refNum, UInt32 *phnFlags)
    Parameters:

      | refNum,: | IN:

- Err PhnLibMute (UInt16 refNum, Boolean toMute)
    Parameters:

      | refNum,: | IN:

- Err PhnLibIsCallMuted (UInt16 refNum, Boolean *isMute)
    Parameters:

      | refNum,: | IN:

- Boolean PhnLibIsPhoneActivated (UInt16 refNum)
    Parameters:

      | refNum,: | IN:

- Err PhnLibMiscDebugInfo (UInt16 refNum, Boolean bSet, VoidPtr debugInfoP, UInt16 infoLen)
    Parameters:

      | refNum,: | IN:

- Err PhnLibAttrGet (UInt16 refNum, UInt16 attr, UInt32 flags, void *dataP)
    Parameters:

      | refNum,: | IN:

- Err PhnLibAttrSet (UInt16 refNum, UInt16 attr, UInt32 flags, void *dataP)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetDeviceID (UInt16 refNum, CharPtr *deviceId)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetNoiseCancellation (UInt16 refNum, Boolean *noiseCancellationP)
    Parameters:

      | refNum,: | IN:

- Err PhnLibSetNoiseCancellation (UInt16 refNum, Boolean noiseCancellation)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetMEID (UInt16 refNum, CharPtr *bufferP)
    Parameters:

      | refNum,: | IN:

- Err PhnLibGetBaseStationIdInfo (UInt16 refNum, UInt16 *base_id, UInt16 *sid, UInt16 *nid)
    Parameters:

      | pointer | to base_id, sid, nid storage IN:

- Err PhnLibGetMMSUAString (UInt16 refNum, char *pUaStr, UInt32 buf_len)
    Parameters:

      | pointer | to buffer of char IN: pUaStr and length of the buffer provided OUT: pUaStr : param pointer to buffer containing values

## Function Documentation

Err PhnLibAttrGet | ( | UInt16 | refNum,
|  | UInt16 | attr,
|  | UInt32 | flags,
|  | void * | dataP |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | attr,: | IN:
  | flags,: | IN:
  | dataP,: | IN:

Return values:

  | Err | Error code.

Err PhnLibAttrSet | ( | UInt16 | refNum,
|  | UInt16 | attr,
|  | UInt32 | flags,
|  | void * | dataP |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | attr,: | IN:
  | flags,: | IN:
  | dataP,: | IN:

Return values:

  | Err | Error code.

Boolean PhnLibCardInfo | ( | UInt16 | refNum,
|  | CharPtr * | manufacturer,
|  | CharPtr * | model,
|  | CharPtr * | version,
|  | CharPtr * | serial |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | manufacturer,: | IN:
  | model,: | IN:
  | version,: | IN:
  | serial | IN:

Return values:

  | Err | Error code.

Boolean PhnLibCardInfoEx | ( | UInt16 | refNum,
|  | CharPtr * | manufacturer,
|  | CharPtr * | model,
|  | CharPtr * | modemSWRev,
|  | CharPtr * | esn,
|  | CharPtr * | prlRev,
|  | CharPtr * | hostSWRev,
|  | CharPtr * | modemHWRev,
|  | CharPtr * | priChecksum,
|  | Word * | eriVer,
|  | Boolean * | isEriSet |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | manufacturer,: | IN:
  | model,: | IN:
  | modemSWRev,: | IN:
  | esn,: | IN:
  | prlRev,: | IN:
  | hostSWRev,: | IN:
  | modemHWRev,: | IN:
  | priChecksum,: | IN:
  | *eriver,: | IN:
  | *isEriSet,: | IN:

Return values:

  | Err | Error code.

Err PhnLibConnectionAvailable | ( | UInt16 | refNum,
|  | PhnConnectionEnum | connection,
|  | Boolean * | pAvailable |
| ) |  |  |

Checks to see if a connection can be made.

Parameters:

  | refNum,: | IN: Library reference number obtained from SysLibLoad.
  | connection,: | IN: Type of connection to be made.
  | pAvailable,: | IN: Result indicating if a connection is available.

Return values:

  | 0 | for success; otherwise failed and returned an error code as defined in “Phone Library Error Codes.”

Err PhnLibErrorRate | ( | UInt16 | refNum,
|  | WordPtr | errorRate |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | errorRate,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetBaseStationIdInfo | ( | UInt16 | refNum,
|  | UInt16 * | base_id,
|  | UInt16 * | sid,
|  | UInt16 * | nid |
| ) |  |  |

Parameters:

  | pointer | to base_id, sid, nid storage IN:

Parameters:

  | base_id,sid,nid | OUT: contains the values

Return values:

  | Err | Error code.

UInt16 PhnLibGetCallCountByService | ( | UInt16 | refNum,
|  | PhoneServiceClassType | service |
| ) |  |  |

Locate the call item that has the specified service if such item exists return the total number of call items that has the same service.

Parameters:

  | refNum,: | IN: Library reference number obtained from SysLibLoad.
  | service,: | IN: The specified connection service (can OR bit combination)

Return values:

  | Number | of call items that has the same status.

Err PhnLibGetDeviceID | ( | UInt16 | refNum,
|  | CharPtr * | deviceId |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | deviceId,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetEchoCancellation | ( | UInt16 | refNum,
|  | Boolean * | echoCancellationOn |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | echoCancellationOn,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetEquipmentMode | ( | UInt16 | refNum,
|  | PhnEquipmentMode * | equipmentMode |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | equipmentMode,: | IN:

Return values:

  | Err | Error code.

void PhnLibGetErrorText | ( | UInt16 | refNum,
|  | Err | error,
|  | CharPtr | buffer,
|  | UInt16 | bufferLen |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | error,: | IN:
  | buffer,: | IN:
  | bufferLen,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetHeadsetConnectedInfo | ( | UInt16 | refNum,
|  | Boolean * | headsetConnected |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | headsetConnected,: | IN:

Return values:

  | 0 | for success; otherwise failed and returned an error code as defined in “Phone Library Error Codes.”

Err PhnLibGetLineState | ( | UInt16 | refNum,
|  | UInt16 | line,
|  | PhnLineStatePtr | lineState |
| ) |  |  |

Retrieve the Line state.

Parameters:

  | refNum,: | IN: Library reference number obtained from SysLibLoad.
  | line,: | IN: Line to query for
  | lineState,: | IN: State of the Line

Return values:

  | 0 | for success; otherwise failed and returned an error code as defined in “Phone Library Error Codes.”

Err PhnLibGetMEID | ( | UInt16 | refNum,
|  | CharPtr * | bufferP |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | bufferP,: | OUT: contains MEID or ESN (for non-MEID devices)

Return values:

  | Err | Error code.

Err PhnLibGetMicrophone | ( | UInt16 | refNum,
|  | Int16 * | gain |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | gain,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetMMSUAString | ( | UInt16 | refNum,
|  | char * | pUaStr,
|  | UInt32 | buf_len |
| ) |  |  |

Parameters:

  | pointer | to buffer of char IN: pUaStr and length of the buffer provided OUT: pUaStr : param pointer to buffer containing values

Return values:

  | Err | Error code.

Err PhnLibGetNoiseCancellation | ( | UInt16 | refNum,
|  | Boolean * | noiseCancellationP |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | noiseCancellationP,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetPhoneCallStatus | ( | UInt16 | refNum,
|  | UInt32 * | phnFlags |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | phnFlags,: | IN:

Return values:

  | Err | Error code.

Err PhnLibGetRadioState | ( | UInt16 | refNum,
|  | PhnRadioStatePtr | radioState |
| ) |  |  |

Retrieve state information about the radio.

Parameters:

  | refNum,: | IN: Library reference number obtained from SysLibLoad.
  | radioState,: | IN: State of the Radio

Return values:

  | 0 | for success; otherwise failed and returned an error code as defined in “Phone Library Error Codes.”

Err PhnLibIsCallMuted | ( | UInt16 | refNum,
|  | Boolean * | isMute |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | isMute,: | IN:

Return values:

  | Err | Error code.

Boolean PhnLibIsPhoneActivated | ( | UInt16 | refNum | ) |

Parameters:

  | refNum,: | IN:

Return values:

  | Err | Error code.

Err PhnLibMiscDebugInfo | ( | UInt16 | refNum,
|  | Boolean | bSet,
|  | VoidPtr | debugInfoP,
|  | UInt16 | infoLen |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | bSet,: | IN:
  | debugInfoP | IN:
  | infoLen,: | IN:

Return values:

  | Err | Error code.

Err PhnLibMute | ( | UInt16 | refNum,
|  | Boolean | toMute |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | toMute,: | IN:

Return values:

  | Err | Error code.

Err PhnLibSetEchoCancellation | ( | UInt16 | refNum,
|  | Boolean | echoCancellationOn |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | echoCancellationOn,: | IN:

Return values:

  | Err | Error code.

Err PhnLibSetEquipmentMode | ( | UInt16 | refNum,
|  | PhnEquipmentMode | equipmentMode |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | equipmentMode,: | IN:

Return values:

  | Err | Error code.

Err PhnLibSetMicrophone | ( | UInt16 | refNum,
|  | Int16 | gain |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | gain,: | IN:

Return values:

  | Err | Error code.

Err PhnLibSetNoiseCancellation | ( | UInt16 | refNum,
|  | Boolean | noiseCancellation |
| ) |  |  |

Parameters:

  | refNum,: | IN:

Parameters:

  | noiseCancellation,: | IN:

Return values:

  | Err | Error code.

Err PhnLibStartVibrate | ( | UInt16 | refNum,
|  | Boolean | pulse,
|  | Boolean | repeat |
| ) |  |  |

This API have been deprecated. Please use “HsIndicatorState.”.

Parameters:

  | refNum,: | IN:
  | pulse,: | IN:
  | repeat,: | IN:

Return values:

  | Err | Error code.

Err PhnLibStopVibrate | ( | UInt16 | refNum | ) |

This API have been deprecated. Please use “HsIndicatorState.”.

Parameters:

  | refNum,: | IN:

Return values:

  | Err | Error code.

Top | Palm Developer Network © 2004-2008, Palm, Inc. All rights reserved. Generated on Fri Jun 13 10:07:21 2008 for Palm API Guide