API Guide Home (Online version only) |

# HsSoundLibCommon.h File Reference

## Detailed Description

Public 68K/Arm common header file for sound support for Treo 600, Treo 650, and Treo 700p smartphones and later models.

This file contains the common constants and structures to be used with the sound library.

Definition in file HsSoundLibCommon.h.

Include dependency graph for HsSoundLibCommon.h:

Go to the source code of this file.

## Data Structures

- struct HsSndPortInfo
    Holds sound port information. More...
- struct HsSndBufferData
    Holds sound buffer information. More...
- struct HsSndMidiProgressMsg

## Gain Envelope Definitions

Used as attackEnvID parameter to function PmSndStreamSetAttackEnvID.

- #define pmSndAttackEnvIDRings (hsSndBufFlags_attackEnvRings)
- #define pmSndAttackEnvIDVibeRing (hsSndBufFlags_attackEnvVibeRings)
- #define pmSndAttackEnvIDRings2 (hsSndBufFlags_attackEnvRings2)
- #define pmSndAttackEnvIDVibeRing2 (hsSndBufFlags_attackEnvVibeRings2)
- #define pmSndBayID_AUDP 0x0F000000
- #define PM_AUDP_CLASS_MASK 0x4000
- #define PM_AUDP_CLASS(n) ((n) | PM_AUDP_CLASS_MASK)
- #define pmSndPrefID_AppsGroupHoldType PM_AUDP_CLASS(0x0001)
- #define pmSndPrefID_JackOutIfMicUnused PM_AUDP_CLASS(0x0002)
- #define pmSndPrefID_PhoneRxGainLimit PM_AUDP_CLASS(0x0003)
- #define pmSndPrefID_WakeOnAnswerBtn PM_AUDP_CLASS(0x0004)
- #define pmSndPrefID_AudioTable PM_AUDP_CLASS(0x0005)
- #define pmSndPrefID_GsmMccArray PM_AUDP_CLASS(0x0006)
- #define pmSndPrefID_AthenaActive PM_AUDP_CLASS(0x0007)
- #define pmSndPrefID_SleepMode PM_AUDP_CLASS(0x0008)
- #define pmSndPrefID_AGCEvent PM_AUDP_CLASS(0x0009)
- #define pmSndPrefID_AthenaAudio PM_AUDP_CLASS(0x000A)
- #define pmSndPref_WakeOnAnswerBtn_Disable (0)
- #define pmSndPref_WakeOnAnswerBtn_Enable (1)
- #define pmSndPref_AthenaActive_No (0)
- #define pmSndPref_AthenaActive_Yes (1)
- #define pmSndPref_AthenaAudio_NoRouting (0)
- #define pmSndPref_AthenaAudio_IfMicPresent (16)
- #define pmSndPref_AthenaAudio_Unconditional (32)
- #define PM_AUDP(n) ((n) | pmSndBayID_AUDP)
- #define pmSndSwitchID_Preferences PM_AUDP(0x00400000)
- #define pmAudioClkTickRef ((PmClkTickRef) 0x00000001)
- typedef UInt16 PmSndPrefID
- typedef UInt32 PmClkTickRef

## Defines

- #define hsSndBayID_AC97 0x01000000
- #define hsSndMidiMsg_SetVolume 1
- #define hsSndMidiProgressMsg_Signature 'MidP'
- #define hsSndPortInfo_Signature 'SPRT'
- #define hsSndBufferData_Signature 'SBDA'

HsSoundLib information

- #define hsSndLibVersion 0x010D0000
- #define hsSoundLibCreatorID hsFileSoundLib
- #define hsSoundLibTypeID sysFileTLibrary
- #define hsSoundLibName "HsSoundLib"

Sound library event notifications
Note: Each one of these notifications are reserved as Creator IDs with PalmSource

- #define hsSndNotify hsFileSoundLib
- #define hsSndNotifyUnplugged 'hOff'
- #define hsSndNotifyHeadset 'hSet'
- #define hsSndNotifyHeadphones 'hPho'
- #define hsSndNotifyHybrid 'hHyb'
- #define hsSndNotifyNotHybrid 'hNoH'
- #define hsSndNotifyAnswerButton 'hAns'
- #define hsSndNotifyAnswerHold 'hHol'
- #define hsSndNotifyAnswerRelease 'hRel'
- #define hsSndNotifyRingerSwitchOn 'hROn'
- #define hsSndNotifyRingerSwitchOff 'hROf'
- #define hsSndNotifyHighPriority 'hHPr'
- #define hsSndNotifyAlert 'hAlr'
- #define hsSndNotifyCarkitActive 'hCar'
- #define hsSndNotifyCarkitInactive 'hCOf'
- #define hsSndNotifyAthenaAudio 'hAta'

Sound library resource types

- #define hsSndRsrcAudioTableType 'hTbl'
- #define hsSndRsrcAudioTableID 25000

Sound library error codes

- #define hsSndErrBase hsSoundLibErrorClass
- #define HS_SND_ERR(x) ((Err)((x) + hsSndErrBase))
- #define hsSndErr_Failed (HS_SND_ERR(1))
- #define hsSndErr_NotSupported (HS_SND_ERR(2))
- #define hsSndErr_InvalidPort (HS_SND_ERR(3))
- #define hsSndErr_PortCannotMute (HS_SND_ERR(4))
- #define hsSndErr_PortCannotVolume (HS_SND_ERR(5))
- #define hsSndErr_PortCannotBoost (HS_SND_ERR(6))
- #define hsSndErr_PortCannotPan (HS_SND_ERR(7))
- #define hsSndErr_InvalidSwitch (HS_SND_ERR(8))
- #define hsSndErr_UnknownSndParam (HS_SND_ERR(9))
- #define hsSndErr_UnknownPortClass (HS_SND_ERR(10))
- #define hsSndErr_PortIDNotInClass (HS_SND_ERR(11))
- #define hsSndErr_PortMuteLocked (HS_SND_ERR(12))
- #define hsSndErr_PortVolumeLocked (HS_SND_ERR(13))
- #define hsSndErr_PortBoostLocked (HS_SND_ERR(14))
- #define hsSndErr_PortPanLocked (HS_SND_ERR(15))
- #define hsSndErr_DoMidiProgressMsg (HS_SND_ERR(16))
- #define hsSndErr_UnknownClkRef (HS_SND_ERR(17))
- #define hsSndErr_InvalidPrefValue (HS_SND_ERR(18))
- #define hsSndErr_LastPublicError (HS_SND_ERR(63))

Sound mode volume controls
Use with HsSndGetUserVolume and HsSndSetUserVolume.

- #define hsSndMode_Current ((HsSndMode) 0x0000)
- #define hsSndMode_Receiver ((HsSndMode) 0x0001)
- #define hsSndMode_Speakerphone ((HsSndMode) 0x0002)
- #define hsSndMode_SpeakerHost ((HsSndMode) 0x0003)
- #define hsSndMode_Headset ((HsSndMode) 0x0004)
- #define hsSndMode_Headphones ((HsSndMode) 0x0005)
- #define hsSndMode_HeadphonesHost ((HsSndMode) 0x0006)
- #define hsSndMode_Carkit ((HsSndMode) 0x0007)
- #define hsSndMode_Reserved ((HsSndMode) 0x0008)

Tone type parameter

- #define hsSndToneType_Square 0

Utility Macros - I

- #define HS_AC97(n) ((n) | hsSndBayID_AC97)
- #define HS_RDIO(n) ((n) | hsSndBayID_Radio)
- #define HsSndParamValue_SetWithLock(v) (((v) & ~hsSndParamMode_Mask) | hsSndParamMode_LockParam)
- #define HsSndParamValue_SetWithUnlock(v) (((v) & ~hsSndParamMode_Mask) | hsSndParamMode_UnlockParam)
- #define HsSndParamValue_RemoveMode(v) (((v) & 0x8000)? (v) | hsSndParamMode_Mask : (v) & ~hsSndParamMode_Mask)

