Adding Support for Phone Message Recording and Playback
Adding support for phone message recording and playback requires the definition of the AT commands that control these functions. The following table describes the voice modem INF file entries that define the AT commands for phone message recording and playback.
INF File Entry | Command Description |
---|---|
Stops playing audio data immediately (does not play the rest of the audio buffer contents). This command is needed for modems that are using a serial wave device. |
|
Resets the modem to Class 0. |
|
Sets the modem's handset playback format. |
|
Sets the modem's handset recording format. |
|
Sets the modem's line playback format. |
|
Sets the modem's line recording format. |
|
Puts modem in a mode that enables audio to be played back through the handset when there is no active call. |
|
Starts playing audio (.wav files) through the modem. If a serial wave driver is being used, a bit in the VoiceProfile entry determines if the baud rate is set prior to, or after, the StartPlay command is issued. |
|
Starts recording audio (.wav files) from the modem. If a serial wave driver is being used, a bit in the VoiceProfile file determines if the baud rate is set prior to, or after, the StartRecord command is issued. |
|
Resets the modem's baud rate after an AbortPlay or TerminatePlay command is issued. A bit in the VoiceProfile entry indicates whether Unimodem has to reset the UART's baud rate. |
|
Stops recording audio (.wav files) from the modem. If a serial wave driver is being used, a bit in the VoiceProfile entry determines whether the baud rate is set before or after the StopRecord command is issued. |
|
Directs the modem to finish recording its local buffer and stop recording audio data. This command is needed for modems with a serial wave device. |
|
Directs the modem to finish playing the contents of its local buffer and stop playing audio data after that. This command is needed for modems that have a serial wave device. |
The following example demonstrates these entries:
HKR, CloseHandset, 1,, "at#cls=0<cr>"
HKR, StartPlay, 1,, "at#vtx<cr>"
HKR, StopPlay, 1,, "None"
HKR, StopPlay, 2,, "NoResponse"
HKR, StartRecord, 1,, "at#vrx<cr>"
HKR, StopRecord, 1,, "None"
HKR, StopRecord, 2,, "NoResponse"
HKR,, TerminateRecord,, "!"
HKR,, TerminatePlay,, "<h10><h03>at<cr>"
HKR,, AbortPlay,, "<h10><h18>at<cr>"
HKR, LineSetPlayFormat, 1,, "at#vls=0<cr>"
HKR, LineSetRecordFormat, 1,, "None"
HKR, LineSetRecordFormat, 2,, "NoResponse"
HKR, HandsetSetRecordFormat, 1,,"at#vsr=7200<cr>"
HKR, HandsetSetRecordFormat, 2,,"at#vbs=4<cr>"
HKR, HandsetSetPlayFormat, 1,,"at#vsr=7200<cr>"
HKR, HandsetSetPlayFormat, 2,,"at#vbs=4<cr>"
HKR, OpenHandset, 1,, "at#cls=8<cr>"
HKR, OpenHandset, 2,, "at#vls=2<cr>"
For more information about these voice modem INF entries, see Voice Modem INF File Entries.