Sound switch configuration types
Used with HsSndSwitchID.

- #define hsSndSwitchID_InRadioSpkr HS_AC97(0x00010000)
- #define hsSndSwitchID_OutRadioMic HS_AC97(0x00020000)
- #define hsSndSwitchID_InMic HS_AC97(0x00030000)
- #define hsSndSwitchID_InHostPlay HS_AC97(0x00040000)
- #define hsSndSwitchID_OutHostRec HS_AC97(0x00050000)

Sound port configuration types
Used with HsSndPortID.

- #define hsSndPortID_Off 0x00000000
- #define hsSndPortID_Current HS_AC97(0x00000000)
- #define hsSndPortID_OutReceiver HS_AC97(0x00000001)
- #define hsSndPortID_OutSpeaker HS_AC97(0x00000002)
- #define hsSndPortID_OutHeadset HS_AC97(0x00000003)
- #define hsSndPortID_OutHeadphones HS_AC97(0x00000004)
- #define hsSndPortID_OutSpeakerAuto HS_AC97(0x00000005)
- #define hsSndPortID_InLineRec HS_AC97(0x00000006)
- #define hsSndPortID_InBaseMic HS_AC97(0x00000007)
- #define hsSndPortID_InHeadsetMic HS_AC97(0x00000008)
- #define hsSndPortID_InMicAuto HS_AC97(0x00000009)
- #define hsSndPortID_OutRadioMic HS_AC97(0x0000000A)
- #define hsSndPortID_InRadioSpkr HS_AC97(0x0000000B)
- #define hsSndPortID_OutHostRec HS_AC97(0x0000000C)
- #define hsSndPortID_InHostPlay HS_AC97(0x0000000D)
- #define hsSndPortID_OutBtHeadset HS_AC97(0x0000000E)
- #define hsSndPortID_OutBtHandsfree HS_AC97(0x0000000F)
- #define hsSndPortID_InHostBaseMic HS_AC97(0x00000010)
- #define hsSndPortID_InHostHeadsetMic HS_AC97(0x00000011)
- #define hsSndPortID_InHostPhone HS_AC97(0x00000012)
- #define hsSndPortID_InCarkit HS_AC97(0x00000013)
- #define hsSndPortID_OutCarkit HS_AC97(0x00000014)
- #define hsSndPortID_InBtHeadset HS_AC97(0x00000015)
- #define hsSndPortID_InBtHandsfree HS_AC97(0x00000016)
- #define hsSndPortID_LastPort HS_AC97(0x00000016)

RadioBayID

- #define hsSndBayID_Radio 0x02000000

Sound switch configuration type for Radio patch bay
Used with HsSndSwitchID.

- #define hsSndSwitchID_RadioCall HS_RDIO(0x00010000)

Sound port configuration type for hsSndSwitchID_RadioCall
hsSndPortID_Off is already defined for all patch bays. Use it to turn off the switch indicating no radio call connected.

- #define hsSndPortID_ConnectCall HS_RDIO(0x00000020)

Sound port classes
Used when passing a HsSndPortClass parameter in HsSndSwitchGetPort and HsSndSwitchSetPort functions.

- #define hsSndPortClass_Virtual ((UInt16) 0)
- #define hsSndPortClass_Real ((UInt16) 1)
- #define hsSndPortClass_BaseDefault ((UInt16) 2)
- #define hsSndPortClass_Anchor ((UInt16) 3)

Sound parameters
Used when passing a parameter of type HsSndParam.

- #define hsSndParam_Volume ((UInt16) 1)
- #define hsSndParam_Mute ((UInt16) 2)
- #define hsSndParam_Boost ((UInt16) 3)
- #define hsSndParam_Pan ((UInt16) 4)

Sound parameter expansion macros
Used to add sound parameter values for additional sound parameter control. For example, muteState = HsSndParamValue_SetWithLock(hsSndMute_Enable);.

- #define hsSndParamMode_Mask 0x7000
- #define hsSndParamMode_Normal 0x0000
- #define hsSndParamMode_LockParam 0x4000
- #define hsSndParamMode_UnlockParam 0x2000

Mute parameters
Used to enable or disable a hsSndParam_Mute parameter.

- #define hsSndMute_Enable 1
- #define hsSndMute_Disable 0

Boost parameters
Used to enable or disable a hsSndParam_Boost parameter.

- #define hsSndBoost_Enable 1
- #define hsSndBoost_Disable 0

Pan parameters
Used as special hsSndParam_Pan parameters otherwise use actual Pan value.

- #define hsSndPan_Middle ((Int16) 0x0000)
- #define hsSndPan_Right ((Int16) 0x7FFF)
- #define hsSndPan_Left ((Int16) 0x8000)
- #define hsSndPan_RightNormal ((Int16) 0x07FF)
- #define hsSndPan_LeftNormal ((Int16) 0x0800)

Sound port flag settings
Used with the "flags" variable in HsSndPortInfo structure.

- #define hsSndPortFlags_Enabled 0x00000001
- #define hsSndPortFlags_Disabled 0x00000000
- #define hsSndPortFlags_EnableMask 0x00000001
- #define hsSndPortFlags_MuteOn 0x00000002
- #define hsSndPortFlags_MuteOff 0x00000000
- #define hsSndPortFlags_MuteMask 0x00000002
- #define hsSndPortFlags_TypeDigital 0x00000004
- #define hsSndPortFlags_TypeAnalog 0x00000000
- #define hsSndPortFlags_TypeMask 0x00000004
- #define hsSndPortFlags_BoostOn 0x00000008
- #define hsSndPortFlags_BoostOff 0x00000000
- #define hsSndPortFlags_BoostMask 0x00000008
- #define hsSndPortFlags_CanInputOnly 0x00000000
- #define hsSndPortFlags_CanOutputOnly 0x00000010
- #define hsSndPortFlags_CanIOSelect 0x00000020
- #define hsSndPortFlags_CanIOBothways 0x00000030
- #define hsSndPortFlags_CanIOMask 0x00000030
- #define hsSndPortFlags_InputOn 0x00000040
- #define hsSndPortFlags_InputOff 0x00000000
- #define hsSndPortFlags_InputMask 0x00000040
- #define hsSndPortFlags_OutputOn 0x00000080
- #define hsSndPortFlags_OutputOff 0x00000000
- #define hsSndPortFlags_OutputMask 0x00000080
- #define hsSndPortFlags_CanMute_Yes 0x00000100
- #define hsSndPortFlags_CanMute_No 0x00000000
- #define hsSndPortFlags_CanMuteMask 0x00000100
- #define hsSndPortFlags_CanBoost_Yes 0x00000200
- #define hsSndPortFlags_CanBoost_No 0x00000000
- #define hsSndPortFlags_CanBoostMask 0x00000200
- #define hsSndPortFlags_CanPan_Yes 0x00000400
- #define hsSndPortFlags_CanPan_No 0x00000000
- #define hsSndPortFlags_CanPanMask 0x00000400
- #define hsSndPortFlags_CanVol_Yes 0x00000800
- #define hsSndPortFlags_CanVol_No 0x00000000
- #define hsSndPortFlags_CanVolMask 0x00000800
- #define hsSndPortFlags_Mute_Locked 0x00001000
- #define hsSndPortFlags_Mute_Unlocked 0x00000000
- #define hsSndPortFlags_Mute_LockMask 0x00001000
- #define hsSndPortFlags_Boost_Locked 0x00002000
- #define hsSndPortFlags_Boost_Unlocked 0x00000000
- #define hsSndPortFlags_Boost_LockMask 0x00002000
- #define hsSndPortFlags_Pan_Locked 0x00004000
- #define hsSndPortFlags_Pan_Unlocked 0x00000000
- #define hsSndPortFlags_Pan_LockMask 0x00004000
- #define hsSndPortFlags_Vol_Locked 0x00008000
- #define hsSndPortFlags_Vol_Unlocked 0x00000000
- #define hsSndPortFlags_Vol_LockMask 0x00008000

Command flag settings
Used with the "Commandflags" parameter in HsSndFormatPlay function.

- #define hsSndCmdFlags_noWait 0x00000001
- #define hsSndCmdFlags_yesWait 0x00000000
- #define hsSndCmdFlags_waitMask 0x00000001

Sound buffer flag settings
Used with the "flags" parameter in HsSndBufferData.

- #define hsSndBufFlags_canInterrupt 0x0001
- #define hsSndBufFlags_cannotInterrupt 0x0000
- #define hsSndBufFlags_interruptMask 0x0001
- #define hsSndBufFlags_yesRepeat 0x0002
- #define hsSndBufFlags_noRepeat 0x0000
- #define hsSndBufFlags_repeatMask 0x0002
- #define hsSndBufFlags_yesEndDelay 0x0004
- #define hsSndBufFlags_noEndDelay 0x0000
- #define hsSndBufFlags_endDelayMask 0x0004
- #define hsSndBufFlags_attackEnvNone 0x0000
- #define hsSndBufFlags_attackEnvRings 0x0010
- #define hsSndBufFlags_attackEnvVibeNone 0x0020
- #define hsSndBufFlags_attackEnvVibeRings 0x0030
- #define hsSndBufFlags_attackEnvRings2 0x0040
- #define hsSndBufFlags_attackEnvReserved1 0x0050
- #define hsSndBufFlags_attackEnvVibeRings2 0x0060
- #define hsSndBufFlags_attackEnvReserved2 0x0070
- #define hsSndBufFlags_attackEnvMask 0x00F0
- #define hsSndBufFlags_interruptDefault 0x0000
- #define hsSndBufFlags_interruptPhone 0x0100
- #define hsSndBufFlags_interruptModeMask 0x0300

Buffer amplitude settings
Used with HsSndBufferData.amplitude field.

- #define hsSndAmplitude_silent ((UInt32) 0)
- #define hsSndAmplitude_unity ((UInt32) 1024)

Buffer control macros
Use these macros to set or get the proper control in HsSndBufferData.controls field.

- #define HsSndBufControl_SetRepeat(controls, value) (controls = ((controls & 0xFFFFFF00) | (((UInt32) value) & 0xFF) ))
- #define HsSndBufControl_GetRepeat(controls) (controls & 0x000000FF)
- #define HsSndBufControl_SetEndDelay(controls, value) (controls = ((controls & 0xFFFF00FF) | ((((UInt32) value) & 0xFF) << 8)))
- #define HsSndBufControl_GetEndDelay(controls) ((controls & 0x0000FF00) >> 8)
- #define hsSndBufControl_repeatForever (0xFF)

## Typedefs

- typedef unsigned long long PmSndU64
- typedef UInt8 hsSndSysBeepType
- typedef Int16 HsSndMode
- typedef UInt16 HsSndCmdType
- typedef UInt32 HsSndPortID
- typedef UInt32 HsSndSwitchID
- typedef UInt16 HsSndParam
- typedef UInt16 HsSndPortClass
- typedef UInt16 HsSndFormatType
- typedef struct HsSndPortInfo * HsSndPortInfoPtr
- typedef Err(*) HsSndBufferProc (void *userdata, UInt32 flags, void *buffer, UInt32 bytesUsed, UInt32 time)
    Callback function used under various conditions with sound.

## Enumerations

- enum hsSndSysBeepTag {
  hsSndCardInsert = 64,
  hsSndCardRemove,
  hsSndSyncStart,
  hsSndSyncStop,
  hsSndChargerAttach,
  hsSndChargerDetach,
  hsSndRadioOn,
  hsSndRadioOff,
  hsSndBatFull,
  hsSndBatLow,
  hsSndBatShutdown,
  hsSndDeepWake,
  hsSndDeepSleep,
  hsSndRadioInServiceArea,
  hsSndRadioOutServiceArea
  }
- enum HsSndCmdEnumTag {
  hsSndCmdPlay = 1,
  hsSndCmdStop
  }
- enum HsSndFormatEnumTag {
  hsSndFormatMidi = 2,
  hsSndFormatAmr,
  pmSndFormatSetAttackEnvID,
  pmSndFormatPauseStream,
  pmSndFormatResumeStream,
  pmSndFormatSetStoppable
  }

## Define Documentation

#define HS_AC97 | ( | n |  | ) | ((n) | hsSndBayID_AC97)

Associates the AC97 Bay ID with other element IDs

Definition at line 219 of file HsSoundLibCommon.h.

#define HS_RDIO | ( | n |  | ) | ((n) | hsSndBayID_Radio)

Associates the Radio Bay ID (hsSndBayID_Radio) with other element IDs

Definition at line 220 of file HsSoundLibCommon.h.

#define HS_SND_ERR | ( | x |  | ) | ((Err)((x) + hsSndErrBase))

Definition at line 103 of file HsSoundLibCommon.h.

#define hsSndAmplitude_silent ((UInt32) 0)

Minimum volume value used to silent a port

Definition at line 521 of file HsSoundLibCommon.h.

#define hsSndAmplitude_unity ((UInt32) 1024)

Volume value used to pass through sound without amplification or attenuation.

Definition at line 522 of file HsSoundLibCommon.h.

#define hsSndBayID_AC97 0x01000000

An AC97 compatible chip is supported as the analog sound patch bay.

Definition at line 212 of file HsSoundLibCommon.h.

#define hsSndBayID_Radio 0x02000000

A defined patch bay for Telephony use.

Definition at line 276 of file HsSoundLibCommon.h.

#define hsSndBoost_Disable 0

Disables boost on a port.

Definition at line 350 of file HsSoundLibCommon.h.

#define hsSndBoost_Enable 1

Activates boost on a port.

Definition at line 349 of file HsSoundLibCommon.h.

#define HsSndBufControl_GetEndDelay | ( | controls |  | ) | ((controls & 0x0000FF00) >> 8)

Definition at line 625 of file HsSoundLibCommon.h.

#define HsSndBufControl_GetRepeat | ( | controls |  | ) | (controls & 0x000000FF)

Definition at line 623 of file HsSoundLibCommon.h.

#define hsSndBufControl_repeatForever (0xFF)

Definition at line 626 of file HsSoundLibCommon.h.

#define HsSndBufControl_SetEndDelay | ( | controls,
|  | value |  | ) | (controls = ((controls & 0xFFFF00FF) | ((((UInt32) value) & 0xFF) << 8)))

Definition at line 624 of file HsSoundLibCommon.h.

#define HsSndBufControl_SetRepeat | ( | controls,
|  | value |  | ) | (controls = ((controls & 0xFFFFFF00) | (((UInt32) value) & 0xFF) ))

Definition at line 622 of file HsSoundLibCommon.h.

#define hsSndBufferData_Signature 'SBDA'

Definition at line 610 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvMask 0x00F0

Mask reserves up to 16 different envelope IDs.

Definition at line 508 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvNone 0x0000

(Default) No attack envelope to be used.

Definition at line 500 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvReserved1 0x0050

Reserved for future use. Do Not use

Definition at line 505 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvReserved2 0x0070

Reserved for future use. Do Not use

Definition at line 507 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvRings 0x0010

Use special attack envelope style suitable for call ringtones.

Definition at line 501 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvRings2 0x0040

Use type 2 attack envelope suitable for call ringtones (stright ramp up)

Definition at line 504 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvVibeNone 0x0020

Use special attack envelope with initial vibration before envelope

Definition at line 502 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvVibeRings 0x0030

Use special attack envelope for ringtones with initial vibration before envelope

Definition at line 503 of file HsSoundLibCommon.h.

#define hsSndBufFlags_attackEnvVibeRings2 0x0060

Use type 2 attack enveloper with initial vibration before envelope

Definition at line 506 of file HsSoundLibCommon.h.

#define hsSndBufFlags_canInterrupt 0x0001

Playback can be interrupted by user events.

Definition at line 488 of file HsSoundLibCommon.h.

#define hsSndBufFlags_cannotInterrupt 0x0000

(Default) Playback cannot be interrupted by user events.

Definition at line 489 of file HsSoundLibCommon.h.

#define hsSndBufFlags_endDelayMask 0x0004

No definition.

Definition at line 498 of file HsSoundLibCommon.h.

#define hsSndBufFlags_interruptDefault 0x0000

(Default) interrupt sound on most user events if hsSndBufFlags_canInterrupt flag is set.

Definition at line 510 of file HsSoundLibCommon.h.

#define hsSndBufFlags_interruptMask 0x0001

No definition.

Definition at line 490 of file HsSoundLibCommon.h.

#define hsSndBufFlags_interruptModeMask 0x0300

Mask reserves 2 bits for up to 4 different interrupt modes.

Definition at line 512 of file HsSoundLibCommon.h.

#define hsSndBufFlags_interruptPhone 0x0100

interrupt on user events (except Touch, Navigation arrows and pens down).

Definition at line 511 of file HsSoundLibCommon.h.

#define hsSndBufFlags_noEndDelay 0x0000

(Default) No delay after last batch of audio data processed.

Definition at line 497 of file HsSoundLibCommon.h.

#define hsSndBufFlags_noRepeat 0x0000

(Default) Buffer used only once.

Definition at line 493 of file HsSoundLibCommon.h.

#define hsSndBufFlags_repeatMask 0x0002

No definition.

Definition at line 494 of file HsSoundLibCommon.h.

#define hsSndBufFlags_yesEndDelay 0x0004

Delay completion of playback using the "delay" count in HsSndBufferData.controls.

Definition at line 496 of file HsSoundLibCommon.h.

#define hsSndBufFlags_yesRepeat 0x0002

Repeat the buffer using the "repeat" count in HsSndBufferData.controls.

Definition at line 492 of file HsSoundLibCommon.h.

#define hsSndCmdFlags_noWait 0x00000001

Use wait period for the play command.

Definition at line 462 of file HsSoundLibCommon.h.

#define hsSndCmdFlags_waitMask 0x00000001

No definition.

Definition at line 464 of file HsSoundLibCommon.h.

#define hsSndCmdFlags_yesWait 0x00000000

No wait period for the play command.

Definition at line 463 of file HsSoundLibCommon.h.

#define hsSndErr_DoMidiProgressMsg (HS_SND_ERR(16))

Special message returned by Midi progress callback to request a dynamic volume change.

Definition at line 119 of file HsSoundLibCommon.h.

#define hsSndErr_Failed (HS_SND_ERR(1))

The operation or request failed.

Definition at line 104 of file HsSoundLibCommon.h.

#define hsSndErr_InvalidPort (HS_SND_ERR(3))

An invalid port was passed to a function. Operation failed.

Definition at line 106 of file HsSoundLibCommon.h.

#define hsSndErr_InvalidPrefValue (HS_SND_ERR(18))

Unsupported or invalid audio preference value

Definition at line 121 of file HsSoundLibCommon.h.

#define hsSndErr_InvalidSwitch (HS_SND_ERR(8))

An invalid switch was passed to a function. Operation failed.

Definition at line 111 of file HsSoundLibCommon.h.

#define hsSndErr_LastPublicError (HS_SND_ERR(63))

just a marker for last public library error code, private sound error codes start at 64

Definition at line 122 of file HsSoundLibCommon.h.

#define hsSndErr_NotSupported (HS_SND_ERR(2))

Attempt to use functionality that is not supported in this version.

Definition at line 105 of file HsSoundLibCommon.h.

#define hsSndErr_PortBoostLocked (HS_SND_ERR(14))

Unable to change boost state when hsSndParamMode_Normal is the default.

Definition at line 117 of file HsSoundLibCommon.h.

#define hsSndErr_PortCannotBoost (HS_SND_ERR(6))

Unable to change boost state on a port that does not have boost capabilities.

Definition at line 109 of file HsSoundLibCommon.h.

#define hsSndErr_PortCannotMute (HS_SND_ERR(4))

Unable to change mute state on a port that does not have mute capabilities.

Definition at line 107 of file HsSoundLibCommon.h.

#define hsSndErr_PortCannotPan (HS_SND_ERR(7))

Unable to change pan settings on a port that does not have panning capabilities.

Definition at line 110 of file HsSoundLibCommon.h.

#define hsSndErr_PortCannotVolume (HS_SND_ERR(5))

Unable to change volume gains on a port that does not have volume capabilities.

Definition at line 108 of file HsSoundLibCommon.h.

#define hsSndErr_PortIDNotInClass (HS_SND_ERR(11))

The portID/portClass combination is not supported.

Definition at line 114 of file HsSoundLibCommon.h.

#define hsSndErr_PortMuteLocked (HS_SND_ERR(12))

Unable to change mute state when hsSndParamMode_Normal is the default.

Definition at line 115 of file HsSoundLibCommon.h.

#define hsSndErr_PortPanLocked (HS_SND_ERR(15))

Unable to change pan value when hsSndParamMode_Normal is the default.

Definition at line 118 of file HsSoundLibCommon.h.

#define hsSndErr_PortVolumeLocked (HS_SND_ERR(13))

Unable to change volume parameter when hsSndParamMode_Normal is the default.

Definition at line 116 of file HsSoundLibCommon.h.

#define hsSndErr_UnknownClkRef (HS_SND_ERR(17))

Unknown clock reference passed to synchronization clock utility

Definition at line 120 of file HsSoundLibCommon.h.

#define hsSndErr_UnknownPortClass (HS_SND_ERR(10))

An unknown HsSndPortClass value was passed to a function call.

Definition at line 113 of file HsSoundLibCommon.h.

#define hsSndErr_UnknownSndParam (HS_SND_ERR(9))

An unknown HsSndParam selector was passed to a function call.

Definition at line 112 of file HsSoundLibCommon.h.

#define hsSndErrBase hsSoundLibErrorClass

Definition at line 102 of file HsSoundLibCommon.h.

#define hsSndLibVersion 0x010D0000

Version of the sound library.

Definition at line 59 of file HsSoundLibCommon.h.

#define hsSndMidiMsg_SetVolume 1

Definition at line 585 of file HsSoundLibCommon.h.

#define hsSndMidiProgressMsg_Signature 'MidP'

Definition at line 589 of file HsSoundLibCommon.h.

#define hsSndMode_Carkit ((HsSndMode) 0x0007)

Mode when wired carkit is attached and active to the device.

Definition at line 166 of file HsSoundLibCommon.h.

#define hsSndMode_Current ((HsSndMode) 0x0000)

Pass to spefify the currently active sound mode.

Definition at line 159 of file HsSoundLibCommon.h.

#define hsSndMode_Headphones ((HsSndMode) 0x0005)

Mode when any audio goes to stereo headphones.

Definition at line 164 of file HsSoundLibCommon.h.

#define hsSndMode_HeadphonesHost ((HsSndMode) 0x0006)

Mode when radio is off and headphones used exclusively by system and third party audio.

Definition at line 165 of file HsSoundLibCommon.h.

#define hsSndMode_Headset ((HsSndMode) 0x0004)

Mode when any audio goes to a mono headphones.

Definition at line 163 of file HsSoundLibCommon.h.

#define hsSndMode_Receiver ((HsSndMode) 0x0001)

Mode when Radio audio goes to receiver speaker.

Definition at line 160 of file HsSoundLibCommon.h.

#define hsSndMode_Reserved ((HsSndMode) 0x0008)

Reserved for future definition. Do not use.

Definition at line 167 of file HsSoundLibCommon.h.

#define hsSndMode_SpeakerHost ((HsSndMode) 0x0003)

Mode when radio is off and speaker used exclusively by system and third party audio.

Definition at line 162 of file HsSoundLibCommon.h.

#define hsSndMode_Speakerphone ((HsSndMode) 0x0002)

Mode when Radio audio goes to loud speaker (speaker phone)

Definition at line 161 of file HsSoundLibCommon.h.

#define hsSndMute_Disable 0

Disables mute on a port.

Definition at line 340 of file HsSoundLibCommon.h.

#define hsSndMute_Enable 1

Activates mute on a port.

Definition at line 339 of file HsSoundLibCommon.h.

#define hsSndNotify hsFileSoundLib

HsSoundLib broadcaster's ID

Definition at line 71 of file HsSoundLibCommon.h.

#define hsSndNotifyAlert 'hAlr'

An alert sound is about to start playing.

Definition at line 83 of file HsSoundLibCommon.h.

#define hsSndNotifyAnswerButton 'hAns'

While a headset or hybrid was connected, the answer-button event was detected.

Definition at line 77 of file HsSoundLibCommon.h.

#define hsSndNotifyAnswerHold 'hHol'

After hsSndNotifyAnswerButton notification, this event is sent if answer-button is still held down for some time.

Definition at line 78 of file HsSoundLibCommon.h.

#define hsSndNotifyAnswerRelease 'hRel'

After hsSndNotifyAnswerButton notification, this event is sent when answer-button released.

Definition at line 79 of file HsSoundLibCommon.h.

#define hsSndNotifyAthenaAudio 'hAta'

Automatic audio switches will route to Athena connector from now on (Treo-650 and later).

Definition at line 86 of file HsSoundLibCommon.h.

#define hsSndNotifyCarkitActive 'hCar'

Wired carkit has been activated, audio goes to carkit path.

Definition at line 84 of file HsSoundLibCommon.h.

#define hsSndNotifyCarkitInactive 'hCOf'

Wired carkit is no longer active, audio routes normally.

Definition at line 85 of file HsSoundLibCommon.h.

#define hsSndNotifyHeadphones 'hPho'

Headset jack connected and configured for stereo headphones.

Definition at line 74 of file HsSoundLibCommon.h.

#define hsSndNotifyHeadset 'hSet'

Headset jack connected and configured for mono headset with microphone.

Definition at line 73 of file HsSoundLibCommon.h.

#define hsSndNotifyHighPriority 'hHPr'

A high priority sound is about to start playing.

Definition at line 82 of file HsSoundLibCommon.h.

#define hsSndNotifyHybrid 'hHyb'

A hybrid headset/headphone is currently attached to the headset jack.

Definition at line 75 of file HsSoundLibCommon.h.

#define hsSndNotifyNotHybrid 'hNoH'

Currently attached peripheral on headset jack is Not a hybrid headset (see hsSndNotifyHybrid).

Definition at line 76 of file HsSoundLibCommon.h.

#define hsSndNotifyRingerSwitchOff 'hROf'

Notifies that ringer switch is in the silent (no sounds to back speaker) position.

Definition at line 81 of file HsSoundLibCommon.h.

#define hsSndNotifyRingerSwitchOn 'hROn'

Notifies that ringer switch is in the on (play sounds to back speaker) position.

Definition at line 80 of file HsSoundLibCommon.h.

#define hsSndNotifyUnplugged 'hOff'

No accesory is currently attached to the headset jack.

Definition at line 72 of file HsSoundLibCommon.h.

#define hsSndPan_Left ((Int16) 0x8000)

Pan all the way to the left. Cannot use with hsSndParamMode (defaults to Normal mode).

Definition at line 361 of file HsSoundLibCommon.h.

#define hsSndPan_LeftNormal ((Int16) 0x0800)

Pan all the way to the left. Can use with any hsSndParamMode.

Definition at line 363 of file HsSoundLibCommon.h.

#define hsSndPan_Middle ((Int16) 0x0000)

Pan at midpoint between left and right.

Definition at line 359 of file HsSoundLibCommon.h.

#define hsSndPan_Right ((Int16) 0x7FFF)

Pan all the way to the right. Cannot use with hsSndParamMode (defaults to Normal mode).

Definition at line 360 of file HsSoundLibCommon.h.

#define hsSndPan_RightNormal ((Int16) 0x07FF)

Pan all the way to the right. Can use with any hsSndParamMode.

Definition at line 362 of file HsSoundLibCommon.h.

#define hsSndParam_Boost ((UInt16) 3)

Changes the boost state of a port.

Definition at line 317 of file HsSoundLibCommon.h.

#define hsSndParam_Mute ((UInt16) 2)

Change the mute state of a port.

Definition at line 316 of file HsSoundLibCommon.h.

#define hsSndParam_Pan ((UInt16) 4)

Change the panning value of a port.

Definition at line 318 of file HsSoundLibCommon.h.

#define hsSndParam_Volume ((UInt16) 1)

Changes the volume of a port

Definition at line 315 of file HsSoundLibCommon.h.

#define hsSndParamMode_LockParam 0x4000

Limits parameter so it can only be changed with hsSndParamMode_LockParam or hsSndParamMode_UnlockParam.

Definition at line 329 of file HsSoundLibCommon.h.

#define hsSndParamMode_Mask 0x7000

The 3 upper bits after the sign bit in parameter values are reserved for the parameter mode.

Definition at line 327 of file HsSoundLibCommon.h.

#define hsSndParamMode_Normal 0x0000

Default parameter mode allowing parameter to be changed with any other hsSndParamMode.

Definition at line 328 of file HsSoundLibCommon.h.

#define hsSndParamMode_UnlockParam 0x2000

Removes hsSndParamMode_LockParam so it can be changed with any other hsSndParamMode.

Definition at line 330 of file HsSoundLibCommon.h.

#define HsSndParamValue_RemoveMode | ( | v |  | ) | (((v) & 0x8000)? (v) | hsSndParamMode_Mask : (v) & ~hsSndParamMode_Mask)

Removes LockParam or UnLockParam from parameter value.

Definition at line 223 of file HsSoundLibCommon.h.

#define HsSndParamValue_SetWithLock | ( | v |  | ) | (((v) & ~hsSndParamMode_Mask) | hsSndParamMode_LockParam)

Adds LockParam to parameter value.

Definition at line 221 of file HsSoundLibCommon.h.

#define HsSndParamValue_SetWithUnlock | ( | v |  | ) | (((v) & ~hsSndParamMode_Mask) | hsSndParamMode_UnlockParam)

Adds UnLockParam to parameter value.

Definition at line 222 of file HsSoundLibCommon.h.

#define hsSndPortClass_Anchor ((UInt16) 3)

Use to obtain the fixed port in a switch that doesn't change--the port that is patched to other ports. Valid only with HsSndSwitchGetPort.

Definition at line 306 of file HsSoundLibCommon.h.

#define hsSndPortClass_BaseDefault ((UInt16) 2)

Default port to use when restoring a Built-In port (For example, user unplugged headset while "auto" port was enabled.)

Definition at line 305 of file HsSoundLibCommon.h.

#define hsSndPortClass_Real ((UInt16) 1)

Current physical port. Use to change port parameters. Applies only to actual ports, not "auto" ports.

Definition at line 304 of file HsSoundLibCommon.h.

#define hsSndPortClass_Virtual ((UInt16) 0)

Symbolic port definition that applies to any port. Use for portID save and restore operations.

Definition at line 303 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Boost_Locked 0x00002000

If locked, can only be changed with lock/unlock boost parameter changes/

Definition at line 422 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Boost_LockMask 0x00002000

No definition.

Definition at line 424 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Boost_Unlocked 0x00000000

Boost can be changed with any type of boost parameters.

Definition at line 423 of file HsSoundLibCommon.h.

#define hsSndPortFlags_BoostMask 0x00000008

No definition.

Definition at line 386 of file HsSoundLibCommon.h.

#define hsSndPortFlags_BoostOff 0x00000000

Boost control on port is inactive.

Definition at line 385 of file HsSoundLibCommon.h.

#define hsSndPortFlags_BoostOn 0x00000008

Boost control on port is active.

Definition at line 384 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanBoost_No 0x00000000

Port has no boost control.

Definition at line 407 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanBoost_Yes 0x00000200

Port has boost control available.

Definition at line 406 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanBoostMask 0x00000200

No definition.

Definition at line 408 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanInputOnly 0x00000000

Port is for sound input exclusively.

Definition at line 388 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanIOBothways 0x00000030

Port can be for sound input and output simultaneously.

Definition at line 391 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanIOMask 0x00000030

No definition.

Definition at line 392 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanIOSelect 0x00000020

Port can switch between being for sound input or output.

Definition at line 390 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanMute_No 0x00000000

Port has no mute control.

Definition at line 403 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanMute_Yes 0x00000100

Port has mute control available.

Definition at line 402 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanMuteMask 0x00000100

No definition.

Definition at line 404 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanOutputOnly 0x00000010

Port is for sound output exclusively.

Definition at line 389 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanPan_No 0x00000000

Port has No pan control.

Definition at line 411 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanPan_Yes 0x00000400

Port has pan control available.

Definition at line 410 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanPanMask 0x00000400

No definition.

Definition at line 412 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanVol_No 0x00000000

Port has No volume control.

Definition at line 415 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanVol_Yes 0x00000800

Port has volume control available.

Definition at line 414 of file HsSoundLibCommon.h.

#define hsSndPortFlags_CanVolMask 0x00000800

No definition.

Definition at line 416 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Disabled 0x00000000

Port is disabled.

Definition at line 373 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Enabled 0x00000001

Port is enabled and in use.

Definition at line 372 of file HsSoundLibCommon.h.

#define hsSndPortFlags_EnableMask 0x00000001

No definition.

Definition at line 374 of file HsSoundLibCommon.h.

#define hsSndPortFlags_InputMask 0x00000040

No definition.

Definition at line 396 of file HsSoundLibCommon.h.

#define hsSndPortFlags_InputOff 0x00000000

Port as sound input is disabled.

Definition at line 395 of file HsSoundLibCommon.h.

#define hsSndPortFlags_InputOn 0x00000040

Port as sound input is enabled.

Definition at line 394 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Mute_Locked 0x00001000

If locked, can only be changed with lock/unlock mute parameter changes.

Definition at line 418 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Mute_LockMask 0x00001000

No definition.

Definition at line 420 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Mute_Unlocked 0x00000000

Mute can be changed with any type of mute parameters.

Definition at line 419 of file HsSoundLibCommon.h.

#define hsSndPortFlags_MuteMask 0x00000002

No definition.

Definition at line 378 of file HsSoundLibCommon.h.

#define hsSndPortFlags_MuteOff 0x00000000

Volume is as specified. (Not muted).

Definition at line 377 of file HsSoundLibCommon.h.

#define hsSndPortFlags_MuteOn 0x00000002

Volume is muted.

Definition at line 376 of file HsSoundLibCommon.h.

#define hsSndPortFlags_OutputMask 0x00000080

No definition.

Definition at line 400 of file HsSoundLibCommon.h.

#define hsSndPortFlags_OutputOff 0x00000000

Port as sound output is disabled.

Definition at line 399 of file HsSoundLibCommon.h.

#define hsSndPortFlags_OutputOn 0x00000080

Port as sound output is enabled.

Definition at line 398 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Pan_Locked 0x00004000

If locked, can only be changed with lock/unlock pan parameter changes.

Definition at line 426 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Pan_LockMask 0x00004000

No definition.

Definition at line 428 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Pan_Unlocked 0x00000000

Pan can be changed with any type of pan parameters.

Definition at line 427 of file HsSoundLibCommon.h.

#define hsSndPortFlags_TypeAnalog 0x00000000

Sound data through port is analog.

Definition at line 381 of file HsSoundLibCommon.h.

#define hsSndPortFlags_TypeDigital 0x00000004

Sound data through port is digital.

Definition at line 380 of file HsSoundLibCommon.h.

#define hsSndPortFlags_TypeMask 0x00000004

No definition.

Definition at line 382 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Vol_Locked 0x00008000

If locked, can only be changed with lock/unlock volume parameter changes.

Definition at line 430 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Vol_LockMask 0x00008000

No definition.

Definition at line 432 of file HsSoundLibCommon.h.

#define hsSndPortFlags_Vol_Unlocked 0x00000000

Volume can be changed with any type of volume parameters.

Definition at line 431 of file HsSoundLibCommon.h.

#define hsSndPortID_ConnectCall HS_RDIO(0x00000020)

Virtual port to indicate a radio call is now connected.

Definition at line 294 of file HsSoundLibCommon.h.

#define hsSndPortID_Current HS_AC97(0x00000000)

Special meta port ID used to specify currently active user port.

Definition at line 246 of file HsSoundLibCommon.h.

#define hsSndPortID_InBaseMic HS_AC97(0x00000007)

Microphone at the base of the smartphone body.

Definition at line 253 of file HsSoundLibCommon.h.

#define hsSndPortID_InBtHandsfree HS_AC97(0x00000016)

Input port used by OutRadioMic switch to get uplink audio from BT handsfree mode.

Definition at line 268 of file HsSoundLibCommon.h.

#define hsSndPortID_InBtHeadset HS_AC97(0x00000015)

Input port used by OutRadioMic switch to get uplink audio from BT headset.

Definition at line 267 of file HsSoundLibCommon.h.

#define hsSndPortID_InCarkit HS_AC97(0x00000013)

Input port used when wired carkit is activated.

Definition at line 265 of file HsSoundLibCommon.h.

#define hsSndPortID_InHeadsetMic HS_AC97(0x00000008)

Microphone on a mono headset. Ccomes from left channel as input.

Definition at line 254 of file HsSoundLibCommon.h.

#define hsSndPortID_InHostBaseMic HS_AC97(0x00000010)

Input port that controls source base port for host recording.

Definition at line 262 of file HsSoundLibCommon.h.

#define hsSndPortID_InHostHeadsetMic HS_AC97(0x00000011)

Input port controlling source headset port for host recording.

Definition at line 263 of file HsSoundLibCommon.h.

#define hsSndPortID_InHostPhone HS_AC97(0x00000012)

Input port used by host if phone or TTY is active.

Definition at line 264 of file HsSoundLibCommon.h.

#define hsSndPortID_InHostPlay HS_AC97(0x0000000D)

Input from the Host converted to analog for output to speakers.

Definition at line 259 of file HsSoundLibCommon.h.

#define hsSndPortID_InLineRec HS_AC97(0x00000006)

Configures headset jack as input, precluding headset use (special port for test purposes).

Definition at line 252 of file HsSoundLibCommon.h.

#define hsSndPortID_InMicAuto HS_AC97(0x00000009)

Atomatic port, according to headset insertion. Use with hsSndSwitchID_OutRadioMic.

Definition at line 255 of file HsSoundLibCommon.h.

#define hsSndPortID_InRadioSpkr HS_AC97(0x0000000B)

Input from the Radio speaker output.

Definition at line 257 of file HsSoundLibCommon.h.

#define hsSndPortID_LastPort HS_AC97(0x00000016)

Update at end. Same ID as last defined port in sequence.

Definition at line 269 of file HsSoundLibCommon.h.

#define hsSndPortID_Off 0x00000000

Special meta port ID used to turn off a sound switch.

Definition at line 245 of file HsSoundLibCommon.h.

#define hsSndPortID_OutBtHandsfree HS_AC97(0x0000000F)

Output port used by InRadioSpkr switch to put Call in bluetooth handsfree mode.

Definition at line 261 of file HsSoundLibCommon.h.

#define hsSndPortID_OutBtHeadset HS_AC97(0x0000000E)

Output port used by InRadioSpkr switch to put Call in bluetooth headset mode.

Definition at line 260 of file HsSoundLibCommon.h.

#define hsSndPortID_OutCarkit HS_AC97(0x00000014)

Output port used when wired carkit is activated.

Definition at line 266 of file HsSoundLibCommon.h.

#define hsSndPortID_OutHeadphones HS_AC97(0x00000004)

Configures the headset port for full left and right stereo output, no inputs.

Definition at line 250 of file HsSoundLibCommon.h.

#define hsSndPortID_OutHeadset HS_AC97(0x00000003)

Audio output to mono headset (right channel output). Left can be used as input.

Definition at line 249 of file HsSoundLibCommon.h.

#define hsSndPortID_OutHostRec HS_AC97(0x0000000C)

Output to the Host digitized recording input.

Definition at line 258 of file HsSoundLibCommon.h.

#define hsSndPortID_OutRadioMic HS_AC97(0x0000000A)

Output connected to the Radio microphone input.

Definition at line 256 of file HsSoundLibCommon.h.

#define hsSndPortID_OutReceiver HS_AC97(0x00000001)

Receiver speaker.

Definition at line 247 of file HsSoundLibCommon.h.

#define hsSndPortID_OutSpeaker HS_AC97(0x00000002)

Back speaker for system audio and speakerphone functions,

Definition at line 248 of file HsSoundLibCommon.h.

#define hsSndPortID_OutSpeakerAuto HS_AC97(0x00000005)

Automatic port, according to headset insertion. Use with hsSndSwitchID_InRadioSpkr.

Definition at line 251 of file HsSoundLibCommon.h.

#define hsSndPortInfo_Signature 'SPRT'

Definition at line 604 of file HsSoundLibCommon.h.

#define hsSndRsrcAudioTableID 25000

Default audio table ID which can be loaded automatically during reset.

Definition at line 95 of file HsSoundLibCommon.h.

#define hsSndRsrcAudioTableType 'hTbl'

Resource contains audio table that can be loaded to audio driver.

Definition at line 94 of file HsSoundLibCommon.h.

#define hsSndSwitchID_InHostPlay HS_AC97(0x00040000)

Controls which speaker to direct PalmOS audio to.

Definition at line 235 of file HsSoundLibCommon.h.

#define hsSndSwitchID_InMic HS_AC97(0x00030000)

Test control for Mfg to directly connect Mic input into any destination speaker.

Definition at line 234 of file HsSoundLibCommon.h.

#define hsSndSwitchID_InRadioSpkr HS_AC97(0x00010000)

Controls the destination port for data coming from the Radio.

Definition at line 232 of file HsSoundLibCommon.h.

#define hsSndSwitchID_OutHostRec HS_AC97(0x00050000)

Controls from which port to digitize and send to PalmOS for recording.

Definition at line 236 of file HsSoundLibCommon.h.

#define hsSndSwitchID_OutRadioMic HS_AC97(0x00020000)

Controls the source microphone to connect to the Radio.

Definition at line 233 of file HsSoundLibCommon.h.

#define hsSndSwitchID_RadioCall HS_RDIO(0x00010000)

Keeps track of the audio connection of a Radio call.

Definition at line 285 of file HsSoundLibCommon.h.

#define hsSndToneType_Square 0

Used when calling HsSndTonePlay.

Definition at line 178 of file HsSoundLibCommon.h.

#define hsSoundLibCreatorID hsFileSoundLib

Creator ID of the sound library.

Definition at line 60 of file HsSoundLibCommon.h.

#define hsSoundLibName "HsSoundLib"

Name of the sound library.

Definition at line 62 of file HsSoundLibCommon.h.

#define hsSoundLibTypeID sysFileTLibrary

Type of the sound library.

Definition at line 61 of file HsSoundLibCommon.h.

#define PM_AUDP | ( | n |  | ) | ((n) | pmSndBayID_AUDP)

utility to associate the Preference Bay ID with other element ID

Definition at line 681 of file HsSoundLibCommon.h.

#define PM_AUDP_CLASS | ( | n |  | ) | ((n) | PM_AUDP_CLASS_MASK)

utility to associate preferences class marker to prefIDs

Definition at line 652 of file HsSoundLibCommon.h.

#define PM_AUDP_CLASS_MASK 0x4000

The ringtone attack envelope ramp-up to low volume initially, and to full volume after about 4 seconds

Definition at line 650 of file HsSoundLibCommon.h.

#define pmAudioClkTickRef ((PmClkTickRef) 0x00000001)

use as PmClkTickRef when requiring audio tick clock

Definition at line 692 of file HsSoundLibCommon.h.

#define pmSndAttackEnvIDRings (hsSndBufFlags_attackEnvRings)

The ringtone attack envelope ramp-up to low volume initially, and to full volume after about 4 seconds

Definition at line 639 of file HsSoundLibCommon.h.

#define pmSndAttackEnvIDRings2 (hsSndBufFlags_attackEnvRings2)

The ringtone attack envelope ramp-up in about 1 second

Definition at line 641 of file HsSoundLibCommon.h.

#define pmSndAttackEnvIDVibeRing (hsSndBufFlags_attackEnvVibeRings)

Vibrate for 4 seconds, then behave as pmSndAttackEnvIDRings

Definition at line 640 of file HsSoundLibCommon.h.

#define pmSndAttackEnvIDVibeRing2 (hsSndBufFlags_attackEnvVibeRings2)

Vibrate for 4 seconds, then behave as pmSndAttackEnvIDRings2

Definition at line 642 of file HsSoundLibCommon.h.

#define pmSndBayID_AUDP 0x0F000000

we are reserving SndBayID 15 for audio preference purposes

Definition at line 648 of file HsSoundLibCommon.h.

#define pmSndPref_AthenaActive_No (0)

disable routing to Athena path for automatic switches

Definition at line 672 of file HsSoundLibCommon.h.

#define pmSndPref_AthenaActive_Yes (1)

enable routing to Athena path for automatic switches

Definition at line 673 of file HsSoundLibCommon.h.

#define pmSndPref_AthenaAudio_IfMicPresent (16)

when Athena audio class detected, only route if Mic is also present

Definition at line 677 of file HsSoundLibCommon.h.

#define pmSndPref_AthenaAudio_NoRouting (0)

no athena audio routing when Athena audio connection detected. Handled elsewhere or through pmSndPrefID_AthenaActive

Definition at line 676 of file HsSoundLibCommon.h.

#define pmSndPref_AthenaAudio_Unconditional (32)

cause unconditional audio routing if Athena audio class detected

Definition at line 678 of file HsSoundLibCommon.h.

#define pmSndPref_WakeOnAnswerBtn_Disable (0)

disable wake up on answer button feature

Definition at line 668 of file HsSoundLibCommon.h.

#define pmSndPref_WakeOnAnswerBtn_Enable (1)

enable wake up on answer button feature

Definition at line 669 of file HsSoundLibCommon.h.

#define pmSndPrefID_AGCEvent PM_AUDP_CLASS(0x0009)

set to temporarily activate AGC if required (only useful when AGC has been disabled before hand)

Definition at line 662 of file HsSoundLibCommon.h.

#define pmSndPrefID_AppsGroupHoldType PM_AUDP_CLASS(0x0001)

specify how to hold application audio (mute/pause)

Definition at line 654 of file HsSoundLibCommon.h.

#define pmSndPrefID_AthenaActive PM_AUDP_CLASS(0x0007)

set to activate audio paths to multi-connector, clear to return to normal (used for wired carkit mode)

Definition at line 660 of file HsSoundLibCommon.h.

#define pmSndPrefID_AthenaAudio PM_AUDP_CLASS(0x000A)

set to activate or deactivate automatic routing of audio to Athena connector

Definition at line 663 of file HsSoundLibCommon.h.

#define pmSndPrefID_AudioTable PM_AUDP_CLASS(0x0005)

pass pointer to PmSndGain8Table to load for use, pass zero to return to default

Definition at line 658 of file HsSoundLibCommon.h.

#define pmSndPrefID_GsmMccArray PM_AUDP_CLASS(0x0006)

pass pointer to PmSndGsmMccArray to load for use, pass zero to return to default

Definition at line 659 of file HsSoundLibCommon.h.

#define pmSndPrefID_JackOutIfMicUnused PM_AUDP_CLASS(0x0002)

shall we force jack out to stereo if Mic not in use?

Definition at line 655 of file HsSoundLibCommon.h.

#define pmSndPrefID_PhoneRxGainLimit PM_AUDP_CLASS(0x0003)

set if gain-limit phone Rx to receiver speaker

Definition at line 656 of file HsSoundLibCommon.h.

#define pmSndPrefID_SleepMode PM_AUDP_CLASS(0x0008)

set to zero for normal sleep, other values for partial audio sleep modes (for internal use only)

Definition at line 661 of file HsSoundLibCommon.h.

#define pmSndPrefID_WakeOnAnswerBtn PM_AUDP_CLASS(0x0004)

set to be able to wake device when headset answer button is pressed

Definition at line 657 of file HsSoundLibCommon.h.

#define pmSndSwitchID_Preferences PM_AUDP(0x00400000)

used with the HsSoundLib Switch calls to set and get sound preference data

Definition at line 684 of file HsSoundLibCommon.h.

## Typedef Documentation

typedef Err(*) HsSndBufferProc(void *userdata, UInt32 flags, void *buffer, UInt32 bytesUsed, UInt32 time)

Callback function used under various conditions with sound.

Parameters:

  | userdata | IN Userdata passed when setting the callback routine
  | flags | IN Copy of the HsSndBufferData flags field
  | buffer | IN Pointer originally passed in HsSndBufferData
  | bytesUsed | OUT How many bytes have been consumed from the buffer
  | time | OUT Number of milliseconds available for callback processing

Returns:
  Error code.

Definition at line 539 of file HsSoundLibCommon.h.

typedef UInt16 HsSndCmdType

Holds sound command type

Definition at line 195 of file HsSoundLibCommon.h.

typedef UInt16 HsSndFormatType

Holds sound format type

Definition at line 210 of file HsSoundLibCommon.h.

typedef Int16 HsSndMode

Holds audio mode type

Definition at line 171 of file HsSoundLibCommon.h.

typedef UInt16 HsSndParam

Used as a parameter to HsSndPortSetParam function.

Definition at line 204 of file HsSoundLibCommon.h.

typedef UInt16 HsSndPortClass

Used as a parameter to HsSndSwitchGetParam function.

Definition at line 207 of file HsSoundLibCommon.h.

typedef UInt32 HsSndPortID

Holds sound port ID information.

Definition at line 198 of file HsSoundLibCommon.h.

typedef struct HsSndPortInfo * HsSndPortInfoPtr

typedef UInt32 HsSndSwitchID

Holds sound switch ID information.

Definition at line 201 of file HsSoundLibCommon.h.

typedef UInt8 hsSndSysBeepType

Holds beep tone type.

See also:
  hsSndSysBeepTag

Definition at line 151 of file HsSoundLibCommon.h.

typedef UInt32 PmClkTickRef

The ringtone attack envelope ramp-up to low volume initially, and to full volume after about 4 seconds

Definition at line 690 of file HsSoundLibCommon.h.

typedef UInt16 PmSndPrefID

The ringtone attack envelope ramp-up to low volume initially, and to full volume after about 4 seconds

Definition at line 665 of file HsSoundLibCommon.h.

typedef unsigned long long PmSndU64

Definition at line 47 of file HsSoundLibCommon.h.

## Enumeration Type Documentation

enum HsSndCmdEnumTag

Sound command values

The HsSndCmdType is used as the first parameter to the function HsSndFormatPlay. Use these command values.

Enumerator:

  hsSndCmdPlay | Use to initiate a playback session.
  hsSndCmdStop | Use to terminate the current playback session.

Definition at line 187 of file HsSoundLibCommon.h.

    00188 {
    00189     hsSndCmdPlay = 1,   /**<Use to initiate a playback session. */
    00190     hsSndCmdStop        /**<Use to terminate the current playback session. */
    00191
    00192 };

enum HsSndFormatEnumTag

Sound formats

Enumerator:

  hsSndFormatMidi | Midi format.
  hsSndFormatAmr | Obsolete. Use Codec Plug-in Manager or streaming component.
  pmSndFormatSetAttackEnvID | For internal use only (escape code used by PmSndStreamSetAttackEnvID macro function).
  pmSndFormatPauseStream | For internal use only (escape code used by PmSndStreamPause macro function).
  pmSndFormatResumeStream | For internal use only (escape code used by PmSndStreamResume macro function).
  pmSndFormatSetStoppable | For internal use only (escape code used by PmSndStreamStoppable macro function).

Definition at line 471 of file HsSoundLibCommon.h.

    00472 {
    00473     hsSndFormatMidi = 2, /**<Midi format. */
    00474     hsSndFormatAmr, /**<Obsolete.  Use Codec Plug-in Manager or streaming component. */
    00475     pmSndFormatSetAttackEnvID, /**<For internal use only (escape code used by PmSndStreamSetAttackEnvID macro function). */
    00476     pmSndFormatPauseStream, /**<For internal use only (escape code used by PmSndStreamPause macro function). */
    00477     pmSndFormatResumeStream, /**<For internal use only (escape code used by PmSndStreamResume macro function). */
    00478     pmSndFormatSetStoppable /**<For internal use only (escape code used by PmSndStreamStoppable macro function). */
    00479 };

enum hsSndSysBeepTag

Beeps

Provides additional system sounds for PalmOS SndPlaySystemSound.

Enumerator:

  hsSndCardInsert | No definition.
  hsSndCardRemove | No definition.
  hsSndSyncStart | No definition.
  hsSndSyncStop | No definition.
  hsSndChargerAttach | No definition.
  hsSndChargerDetach | No definition.
  hsSndRadioOn | No definition.
  hsSndRadioOff | No definition.
  hsSndBatFull | No definition.
  hsSndBatLow | No definition.
  hsSndBatShutdown | No definition.
  hsSndDeepWake | No definition.
  hsSndDeepSleep | No definition.
  hsSndRadioInServiceArea | No definition.
  hsSndRadioOutServiceArea | No definition.

Definition at line 130 of file HsSoundLibCommon.h.

    00131 {
    00132     hsSndCardInsert = 64, /**<No definition. */
    00133     hsSndCardRemove, /**<No definition. */
    00134     hsSndSyncStart, /**<No definition. */
    00135     hsSndSyncStop, /**<No definition. */
    00136     hsSndChargerAttach, /**<No definition. */
    00137     hsSndChargerDetach, /**<No definition. */
    00138     hsSndRadioOn, /**<No definition. */
    00139     hsSndRadioOff, /**<No definition. */
    00140     hsSndBatFull, /**<No definition. */
    00141     hsSndBatLow, /**<No definition. */
    00142     hsSndBatShutdown, /**<No definition. */
    00143     hsSndDeepWake, /**<No definition. */
    00144     hsSndDeepSleep, /**<No definition. */
    00145     hsSndRadioInServiceArea, /**<No definition. */
    00146     hsSndRadioOutServiceArea /**<No definition. */
    00147
    00148 };

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