This chapter lists and describes the function calls that go directly to the speech engine.
Purpose
SmAddCallback adds a single callback routine for the specified message.
Syntax
int SmAddCallback (char *reply_name, SmHandler *handler , caddr_t client_data);
Parameters
Return Values
SM_RC_EALLOC SM_RC_ENOMEM SM_RC_NOT_VALID_REQUEST SM_RC_OK SM_RC_SM_NOT_OPEN
Task Related Functions and Callbacks
SmDispatch SmRemoveCallback
Purpose
SmAddPronunciation adds a new pronunciation.
This function provides the method for associating a pronunciation with a spelling.
The following restrictions apply when calling SmAddPronunciation:
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmAddPronunciation (char *spelling, char *pronunciation, long uttno, short repetitions, long options, SM_MSG *reply );
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_ADDWORD_LIMIT_EXCEEDED SM_RC_BAD_ACOUSTICS SM_RC_BAD_ADDWORD SM_RC_ILLEGAL_SOUNDSLIKE SM_RC_ILLEGAL_SPELLING SM_RC_MISMATCHED_ACOUSTICS SM_RC_NOT_ADDED SM_RC_NOT_VALID_REQUEST SM_RC_NOT_YET SM_RC_SERVER_ERROR SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_READ_ERROR SM_RC_SERVER_FILE_WRITE_ERROR SM_RC_SERVER_MALLOC_ERROR
Reply Structure Functions by Message Type
SM_ADD_PRONUNCIATION_REPLY
Task Related Functions and Callbacks
SmQueryPronunciation SmQueryPronunciations SmRemovePronunciation SmNaddPronunciationCallback SmNqueryPronunciationCallback SmNqueryPronunciationsCallback SmNremovePronunciationCallback
Purpose
SmAddToVocab adds words to a vocabulary.
This function adds words to predefined vocabularies or to a vocabulary previously created by SmDefineVocab. SmAddToVocab can be used to dynamically change command vocabularies within an application. If any of the specified words do not have an existing pronunciation, the call returns the list of words without pronunciations. Missing pronunciations must be added by using the SmAddPronunciation function. Pronunciations exist for all words in the predefined vocabularies and for words added by the user. For a predefined vocabulary the words are added in the user's personal pronunciation area of the vocabulary.
This call is valid only when the speech engine is not decoding speech to text.
Syntax
int SmAddToVocab (char *vocab, short nvocwords, SM_VOCWORD *vocwords[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LEN
For synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_WRITE_ERROR
Reply Structure Functions by Message Type
SM_ADD_TO_VOCAB_REPLY
Task Related Functions and Callbacks
SmDefineVocab SmDisableVocab SmEnableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmApiVersionCheck verifies the current version of the SMAPI.
This function checks whether the version of the SMAPI used to compile the speech-aware application is compatible with the API currently installed on the system. The reply message contains the return code indicating the current status.
Syntax
int SmApiVersionCheck (char *caller_version, char **sm_version);
Parameters
Return Values
SM_RC_OK SM_RC_WRONG_SM_VERSION
Purpose
SmCancelPlayback cancels the request to play back a message, utterance, or words.
This function cancels a play request from the SmPlayMessage, SmPlayUtterance, and SmPlayWords functions.
Syntax
int SmCancelPlayback(SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_CANCEL_PLAYBACK_REPLY
Task Related Functions and Callbacks
SmPlayMessage SmPlayUtterance SmPlayWords SmNcancelPlaybackCallback SmNplayMessageCallback SmNplayMessageStatusCallback SmNplayUtteranceCallback SmNplayUtteranceStatusCallback SmNplayWordsCallback SmNplayWordsStatusCallback
Purpose
SmClose closes the SMAPI connection.
If the speech-aware application has not already called the SmDisconnect function to terminate the connection with the speech engine, the speech API does so before executing SmClose.
Syntax
int SmClose ();
Parameters None.
Return Values
SM_RC_OK SM_RC_SM_NOT_OPEN
Task Related Functions and Callbacks
SmDisconnect SmNdisconnectCallback
Purpose
SmConnect connects to the speech engine.
This function establishes a session with the speech engine. The desired type of session and other necessary information are provided by setting SMAPI attributes. Once a session is established the session type cannot be changed. To change the session type, call SmDisconnect then call SmConnect again.
Syntax
int SmConnect (int nargs, SmArg *Args, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_EUNEXP SM_RC_INCOMPATIBLE_ENROLLMENT SM_RC_NAVIGATOR_ALREADY_DEFINED SM_RC_SM_NOT_OPEN SM_RC_ALREADY_CONNECTED SM_RC_OK SM_RC_INVALID_PARM_MAX_LEN
For synchronous call and callbacks:
SM_RC_BAD_ADDWORD SM_RC_BAD_AP SM_RC_BAD_AUDIO SM_RC_BAD_DECO SM_RC_BAD_DESCRIPTION SM_RC_BAD_ENROLLID SM_RC_BAD_PASSWORD SM_RC_BAD_SCRIPT SM_RC_BAD_TASKID SM_RC_BAD_USERID SM_RC_ENROLLID_EXISTS SM_RC_ENROLLID_RUNNING SM_RC_ENROLLMENT_NOT_COMPLETE SM_RC_MISMATCHED_ALPHABET SM_RC_MISMATCHED_LANGUAGE SM_RC_MISMATCHED_SCRIPT SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_ERROR SM_RC_SEVER_FILE_OPEN_ERROR
Reply Structure Functions by Message Type
SM_CONNECT_REPLY
Task Related Functions and Callbacks
SmOpen SmSetArg SmNconnectCallback
Purpose
SmCorrectText updates the user's voice model with a sequence of text the user considers correct.
This function provides the speech engine with a sequence of correctly recognized text. This text can be used to adapt the user's voice model, thereby improving future recognition of dictated text.
Syntax
int SmCorrectText (short nwords, SM_WORD *words[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_WRITE_ERROR
Reply Structure Functions by Message Type
SM_CORRECT_TEXT_REPLY
Task Related Functions and Callbacks
SmCorrectTextCancel SmNewContext SmRemovePronunciation SmWordCorrection SmNcorrectTextCallback SmNcorrectTextCancelCallback SmNnewContextCallback SmNremovePronunciationCallback SmNwordCorrectionCallback
Purpose
SmCorrectTextCancel cancels the previous notification of a correct sequence of text.
This function undoes the previous call to SmCorrectText.
Syntax
int SmCorrectTextCancel (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_CORRECT_TEXT_CANCEL_REPLY
Task Related Functions and Callbacks
SmCorrectText SmNewContext SmRemovePronunciation SmWordCorrection SmNcorrectTextCallback SmNcorrectTextCancelCallback SmNnewContextCallback SmNremovePronunciationCallback SmNwordCorrectionCallback
Purpose
SmDefineGrammar defines a grammar-based vocabulary.
This function dynamically defines a new vocabulary that can be enabled through the SmEnableVocab function, along with dynamic command vocabularies defined through SmDefineVocab. The vocabulary content is specified by a precompiled .fsg file, produced by the grammar compiler. Like SmDefineVocab, SmDefineGrammar returns a list of grammar words that don't have pronunciations. Unlike SmDefineVocab, if any pronunciation is missing, SmDefineGrammar fails with a return code of SM_RC_NOT_INVOCAB, since recognition of a grammar network with missing pronunciations is not well defined. Use SmGetVocWords to retrieve the list of missing words.
If external lists are missing (for example, there was no SmDefineVocab before the SmDefineGrammar), SmDefineGrammar will also fail. This time, the return code is SM_RC_MISSING_EXTERN. The names of the external lists are returned as if they were words without pronunciations, and can also be obtained with SmGetVocWords.
Since missing externs is really a program logic error, these are checked and returned before determining if any words are missing pronunciations. So, if both externs and words are missing, you first get SM_RC_MISSING_EXTERN. When that is fixed, you get SM_RC_NOT_INVOCAB.
Note that pronunciations can be found in the user's personal pool, application-specific pools or the base domain pool.
Syntax
int SmDefineGrammar (char *vocab, char *grammar, long options, SM_MSG *reply);
Parameters
Note:
These runtime flags override settings compiled in the .FSG file.
Return Values
SM_RC_OK SM_RC_MISSING_EXTERN SM_RC_NOT_VALID_REQUEST SM_RC_NOT_INVOCAB SM_RC_BAD_VOCAB SM_RC_SERVER_FILE_MALLOC_ERROR SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_READ_ERROR
Reply Structure Functions by Message Type
SM_DEFINE_GRAMMAR_REPLY
Task Related Functions and Callbacks
SmEnableVocab SmGetAnnotations SmUndefineGrammar SmDisableVocab SmNdisableVocabCallback SmNdenableVocabCallback SmNundefineVocabCallback
Purpose
SmDefineVocab defines a new vocabulary.
This function dynamically creates a new vocabulary that can later be used by calling the SmEnableVocab function. The vocabulary created by SmDefineVocab consists only of the words specified in the call with all words receiving an equal voice model weighting. This function can be used to dynamically create command vocabularies in an application. If any of the specified words do not have an existing pronunciation, the call returns a list of words without pronunciations. Pronunciations can be found in the predefined vocabulary and in the user's personal vocabulary. Predefined vocabularies are not dynamic. Dynamic vocabularies are intended for command vocabulary recognition.
SmDefineVocab takes more time to execute than SmEnableVocab and SmDisableVocab; therefore, it is more efficient to define a vocabulary once and enable/disable frequently rather than to define multiple times.
This call is valid only when the speech engine is not decoding speech to text.
Syntax
int SmDefineVocab (char *vocab, short nvocwords, SM_VOCWORD *vocwords[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_WRITE_ERROR
Reply Structure Functions by Message Type
SM_DEFINE_VOCAB_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDisableVocab SmEnableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmDetachSessions requests that one or more sessions detach.
This function requests all applications connected to the speech engine to disconnect from it. SmQuerySessions can be used to monitor the number of attached applications. The disconnect request is in the form of the SM_REQUEST_DETACH reply message structure. The engine does not force a session to disconnect and does not wait for a reply to the disconnect request. This function can be used for switching users (or userid, enrollid, task).
Syntax
int SmDetachSessions (SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_DETACH_SESSIONS_REPLY
Task Related Functions and Callbacks
SmQuerySessions SmNdetachRequestedCallback SmNdetachSessionsCallback SmNquerySessionsCallback
Purpose
SmDisableVocab disables a defined vocabulary.
This function disables a vocabulary so it is no longer used by the speech engine to decode speech to text during a recognition session. Only the specified vocabulary is disabled. Any other enabled vocabularies remain active.
This function is valid only when the speech engine is not decoding speech to text.
Syntax
int SmDisableVocab (char *vocab, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_DISABLE_VOCAB_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmEnableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmDiscardData discards audio and error-correction data.
This function discards audio data and error-correction information for recognized words that are not referenced again, thus conserving speech engine disk space (refer to the SmNdiscardSessionData speech attribute used at SmDisconnect).
SmDiscardData works on the granularity of utterances (between SmMicOn and SmMicOff) and discards utterance files owned by the application. Ownership is established by the application that turned the microphone on to create the utterance. An application can guarantee ownership of its data by toggling the microphone Off and On when it receives focus.
Syntax
int SmDiscardData (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_DISCARD_DATA_REPLY
Task Related Functions and Callbacks
Purpose
SmDisconnect disconnects from the speech engine.
This function closes the communication connection with the speech engine.
Syntax
int SmDisconnect (int nargs, SmArg *Args, SM_MSG *reply);
Parameters
In recognition sessions: | |
SmNdiscardSessionAdaptation | Reset the user's voice model to the state it was in before the decoding session. |
SmNdiscardSessionData | Delete any data for this session. |
SmNsaveSessionData | Keep the session data until the user re-initializes. (Default) |
SmNsaveSessionAdaptation | Keep words added to the word-usage model during this session. (Default) |
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_BAD_ENROLLID SM_BAD_SCRIPT SM_RC_BAD_VALUE SM_RC_ENROLLID_EXISTS SM_RC_ENROLLID_RUNNING SM_RC_NO_SPACE_TERM_ENROLL SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_ERROR
Reply Structure Functions by Message Type
SM_DISCONNECT_REPLY
Task Related Functions and Callbacks
SmClose SmNdisconnectCallback
Purpose
SmDispatch receives one message and dispatches the callbacks.
This function provides the method through which callback functions are executed by OS/2 applications. More specifically, this function receives one message from the speech engine and dispatches the appropriate callback routines, which were previously registered using SmAddCallback, for the default connection.
Syntax
int SmDispatch (unsigned long ap_val);
Parameters
Return Values
SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_EINVAL SM_RC_EMSGSIZE SM_RC_ENOCONN SM_RC_ENOHANDLES SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_ETIMEOUT SM_RC_EUNEXP SM_RC_EUNKMSG SM_RC_NOT_OPEN SM_RC_OK
Task Related Functions and Callbacks
SmAddCallback SmRemoveCallback
Purpose
SmEnableVocab enables a defined vocabulary.
This function enables a vocabulary to be used by the speech engine to decode speech to text during a recognition session. Currently enabled vocabularies are not disabled by this function but remain enabled along with the newly enabled vocabulary. If currently enabled vocabularies are to be disabled first, then an SmDisableVocab call must be made beforehand for each vocabulary to be disabled.
This call is valid only when the speech engine is not decoding speech to text.
Syntax
int SmEnableVocab (char *vocab, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_ENABLE_VOCAB_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmEventNotify requests notification when the speech engine completes decoding all the audio dictated up to the time SmEventNotify was called.
This function causes the callback associated with the SmNaudioEventCallback attribute to be called as soon as decoding is completed for all the words dictated up to the time SmEventNotify was called.
If a callback is not used, the application is notified with the reply message structure SM_EVENT_SYNCH sent by the speech engine.
Syntax
int SmEventNotify (long event_id, long options, SM_MSG *reply);
Parameters
Notes:
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_EVENT_NOTIFY_REPLY
Task Related Functions and Callbacks
SmNeventNotifyCallback SmNeventSynchCallback
Purpose
SmHaltRecognizer temporarily halts recognition.
This function can be called when the speech engine is decoding speech to text. Halting recognition may be necessary, for example, to define and/or enable vocabularies to be used by the engine during recognition. Recognition can be restarted with SmRecognizeNextWord.
Syntax
int SmHaltRecognizer (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_ERROR
Reply Structure Functions by Message Type
SM_HALT_RECOGNIZER_REPLY
Task Related Functions and Callbacks
SmMicOff SmMicOn SmQuery SmRecognizeNextWord SmSet SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmMicOff turns off the microphone.
 Depending on the speed and what is said before the microphone is turned off, this process can take several seconds to complete.
Syntax
int SmMicOff (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_MIC_ALREADY_OFF SM_RC_MIC_OFF_PENDING SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_MIC_OFF_REPLY
Task Related Functions and Callbacks
SmHaltRecognizer SmMicOn SmQuery SmRecognizeNextWord SmSet SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmMicOn turns on the microphone.
In a recognition session, this function turns on the microphone and starts the audio stream. The application must issue an SmRecognizedNextWord to start the engine decoding.
Syntax
int SmMicOn (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_AP SM_RC_BAD_DECO SM_RC_BUSY_LAST_UTTERANCE SM_RC_BUSY_WORD_CORRECTION SM_RC_ENROLLMENT_NOT_COMPLETE SM_RC_MIC_ALREADY_ON SM_RC_MIC_OFF_PENDING SM_RC_MIC_ON_PENDING SM_RC_NO_SPACE_MIC_ON SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_MIC_ON_REPLY
During a recognition session:
SM_RECOGNIZED_TEXT
Task Related Functions and Callbacks
SmHaltRecognizer SmMicOff SmQuery SmRecognizeNextWord SmSet SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmNewContext sends a new text context.
This function allows a change in text context sent to the speech engine. This function is usually called when text dictation begins at a new location in a document and can only be called when the speech engine is halted. Context refers to previous and following words, which are used to decode the current word in a recognition session.
Syntax
int SmNewContext (short nwords, SM_WORD *words[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_NEW_CONTEXT_REPLY
Task Related Functions and Callbacks
SmCorrectText SmCorrectTextCancel SmRemovePronunciation SmWordCorrection SmNcorrectTextCallback SmNcorrectTextCancelCallback SmNnewContextCallback SmNremovePronunciationCallback SmNwordCorrectionCallback
Purpose
SmOpen opens the SMAPI.
This function establishes a SMAPI connection and initializes values in a connection structure.
Syntax
int SmOpen (int nargs, SmArg *Args);
Parameters
For details on the attributes, see "SMAPI Attributes".
Return Values
SM_RC_EALLOC SM_RC_ENOMEM SM_RC_NAVIGATOR_ALREADY_DEFINED SM_RC_OK SM_RC_ALREADY_CONNECTED SM_RC_ALREADY_OPENEDFor synchronous call and callbacks: SM_RC_OPEN_SYNCH_QUEUE_FAILED SM_RC_NOT_VALID_REQUEST
Task Related Functions and Callbacks
SmConnect SmSetArg SmNconnectCallback
Purpose
SmPlayMessage plays back a prerecorded audio file.
This function allows the user to play a prerecorded audio file. After the speech-aware application requests a playback, it can call SmGetStatus to retrieve the last playback status, which can be one of the following:
| SM_STAT_BAD_AUDIO | The connection to the audio source was lost during playback. |
| SM_STAT_PLAY_START | The message has started playing. |
| SM_STAT_PLAY_STOP | The message has stopped playing. |
Possible return values passed to the SmNplayMessageStatusCallback are:
The following restrictions apply when calling SmPlayMessage:
Syntax
int SmPlayMessage (char *message_name, char *language, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_LANGUAGE SM_RC_BAD_MESSAGE SM_RC_NOT_VALID_REQUEST SM_RC_NOT_WHILE_MIC_ON
Reply Structure Functions by Message Type
SM_PLAY_MESSAGE_REPLY
Task Related Functions and Callbacks
SmCancelPlayback SmPlayUtterance SmPlayWords SmNcancelPlaybackCallback SmNplayMessageCallback SmNplayMessageStatusCallback SmNplayUtteranceCallback SmNplayUtteranceStatusCallback SmNplayWordsCallback SmNplayWordsStatusCallback
Purpose
SmPlayUtterance plays back a spoken utterance.
This function allows an utterance or a portion of an utterance previously spoken during dictation or enrollment to be played back to the user as an error-correction aid. For a monitored enrollment session, an utterance corresponds to a sentence of an enrollment script and, for a recognition session, it corresponds to any word spoken between SmMicOn and subsequent SmMicOff.
After the speech-aware application requests a playback it can call SmGetStatus to retrieve the last playback status, which can be one of the following:
| SM_STAT_BAD_AUDIO | The connection to the audio source was lost during playback. |
| SM_STAT_PLAY_START | The utterance has started playing. |
| SM_STAT_PLAY_STOP | The utterance has stopped playing. |
Possible return values passed to the SmNplayUtteranceStatusCallback are:
The following restrictions apply when calling SmPlayUtterance :
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmPlayUtterance (long uttno, long begtime, long endtime, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST SM_RC_NOT_WHILE_MIC_ON
Reply Structure Functions by Message Type
SM_PLAY_UTTERANCE_REPLY
Task Related Functions and Callbacks
SmCancelPlayback SmPlayMessage SmPlayWords SmNcancelPlaybackCallback SmNplayMessageCallback SmNplayMessageStatusCallback SmNplayUtteranceCallback SmNplayUtteranceStatusCallback SmNplayWordsCallback SmNplayWordsStatusCallback
Purpose
SmPlayWords plays back spoken words.
This function allows a previously spoken word or collection of words to be played back to the user as an error correction aid.
After the speech-aware application requests a playback, it can then call SmGetStatus to retrieve the last playback status, which can be one of the following:
| SM_STAT_BAD_AUDIO | The connection to the audio source was lost during playback. |
| SM_STAT_BAD_TAG | An invalid word (tag) was specified for the played word. |
| SM_STAT_PLAY_START | The word has started playing. |
| SM_STAT_PLAY_STOP | The word has stopped playing. |
Possible return values passed to the SmNplayWordsStatusCallback are:
During a monitored enrollment session, the words that can be played back are those belonging to the example recording of an enrollment script. These words are retrieved by using the SmRequestScriptText call. During a recognition session, the words that can be played back are those found in the reply message structures, SM_RECOGNIZED_TEXT and SM_RECOGNIZED_WORD, sent by the speech engine.
The following restrictions apply when calling SmPlayWords:
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmPlayWords (short ntags, long tags[], long options, SM_MSG *reply);
Parameters
SM_PLAY_WORDS_CONTIGUOUS | When playing multiple words, return a single SM_PLAY_WORDS_STATUS message after all words are played. This is the default. |
SM_PLAY_WORDS_SEPARATE | Reserved, not supported. |
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_TAG SM_RC_NOT_VALID_REQUEST SM_RC_NOT_WHILE_MIC_ON
Reply Structure Functions by Message Type SM_PLAY_WORDS_REPLY
Task Related Functions and Callbacks
SmCancelPlayback SmPlayMessage SmPlayUtterance SmQueryWord SmWordCorrection SmNcancelPlaybackCallback SmNplayMessageCallback SmNplayMessageStatusCallback SmNplayUtteranceCallback SmNplayUtteranceStatusCallback SmNplayWordsCallback SmNplayWordsStatusCallback SmNqueryAddedWordsCallback
Purpose
SmQuery queries a speech engine parameter.
This function queries the value of the specified speech engine parameter. Call the SmGetItemValue function to extract the queried value.
Syntax
int SmQuery (short item, SM_MSG *reply);
Parameters
SM_API_DEBUG | Values include the following: 0 is debugging off, 1 to 5 provide progressively more debug information. A value of 1 or 2 provides flow of control information. |
SM_API_DISPLAY - Reserved |
|
SM_API_LOG - Reserved |
|
SM_API_TIMING - Reserved |
|
SM_AUDIO_CONFIGURATION | Query the input source of the audio hardware where audio data is collected. The returned value is bit mapped and can be any combination of the following values:
|
SM_AUDIO_DEVICE | Query the type of audio hardware. Return values include the following:
|
SM_AUDIO_INPUT_LEVEL | Query the returning of audio-level data during recognition or enrollment. The value is either TRUE (1) or FALSE (0). |
SM_AUDIO_INPUT_MODE | Query the input source of the audio hardware where audio data is collected. The returned value is bit mapped and can be any one of the following values:
|
SM_AUDIO_INPUT_GAIN | If supported by underlying audio, this parameter allows you to query current gain setting. |
SM_AUDIO_OUTPUT_GAIN | If supported by underlying audio, this parameter allows you to query current gain setting. |
SM_AUDIO_OUTPUT_MODE | If supported by underlying audio, this bit value indicates the current output destination. The returned value can be any one of the following values:
|
SM_ENABLE_EXCLUSIVE_VOCABS | Query the calling application's vocabularies. The value is either TRUE (1) for enabled, or FALSE (0) for disabled. |
SM_ENGINE_DEBUG | Reserved. Values include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_ENGINE_DISPLAY | Reserved. Values include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_REJECTION_THRESHOLD | Returns value from SM_MIN_REJECTION_THRESHOLD to SM_MAX_REJECTION_THRESHOLD (refer to SmSet for a detailed description of the SM_REJECTION_THRESHOLD parameter). |
SM_ENGINE_LOG | Reserved. Values include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_NOTIFY_AUDIO_LEVEL | Query the returning of audio-level data during recognition or enrollment. The value is either TRUE (1) or FALSE (0). |
SM_NOTIFY_COMMAND_WORD | Query whether the application is notified when a command word is recognized by having the engine send a SM_COMMAND_WORD reply message. The value is either TRUE (1) or FALSE (0). |
SM_NOTIFY_ENGINE_STATE | Query whether the application is notified of a speech engine state change. The value is either TRUE (1) or FALSE (0). |
SM_NOTIFY_FOCUS_STATE | Query whether the application is notified of a speech focus state change. The value is either TRUE (1) or FALSE (0). |
SM_NOTIFY_MIC_STATE | Query whether the application is notified of a microphone state change. The value is either TRUE (1) or FALSE (0).
|
SM_REDUCED_CPU_MODE | Query the CPU mode of the speech engine. The value is either TRUE (1) for reduced CPU mode, or FALSE (0) for normal CPU mode. See SmGetEngineState for more information. |
SM_SAVE_AUDIO | Query whether recorded audio is being saved during recognition. The value is either TRUE (1) or FALSE (0). |
SM_ENGINE_TIMING | Reserved. Values include the following: 0 is disabled, greater than 0 provides progressively more information. |
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_BAD_MODE SM_RC_NOT_YET SM_RC_EXISTS_IN_NOTIFY SM_RC_NOT_IN_NOTIFYFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_REPLY
Task Related Functions and Callbacks
SmHaltRecognizer SmMicOff SmMicOn SmRecognizeNextWord SmSet SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmQueryAddedWords queries added words.
This function requests a list of all words that have been added to vocabularies of the currently active session.
Syntax
int SmQueryAddedWords (char *vocab, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_ADDED_WORDS_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNplayWordsCallback SmNplayWordsStatusCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback SmNwordCorrectionCallback SmPlayWords SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmWordCorrection
Purpose
SmQueryAlternates requests a list of alternative words.
This function requests a list of alternative choices for a firm word or a group of firm words that has been incorrectly recognized. Errors are usually one-for-one substitutions, in which case only one word needs to be specified on the call to SmGetAlternates. A word may, however, be recognized incorrectly as two or more words. In that case, two or more words might need to be specified in order to get an alternative list containing the correct word.
The following restrictions apply when calling SmQueryAlternates :
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmQueryAlternates (short ntags, long tags[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_ALTERNATES_REPLY
Task Related Functions and Callbacks
SmNqueryAlternatesCallback
Purpose
SmQueryDefault queries the default value for a user, enrollment, or task ID speech attribute.
This function queries the value of SmNuserId, SmNenrollId, or SmNtask speech attributes. These attributes can be specified with SmOpen and SmConnect.
Syntax
int SmQueryDefault (long item, SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_QUERY_DEFAULT_REPLY
Task Related Functions and Callbacks
SmConnect SmOpen SmSetDefault
Purpose
SmQueryEnabledVocabs queries currently enabled vocabularies.
This function obtains a list of all currently enabled vocabularies.
Syntax
int SmQueryEnabledVocabs (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_ENABLED_VOCABS_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmQueryAddedWords SmQueryVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmQueryEnrollIds queries user enrollment IDs.
This function returns a list of the enrollment IDs previously generated for a user by an enrollment procedure. Each time a user enrolls for the recognition system a new enrollment ID is generated for that user. When speech recognition is performed, one of the enrollment IDs from the user's enrollment ID list must be specified for the SmConnect function.
Syntax
int SmQueryEnrollIds (char *user_id, char *enroll_id, char *language, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_ENROLLID SM_RC_BAD_USERID SM_RC_SERVER_MALLOC_ERROR
Reply Structure Functions by Message Type
SM_QUERY_ENROLLIDS_REPLY
Task Related Functions and Callbacks
SmNrequestNewEnrollIdCallback
Purpose
SmQueryLanguages queries the available languages.
This function returns a list of available languages that can be used to initialize the speech engine.
Syntax
int SmQueryLanguages (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_SERVER_MALLOC_ERROR
Reply Structure Functions by Message Type
SM_QUERY_LANGUAGES_REPLY
Task Related Functions and Callbacks
SmNqueryLanguagesCallback
Purpose
SmQueryPronunciation queries a pronunciation.
This function provides a method for a requesting application to determine whether an associated pronunciation exists for a given spelling. This query is applied to the pronunciations that have been added to the user's personal pronunciation pool for the current session.
Syntax
int SmQueryPronunciation (char *spelling, SM_MSG *reply );
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_INVOCAB SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_PRONUNCIATION_REPLY
Task Related Functions and Callbacks
SmAddPronunciation SmQueryPronunciations SmRemovePronunciation SmNaddPronunciationCallback SmNqueryPronunciationCallback SmNqueryPronunciationsCallback SmNremovePronunciationCallback
Purpose
SmQueryPronunciations queries added pronunciations.
This function requests a list of word pronunciations that have been added to the user's pronunciation pool for the current session.
Syntax
int SmQueryPronunciations (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_ERROR SM_RC_SERVER_FILE_OPEN_ERROR
Reply Structure Functions by Message Type
SM_QUERY_PRONUNCIATIONS_REPLY
Task Related Functions and Callbacks
SmAddPronunciation SmQueryPronunciation SmRemovePronunciation SmNaddPronunciationCallback SmNqueryPronunciationCallback SmNqueryPronunciationsCallback SmNremovePronunciationCallback
Purpose
SmQuerySessions queries sessions and returns a list of connected recognition sessions.
Syntax
int SmQuerySessions (SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_QUERY_SESSIONS_REPLY
Task Related Functions and Callbacks
SmDetachSessions SmNdetachSessionsCallback SmNquerySessionsCallback
Purpose
SmQuerySpeechData queries speech data.
Syntax
int SmQuerySpeechData (SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_QUERY_SPEECH_DATA_REPLY
Purpose
SmQueryTasks queries a speech engine domain list.
This function returns a list of the domains that can be used for dictation and enrollment. A domain consists of a set of vocabularies, word-usage models, and other associated parameters used during a recognition session. A domain name must be specified when the speech engine is initialized for a user.
Syntax
int SmQueryTasks (char *language, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_SERVER_MALLOC_ERROR
Reply Structure Functions by Message Type
SM_QUERY_TASKS_REPLY
Task Related Functions and Callbacks
SmNqueryTasksCallback
Purpose
SmQueryUserInfo queries user ID or enrollment ID information.
This function retrieves all information associated with a user ID or an enrollment ID. Only one value can be queried at a time.
Syntax
int SmQueryUserInfo (char *user_id, char *enroll_id, char *itemname, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_ENROLLID SM_RC_BAD_ITEM SM_RC_BAD_USERID
Reply Structure Functions by Message Type
SM_QUERY_USER_INFO_REPLY
Task Related Functions and Callbacks
SmQueryUsers SmSetUserInfo SmNqueryUsersCallback SmNqueryUserInfoCallback SmNsetUserInfoCallback
Purpose
SmQueryUsers queries a user list.
This function returns a list of users allowed to use the speech engine. To establish a speech session, a user from this list must be supplied in the SmNuserId speech attribute.
Syntax
int SmQueryUsers (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_SERVER_MALLOC_ERROR
Reply Structure Functions by Message Type
SM_QUERY_USERS_REPLY
Task Related Functions and Callbacks
SmQueryUserInfo SmSetUserInfo SmNqueryUsersCallback SmNqueryUserInfoCallback SmNsetUserInfoCallback
Purpose
SmQueryVocabs queries currently defined vocabularies.
This function obtains the list of all defined speech engine vocabularies that belong to the current session. This includes predefined vocabularies and those defined after initialization with the SmDefineVocab function.
Syntax
int SmQueryVocabs (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_QUERY_VOCABS_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryWord SmRemoveFromVocab SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmQueryWord checks for a specified word in all active vocabularies.
Syntax
int SmQueryWord (SM_WORD *word, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_INVOCAB
Reply Structure Functions by Message Type
SM_QUERY_WORD_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmPlayWords SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmRemoveFromVocab SmUndefineVocab SmWordCorrection SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNplayWordsCallback SmNplayWordsStatusCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback SmNwordCorrectionCallback
Purpose
SmReceiveMsg receives a message from the speech engine.
This function provides the method through which speech-aware OS/2 applications receive asynchronous messages, including unsolicited asynchronous messages such as SM_RECOGNIZED_TEXT, from the speech engine. This function receives one complete message from the speech engine.
Syntax
int SmReceiveMsg (unsigned long ap_val, SM_MSG *msg);
Parameters
Return Values
SM_RC_OK SM_RC_REPLY_NULL SM_RC_SM_NOT_OPEN
Reply Structure Functions by Message Type
Purpose
SmRecognizeNextWord enables the recognition of the next word.
This function searches for the next word to decode. When running, the engine searches the currently enabled vocabularies to find a word that matches the incoming speech. The vocabulary that contains the best match determines what happens next:
If a recognized word occurs in two or more vocabularies enabled at the same time, the engine selects the word from the more recently enabled command vocabulary. Command vocabularies always override dictation vocabularies; when a recognized word occurs in both a command and dictation vocabulary enabled at the same time, the engine selects the command-vocabulary word.
Syntax
int SmRecognizeNextWord (SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OKFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_RECOGNIZED_WORD
Task Related Functions and Callbacks
SmHaltRecognizer SmMicOff SmMicOn SmQuery SmSet SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmReleaseFocus releases speech focus.
This function releases speech focus for the application calling this API. If the application does not have the speech focus, this function returns SM_RC_NOT_VALID_REQUEST; otherwise it returns SM_RC_OK.
If the call is made asynchronously the reply can be dispatched through either of the following:
Syntax
int SmReleaseFocus (SM_MSG *reply);
Parameters
Return Values
SM_RC_NOT_VALID_REQUEST SM_RC_OK
Reply Structure Functions by Message Type
SM_RELEASE_FOCUS
Task Related Functions and Callbacks
SmRequestFocus SmNfocusGrantedCallback SmNfocusRequestedCallback SmNreleaseFocusCallback SmNrequestFocusCallback
Purpose
SmRemoveCallback removes a single callback routine for a specific callback.
Syntax
int SmRemoveCallback (char *reply_name, SmHandler *handler, caddr_t client_data);
Parameters
Return Values
SM_RC_ENOMEM SM_RC_NOT_VALID_REQUEST SM_RC_OK SM_RC_SM_NOT_OPEN
Task Related Functions and Callbacks
SmAddCallback SmDispatch
Purpose
SmRemoveFromVocab removes words from a dynamic vocabulary.
This function removes words previously added, using SmAddToVocab, to either dynamic vocabularies created by SmDefineVocab or added to predefined vocabularies. This function can be used to dynamically change command vocabularies in an application. Pronunciations for the specified words are not removed by this call and can be reused later by words added to this or any other vocabulary.
This call is valid only when the speech engine is not accepting dictation.
Syntax
int SmRemoveFromVocab (char *vocab, short nvocwords, SM_VOCWORD *vocwords[], SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_VOCAB SM_RC_NOT_VALID_REQUEST SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_FILE_WRITE_ERROR
Reply Structure Functions by Message Type
SM_REMOVE_FROM_VOCAB_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmUndefineVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmRemovePronunciation removes a pronunciation from the user's personal pronunciation pool.
Syntax
int SmRemovePronunciation (char *spelling, char *pronunciation, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST SM_RC_NOT_YET SM_RC_SERVER_ERROR
Reply Structure Functions by Message Type
SM_REMOVE_PRONUNCIATION_REPLY
Task Related Functions and Callbacks
SmAddPronunciation SmCorrectText SmCorrectTextCancel SmNewContext SmQueryPronunciation SmQueryPronunciations SmWordCorrection SmNaddPronunciationCallback SmNcorrectTextCallback SmNcorrectTextCancelCallback SmNnewContextCallback SmNqueryPronunciationCallback SmNqueryPronunciationsCallback SmNremovePronunciationCallback SmNwordCorrectionCallback
Purpose
SmRequestFocus requests speech focus.
An application requests speech focus with a SmRequestFocus function call. If the call is made asynchronously, the reply can be dispatched through either of the following:
Important notes on return code values include the following:
Syntax
int SmRequestFocus (SM_MSG *reply);
Parameters
Return Values
SM_RC_FOCUS_DENIED SM_RC_FOCUS_GRANTED SM_RC_OK
Reply Structure Functions by Message Type
SM_REQUEST_FOCUS
Task Related Functions and Callbacks
SmReleaseFocus SmNfocusGrantedCallback SmNfocusRequestedCallback SmNreleaseFocusCallback SmNrequestFocusCallback
Purpose
SmRequestMicOff requests that the microphone be turned off.
This function requests the speech engine to request the application with speech focus to turn off the microphone. If no application has speech focus, then SM_RC_NO_FOCUS_APP is returned.
Syntax
int SmRequestMicOff (SM_MSG *reply);
Parameters
Return Values
SM_RC_NO_FOCUS_APP SM_RC_OK
Reply Structure Functions by Message Type
SM_REQUEST_MIC_OFF_REPLY
Task Related Functions and Callbacks
SmRequestMicOn SmNrequestMicOffCallback SmNrequestMicOnCallback
Purpose
SmRequestMicOn requests that the microphone be turned on.
This function requests the speech engine to request the application with speech focus to turn on the microphone. If no application has speech focus, then SM_RC_NO_FOCUS_APP is returned.
Syntax
int SmRequestMicOn (SM_MSG *reply);
Parameters
Return Values
SM_RC_NO_FOCUS_APP SM_RC_OK
Reply Structure Functions by Message Type
SM_REQUEST_MIC_ON_REPLY
Task Related Functions and Callbacks
SmRequestMicOff SmNrequestMicOffCallback SmNrequestMicOnCallback
Purpose
SmRestoreSpeechData overwrites the current session files and resets the running utterance number. Only valid in recognition mode.
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmRestoreSpeechData (char *archive, long version, SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_RESTORE_SPEECH_DATA_REPLY
Task Related Functions and Callbacks
SmSaveSpeechData
Purpose
SmSaveSpeechData saves current session speech data to a file.
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmSaveSpeechData (char *archive, long version, long flags, SM_MSG *reply);
Parameters
SM_NORMAL_FILE | The speech data is written to the file specified by the file name. This
file will contain only engine data.
|
SM_COMPOUND_FILE | The speech data is written to the OS/2 compound file specified by the
file name, using IStorage/IStream. The data is saved in a section
named "VTDSessionArchive."
This allows an application to save both engine state and application state
data in the same file.
|
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_SAVE_SPEECH_DATA_REPLY
Task Related Functions and Callbacks
SmRestoreSpeechData
Purpose
SmSet sets the value of a specified speech engine parameter.
Syntax
int SmSet (short item, long value, SM_MSG *reply);
Parameters
SM_API_DEBUG | Values that can be set include the following: 0 is debugging off, 1 to 5 provide progressively more debug information. A value of 1 or 2 provides flow of control information. |
SM_API_DISPLAY | Reserved. |
SM_API_LOG | The values are:
|
SM_API_TIMING | Reserved. |
SM_AUDIO_DEVICE | Selects the type of audio hardware. |
SM_AVAILABLE_AUDIO_DEVICES |
|
SM_AUDIO_CONFIGURATION |
|
SM_AUDIO_INPUT_LEVEL | Sets the returning of audio-level data during recognition or enrollment. The value is either TRUE (1) or FALSE (0). |
SM_AUDIO_INPUT_MODE | Sets the input source of the audio hardware where audio data is collected. Only one value can be specified per call and values include the following:
|
SM_AUDIO_OUTPUT_MODE | If supported by the underlying audio, this parameter indicates the current output destination. Only one value can be specified per call and values include the following:
|
SM_AUDIO_INPUT_GAIN | If suported by underlying audio, this parameter allows you to set current gain setting. Refer to the SMLIMITS.H file for bounds on intput and output values. |
SM_AUDIO_OUTPUT_GAIN | If suported by underlying audio, this parameter allows you to set current gain setting. Refer to the SMLIMITS.H file for bounds on intput and output values. The IBM VoiceType Dictation adapter does not support the value, SM_AUDIO_INPUT_LINE_RIGHT. |
SM_CONNECTION_ID |
|
SM_ENABLE_EXCLUSIVE_VOCABS | Sets the calling application's vocabularies. |
SM_ENGINE_DEBUG | Reserved. Values that can be set include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_ENGINE_DISPLAY | Reserved. Values that can be set include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_PM_ENABLE |
|
SM_REJECTION_THRESHOLD | The speech engine rejects out-of-vocabulary words or
background
noise during monitored enrollment or command recognition.
However,
there is a trade-off between correctly rejecting these
words/noises, and incorrectly rejecting properly spoken words.
|
SM_ENGINE_LOG | Reserved. Values that can be set include the following: 0 is disabled, greater than 0 provides progressively more information. |
SM_NOTIFY_AUDIO_LEVEL | Sets the returning of audio-level data during recognition or enrollment. The value is either TRUE (1) or FALSE (0). See SmGetAudioLevel for more information. |
SM_NOTIFY_COMMAND_WORD | Sets whether the application is notified when a command word is recognized by having the engine send a SM_COMMAND_WORD reply message. The value is either TRUE (1) or FALSE (0). |
SM_NOTIFY_ENGINE_STATE | Sets whether the application is notified of a speech engine state change. The value is either TRUE (1) or FALSE (0). See SmGetEngineState for more information. |
SM_NOTIFY_FOCUS_STATE | Sets whether the application is notified of a speech focus state change. The value is either TRUE (1) or FALSE (0). See SmGetFocusState for more information. |
SM_NOTIFY_MIC_STATE | Sets whether the application is notified of a microphone state change. The value is either TRUE (1) or FALSE (0). See SmGetMicState for more information. |
SM_REDUCED_CPU_MODE | Sets the CPU mode of the speech engine. The value is either TRUE (1) for reduced CPU mode, or FALSE (0) for normal CPU mode. See SmGetEngineState for more information. |
SM_SAVE_AUDIO | Enables or disables the saving of recorded audio during recognition. The value is either TRUE (1) or FALSE (0). For a monitored enrollment session, the default is TRUE, and for a recognition session, the default is FALSE. |
SM_ENGINE_TIMING - Reserved | Values that can be set include the following: 0 is disabled, greater than 0 provides progressively more information. |
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_BAD_MODE SM_RC_BAD_VALUE SM_RC_NOT_YET SM_RC_SERVER_FILE_OPEN_ERROR SM_RC_SERVER_ERROR SM_RC_EXISTS_IN_NOTIFY SM_RC_NOT_IN_NOTIFYFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_SET_REPLY
For SM_NOTIFY_MIC_STATE parameter equal TRUE:
SM_MIC_STATE
For SM_NOTIFY_FOCUS_STATE parameter equal TRUE:
SM_FOCUS_STATE
For SM_NOTIFY_ENGINE_STATE parameter equal TRUE:
SM_ENGINE_STATE
For SM_NOTIFY_COMMAND_WORD parameter equal TRUE:
SM_COMMAND_WORD
For SM_NOTIFY_AUDIO_LEVEL parameter equal TRUE:
SM_AUDIO_LEVEL
Task Related Functions and Callbacks
SmHaltRecognizer SmMicOff SmMicOn SmQuery SmRecognizeNextWord SmNhaltRecognizerCallback SmNmicOffCallback SmNmicOnCallback SmNqueryCallback SmNrecognizeNextWordCallback SmNrecognizedTextCallback SmNrecognizedWordCallback SmNsetCallback SmNutteranceCompletedCallback
Purpose
SmSetArg is a macro that fills an SmArg structure when given its components.
This function sets the components of the arg parameter. The pointer to arg or to a list of similarly created arguments can then be passed to a number of functions, such as SmOpen, and SmConnect.
For further information on attributes, see "SMAPI Attributes".
Syntax
void SmSetArg (SmArg arg, char *name, long value);
Parameters
Return Values None
Task Related Functions and Callbacks
SmConnect SmOpen SmNconnectCallback
Purpose
SmSetDefault sets a default value for a user, enrollment, or task ID speech attribute. This default value is used by the speech engine when SM_USE_DEFAULT is specified for the speech attribute or when the speech attribute is specified. These attributes can be specified with SmOpen and SmConnect.
Syntax
int SmSetDefault (long item, char *item_value, SM_MSG *reply);
Parameters
Return Values
SM_RC_OK
Reply Structure Functions by Message Type
SM_SET_DEFAULT_REPLY
Task Related Functions and Callbacks
SmConnect SmOpen SmQueryDefault
Purpose
SmSetUserInfo sets user information.
This function stores any information that pertains to a user ID or an enrollment ID. It is the responsibility of the speech-aware application to select a proper item name (tag) that uniquely identifies stored information. This item is used later by the SmQueryUserInfo function for retrieving the stored information. This function allows an application to associate string information with a particular user ID or enrollment ID.
Syntax
int SmSetUserInfo (char *user_id, char *enroll_id, char *itemname, char *itemvalue, SM_MSG *reply);
Parameters
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_BAD_ENROLLID SM_RC_BAD_ITEM SM_RC_BAD_USERID
Reply Structure Functions by Message Type
SM_SET_USER_INFO_REPLY
Task Related Functions and Callbacks
SmQueryUserInfo SmQueryUsers SmNqueryUsersCallback SmNqueryUserInfoCallback SmNsetUserInfoCallback
Purpose
SmUndefineVocab deletes a dynamic vocabulary.
This function deletes a vocabulary defined by a SmDefineVocab call. After the vocabulary is deleted, no calls to SmEnableVocab, SmDisableVocab, SmAddToVocab, or SmRemoveFromVocab can be made for the specified vocabulary. The specified vocabulary must be disabled to be deleted.
SmUndefineVocab release the image of the private area of the FSG file.
SmUndefineVocab is valid only when the speech engine is not decoding speech to text.
Syntax
int SmUndefineVocab (char *vocab, SM_MSG *reply);
Parameters
Return Values
SM_RC_BAD_VOCAB SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_UNDEFINE_VOCAB_REPLY
Task Related Functions and Callbacks
SmAddToVocab SmDefineVocab SmDisableVocab SmEnableVocab SmGetAnnotations SmQueryAddedWords SmQueryEnabledVocabs SmQueryVocabs SmQueryWord SmRemoveFromVocab SmNaddToVocabCallback SmNdefineVocabCallback SmNdisableVocabCallback SmNenableVocabCallback SmNqueryAddedWordsCallback SmNqueryEnabledVocabsCallback SmNqueryVocabsCallback SmNqueryWordsCallback SmNremoveFromVocabCallback SmNundefineVocabCallback
Purpose
SmWordCorrection corrects a misrecognized word.
This function notifies the speech engine that an incorrectly recognized word or sequence of words was corrected by the user.
The user corrects the word by providing the correct spelling. This call specifies whether the pronunciation for this word is to be added to the user's personal pronunciation pool and whether the corrected spelling is to be added to the user's personal text vocabulary extension. The speech engine uses this information to assist future recognition.
If an SmWordCorrection call fails and the call is immediately repeated with exactly the same parameters, the engine will automatically apply more lenient threshold parameters the second time (refer to SmSet for a detailed description of the SM_REJECTION_THRESHOLD parameter).
This call is valid only when the speech engine is not decoding speech to text.
Note: For this call to be valid, the application must first enable audio saving through SmSet(SM_SAVE_AUDIO, TRUE).
Syntax
int SmWordCorrection (short ntags, long tags[], short nspells, char *spellings[], char *pronunciations[], short new_pronunciation, SM_MSG *reply);
Parameters
SM_CHECK_SPELLING | Check the spelling of the new word before adding it to the recognition vocabulary as a new word. SM_CHECK_SPELLING is valid only with SM_DEFAULT_ADDWORD. SM_FORCE_ADDWORD and SM_REPLACE_ADDWORD override the spelling check. |
SM_FORCE_ADDWORD | The corrected word is a new pronunciation and needs to be added as a new word even if the word already exists in the vocabulary. |
SM_NO_ADDWORD | The corrected word need not be added to the recognition vocabulary as a new word. |
SM_DEFAULT_ADDWORD | The user needs to decide whether to add the corrected word to the recognition vocabulary. The speech engine produces a pronunciation if one does not already exist. |
SM_REPLACE_ADDWORD | The new pronunciation needs to replace any existing pronunciations of the corrected word. |
Return Values
SM_RC_DEALLOCATING_SH_MEM SM_RC_EALLOC SM_RC_EBADHANDLE SM_RC_ENOCONN SM_RC_ENOMEM SM_RC_ENOMSG SM_RC_ENOSERVER SM_RC_EUNEXP SM_RC_SM_NOT_OPEN SM_RC_OK SM_RC_INVALID_PARM_MAX_LENFor synchronous call and callbacks: SM_RC_MULTIPLE_SPELLINGS SM_RC_NOT_VALID_REQUEST
Reply Structure Functions by Message Type
SM_WORD_CORRECTION_REPLY
Task Related Functions and Callbacks
SmCorrectText SmCorrectTextCancel SmNewContext SmNcorrectTextCallback SmNcorrectTextCancelCallback SmNnewContextCallback SmNplayWordsCallback SmNplayWordsStatusCallback SmNqueryAddedWordsCallback SmNqueryWordsCallback SmNremovePronunciationCallback SmNwordCorrectionCallback SmPlayWords SmQueryAddedWords SmQueryWord SmRemovePronunciation


Output
In this window, you can see the output messages of the compiler and optimizers.
Use the button "
" to clear the contents.
Return to Welcome page


The test network is currently undergoing a huge metamorphisis. The server software has been totally refactored. You can find the code for the new server on GitHub.
In the meantime, you can:


JavaScript is disabled on your browser.
Package
Class
Use
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes
A
C
D
E
G
I
M
O
P
R
S
T
A
addCost(E, double)
- Method in interface city.test1.
Adder
addCost(E, double)
- Method in class city.test1.
CostAdder
addCost(E, double)
- Method in class city.test1.
SpeedAdder
addEdge(E)
- Method in interface city.test1.
IWritableGraph
Adder
<
T
,
E
extends
IEdge
<
T
>> - Interface in
city.test1
Generic interface for adding weights in a graph 'shortest paths' algorithm
addVertex(T)
- Method in interface city.test1.
IWritableGraph
AdjGraph
<
T
,
E
extends
IEdge
<
T
>> - Class in
city.test1
Adjacency graph used for representing the city map.
AdjGraph(List<T>, Set<E>)
- Constructor for class city.test1.
AdjGraph
A
C
D
E
G
I
M
O
P
R
S
T
Package
Class
Use
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes


This fertile sector for apprenticeships can be separated into three major categories:
As you can imagine, there are a wide variety of jobs in the sector. While many apprentices find their ideal job in the farming and skilled agricultural and environmental areas, there are also plenty of diverse, practical, and animal-centric options out there too.
You will also find creative occupations here, like forestry, and caring jobs, for example, working as an apprentice veterinary nurse.


Fig04B: Emission from a boxed area (Type 5). Set Option=1 to visualize the emission area, set to zero to hide it.Fig04C: Emission from a custom image (Type 7). The Count slider means the reference image(triangle) is N layer above this object(circle). Before setting type to 7, please get the reference object ready first, or error may occur.
Emission
Define emission origin as points, area or a 3D-space.
Sliders
Count(Layer)
When Type is 1, 2 or 7, this slider means "Letting the current object is on layer N, the reference object is on layer N-Count, "
When Type is 3 or 4, it means the number of anchors
When Type is 8 and used with Path@, this value is the pathID.
Type
1: Emission origin tracks another object on layer above. Count slider sets the reference layer. It tracks the reference object's x, y and z slider values. Please set the duration of the reference object the same as the particle object.
2: Almost identical to type 1
3: Defines emission from a line (Option=0) or from anchor points(Option=1). The number of anchor points is set by the Count slider. Option=0 is basically a get-around for ParticleRender not supporting temporal change via use of mid-points.
4: Similar to Type 3 but runs along the line, pretty like the worms in pacman game
5: Particles randomly emitted from a 3D-boxed region. The region is defined by 2 anchor points and the boxed region can be color-visualized by setting Option=1. Note that the anchor points may be difficult to adjust unless you switch the object to Advanced drawing mode and use with Camera control object.
6: Similar to 5 but the emission region is a sphere.
7: Similar to 1 and 2 but it also looks into the shape and color(Option=1) of the reference object. A few points to note when using type7:
Temporal change of position and rotation of reference object are supported, but anchor position, size and magnification changes are not supported.
Please set the same duration for the reference object and the particle object.
DO NOT attach the built-in Emission effect to the reference object!
8: Emission pattern determined by external topological function. Path@ should be the first child effect attached to this object. Count slider means the PathID. Sample functions can be found in the ./CustomFunctionSample folder with name Emit*.txt. Just point Path@ to one of the TXT file.
Value
When Type=2, this is a 0.1X speed multiplier. Only effective when Opt2 is checked.
When Type=4, this is the total time (in seconds) required to run from on end of the line to the other end.
When Type=5, this sets the void space(%) at the center of emission region. No particle will be emitted from the void space. Set it to zero to emit from anywhere inside the region. Set it to 100 to emit only from region boundary.
When Type=6, this also sets the center void. See the Type=5 entry above.
When Type=7, this sets the threshold for shape outline.
Option
Type1
0: Particle output direction follows reference object's movement
1: Output direction not taking object movement into account
Type2
0: same as Type 1
1: same as Type 1
Type3
0: Emit from the line as defined by anchor points
1: Emit from anchor points only
Type4
0: Stop at final anchor
1: Loop back to first anchor after the final anchor
Type5
0: Hide emission region
1: Display emission region
Type6
0: Hide emission region
1: Display emission region
Type7
0: Use this object's color
1: color depends on the reference object and the location of emission (see Fig04C)
Type8
0: Use external file as defined by Path@
1: Use Scrip control in this object instead of external file.
Check box
Synthesis Line
For type 3 and 4, enable this if you need more than 16 anchor points. Then you can attach another Emission@ child effect.
Setting dialog
Opt2
Type1: Random particle output from the path of the reference object
Type2: add particle speed with reference object's speed
Type3:
Option=0: Concurrent emission from the same spot
Option=1: Concurrent emission from different anchor points
Type4: Smooth out the motion
Type5: Concurrent emission from the same spot
Type6: Concurrent emission from the same spot
Type7: Particle output direction follows reference object's movement
line
Anchors position in numbers
About custom function
There are two types of functions that you can define, differing in return values:
Type1 template:
function xyz(t)
local r=
local x=
local y=
local z=
return x,y,z
end
where t is object time in seconds,while x,y and z are particle's emission coordinate. r is a user-defined variable.
Type2 template:
function xyzd(t)
local r=
local degxy=
local degz=
local x=
local y=
local z=
degxy=
return x,y,z,degxy,degz
end
where t is object time in seconds,
x,y,z: emission coordinate,
degxy: output angle on x-y plane in radian
degz: output angle for depth in radian.
If you are not using Script control to define these functions, please save the function as ASCII/SJIS text with .txt or .lua extension.


{% extends "layout.html" %} {% block page_title %} Apply for European Structural and Investment Funding {% endblock %} {% block content %} {% include "includes/phase_banner_alpha.html" %} Home Call list Application overview Strategy Strategic fit {% include 'includes/page_errors.html' %} Strategy (1 of 4) Strategic fit Strategic fit How does the project satisfy the call criteria? Why does the project merit the award of funds? Explain how the project represents an appropriate means of delivering the relevant specific objectives and results of the relevant priorities set out in the Operational Programme and how it fits the guiding principles for selection within each Priority Axis Explain how the project is aligned to the local growth needs set out in the local ESIF strategy/strategies Identify any organisation offering the same or similar activity. Explain how the proposed project adds value to and doesn't duplicate existing provision and does not conflict with national policy Save and continue Cancel and return to dashboard {% include "includes/application_info.html" %} {% include "includes/secondary_nav.html" %} {% endblock %}


{% extends "layout.html" %} {% block title %} INDEX PAGE {% endblock %} {% block main %}
This website helps you to improve accuracy while writing essays.
Write essay of any length and click the submit button.
After submitting go ahead and check your results.


The <go-header-bar>
component should be used for the title of a detail page and can incorporate form submit buttons
The Header Bar can optionally include a back arrow on the left and buttons on the right
@Input() showBackArrow: boolean = {{ showBackArrow }}
title
will display the title on the left side of the Header Bar
showBackArrow
will show or hide the back arrow
handleBackButton
would be a custom function to be called when the back
button is clicked. If no function is bound, window.history.back()
will be called.


MySQL connection context
Setup connection params for MySQL.
When to use?
When we want to setup a connection params for MySQL.
How to use:
- In the CONTEXT ID field, enter the Unique name by which this context is referenced, example: TestDatabase
- In the HOST field, enter the hosts IP adress to connect to database, example: <IP_ADDRESS>
- In the PORT field, enter the Port to connect to the host, example: 3031
- In the USERNAME field, enter the Username to authenticate with, example: root
- In the PASSWORD field, enter the Password to use when connecting, example: password
- In the DATABASE NAME field, enter the Name of database to use, example: MyNewDatabase


What is Arduino?
Arduino is a tool for making computers that can sense and control more of the physical world than your desktop computer. It's an open-source physical computing platform based on a simple microcontroller board, and a development environment for writing software for the board.
Arduino can be used to develop interactive objects, taking inputs from a variety of switches or sensors, and controlling a variety of lights, motors, and other physical outputs. Arduino projects can be stand-alone, or they can be communicate with software running on your computer (e.g. Flash, Processing, MaxMSP.) The boards can be assembled by hand or purchased preassembled; the open-source IDE can be downloaded for free.
The Arduino programming language is an implementation of Wiring, a similar physical computing platform, which is based on the Processing multimedia programming environment.
Why Arduino?
There are many other microcontrollers and microcontroller platforms available for physical computing. Parallax Basic Stamp, Netmedia's BX-24, Phidgets, MIT's Handyboard, and many others offer similar functionality. All of these tools take the messy details of microcontroller programming and wrap it up in an easy-to-use package. Arduino also simplifies the process of working with microcontrollers, but it offers some advantage for teachers, students, and interested amateurs over other systems:
- Inexpensive - Arduino boards are relatively inexpensive compared to other microcontroller platforms. The least expensive version of the Arduino module can be assembled by hand, and even the pre-assembled Arduino modules cost less than $50
- Cross-platform - The Arduino software runs on Windows, Macintosh OSX, and Linux operating systems. Most microcontroller systems are limited to Windows.
- Simple, clear programming environment - The Arduino programming environment is easy-to-use for beginners, yet flexible enough for advanced users to take advantage of as well. For teachers, it's conveniently based on the Processing programming environment, so students learning to program in that environment will be familiar with the look and feel of Arduino
- Open source and extensible software- The Arduino software and is published as open source tools, available for extension by experienced programmers. The language can be expanded through C++ libraries, and people wanting to understand the technical details can make the leap from Arduino to the AVR C programming language on which it's based. SImilarly, you can add AVR-C code directly into your Arduino programs if you want to.
- Open source and extensible hardware - The Arduino is based on Atmel's ATMEGA8 and ATMEGA168 microcontrollers. The plans for the modules are published under a Creative Commons license, so experienced circuit designers can make their own version of the module, extending it and improving it. Even relatively inexperienced users can build the breadboard version of the module in order to understand how it works and save money.
How do I use Arduino?
See the getting started guide.
The text of the Arduino getting started guide is licensed under a
Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the guide are released into the public domain.


Hi, my name is Max Ma. I served in the Army. Recently got into the IT industry and looking to learn here.
- CodeFellows 201 Foundations of Software Development
- Microsoft Software and Systems Academy
- George Washington University
- Army Infantry
- Wells Fargo Analyst
My goal is to get a foot in the door into the IT industry, get comfortable with coding with different languages, and later become a software engineer down the road.
Top Favorite Activities
- Running
- Eating
- Sleeping
- Kayaking
- Swimming
- Hiking
- Cooking
- Bowling
- Daydreaming
- Just Chilling


Making Sure Everyone has a Hot Meal this Christmas 3/6/2016
| Hours Volunteered: | 7.5 | |
| Funding Raised: | 298 | |
| Organisation: | Meals on Wheels | |
| Theme: | Homelessness |
We spent the afternoon helping out an amazing bunch of men who are working to setup a Men's Shed in Castlebar. What an amazing new facility for the people of the town. Delighted to help out
Helping Start a new Men's Shed 3/6/2016
| Hours Volunteered: | 1.0 | |
| Funding Raised: | 876 | |
| Organisation: | Men's Shed | |
| Theme: | Social Isolation |
We spent the afternoon helping out an amazing bunch of men who are working to setup a Men's Shed in Castlebar. What an amazing new facility for the people of the town. Delighted to help out
Volunteered with Local Tidy Towns 3/6/2016
| Hours Volunteered: | 2.5 | |
| Funding Raised: | 1600 | |
| Organisation: | Castlebar Tidy Towns | |
| Theme: | Environment |
Our team set ourselves a challenge to volunteer with one new community group every month this year.  We helpeed their brilliant team to clean the ringroad around the town!
Hosted Local Street Feast 3/6/2016
| Hours Volunteered: | 3.5 | |
| Funding Raised: | 2300 | |
| Organisation: | Street Feast | |
| Theme: | Community |
We spent the afternoon helping out an amazing bunch of men who are working to setup a Men's Shed in Castlebar. What an amazing new facility for the people of the town. Delighted to help out


Woops.. We couldn't load your image. Please upload another one.
If this is a good representation, perfect! If not, please upload another one.


Device
Action
Log
System resources
Connected WiFi
Reboot
Raw Command or (use msg.payload)
Command
Name
You can override the command properties with
msg.payload
or
msg.command
To override connections settings just sent
msg.user, msg.password, msg.host, msg.port


CROUPIER (director: Mike Hodges; screenwriter: Paul Mayersberg; cinematographer: Mike Garfath; editor: Les Healey; cast: Clive Owen (Jack Manfred), Kate Hardie (Bella), Alex Kingston (Jani de Villiers), Gina McKee (Marion Neil), Alexander Morton (David Reynolds), Nick Reding (Giles Cremorne), Paul Reynolds (Matt), Nicholas Ball (Jack's Father); Runtime: 91; 1998-UK)
Reviewed by Dennis Schwartz
Being a croupier (dealer) in a London casino surprisingly turns out to be the perfect job for the struggling South African novelist who is looking for a subject and a main character for his book, and will find it in this job he at first thought would only be a secondary one. Clive Owen is Jack Manfred, the poker-faced narrator, whose voice-over not only relates what is taking place onscreen, but relates how his novel is coming along. He sometimes becomes his fictional alter ego, the main character in his novel about a croupier.
Jack, the antihero of this sparkling and intelligent noir tale, is having trouble writing, so he is forced to take a job his unscrupulous father, who was once a notorious gambler but is now a bartender still living in South Africa, secures for him through his connections in a London casino. Jack's father brought him up in casinos and forced his lifestyle upon him, raising him as a single-parent when his wife left him. Jack loathed working as a dealer in the South African casino and moved to London with the hope that he could become a writer.
Why Jack refuses to gamble but enjoys being a croupier becomes a main thread of the story. The answer is only hinted at, being either that Jack has watched his father's gambling habits make him a loser and has sworn that won't happen to him, or perhaps, Jack himself was at one time a compulsive gambler and has had a negative experience.
This is an overlooked noir thriller--shamefully it couldn't get a British film distributor to give it a wide release when it opened. It is a film from Mike Hodge, the director of the legendary "Get Carter" in 1971. What is magnificent about it, is the way its cynical tone captures the London nocturnal after-hours club scene and how the charismatic Clive Owen was able to pull you into his thought process as he weaves Jack's character study, mainly by having him be an observer of the punters (gamblers) in the casino, sneeringly looking down at them as losers. Jack identifies with the casino and the casino's credo of not being in the business of gambling but in winning. Jack wants to do things in a honest way to win, whether as a writer or as a croupier, who makes it a point of telling us how much he hates cheats, yet by a twist of fate, part of the forced psychodynamics of the story, Jack ends up like all the other cheats, choosing to be dishonest. The cynical message inferred, is that one can't change human nature, that sooner or later one will have to make a choice and bend the rules to accomodate who one is.
In a plot that can be faulted only for its contrived surprise ending and a death of one of the main players near the end, that adds absolutely nothing to the story, what remains striking, is the passion the croupier has for casino life and how it relates to his passion for writing.
The croupier knows that he has hit nirvana when he can no longer hear the ball of the wheel as it rolls. It is beautiful to see this notion converted onto the screen, as the film is a one-man show for Clive Owen, relating how the tension builds inside him as he is confronted with changes in his life, whether they are ones that might be considered trivial like being forced to ride public transport or heavier changes, as how to deal with his ex-cop, current store detective live-in girlfriend Marion (Gina), or even heavier changes, if he should get involved in a casino scam.
Jack wavers between loving Marion as if she were his conscience or not being fully in love with her because he can't love someone who is so straight. She states that she only wants to live with a writer not a "fucking" croupier and always has such a sad expression, and is an open book to read; while, Jack is always an enigma. How Jack deals with his life and how keenly accurate he is in describing others he meets, makes this film very literary.
He instantly becomes a favorite of casino manager David Reynolds (Alexander Morton) because he is so good at the job and because he is so trustworthy. Reynolds lectures him about the house rules and warns him about fraternizing with gamblers and with his fellow casino employees, and also tells him that he must report anyone he sees cheating or else he will lose his job.

There are a few other subplots brought up, such as him beating up men who are cheaters. But, as with the many other subplots, its theme is never fully realized.
When compared to three recent films about gambling, "Casino," "The Rounders" and "Reindeer Games," there is no comparison, this one was the more real and pertinent one. It is only too bad that "Croupier" couldn't feel more committed to the power of the lyrical voice-over and less to the canned responses of all the odd twists it had to throw into the story, that diminished the bleak truth it was harping at -- of how life itself is a game of chance and the casino is only a cheap imitation of life.
In the end, the film's stylish depiction of the casino milieu, its thrilling noir ambiance, and the character study of the croupier, override the film's failure to end the film convincingly with the kind of payoff that this thriller warranted.  But the ace it has up its sleeve, is the distinguished performance by Clive Owen.
REVIEWED ON 7/13/2000 GRADE: B+
Dennis Schwartz: "Ozus' World Movie Reviews"
http://www.sover.net/~ozus
<EMAIL_ADDRESS>© ALL RIGHTS RESERVED DENNIS SCHWARTZ
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Life Becomes Beautiful with love ones
"Feelings aroused by the touch of someone's hand, the sound of music, the smell of a flower, a beautiful sunset, a work of art, love, laughter, hope and faith - all work on both the unconscious and the conscious aspects of the self, and they have physiological consequences as well."
Mr. Thulunga Basumatary
Hi, Im the owner of this site. This site is on building procedure. I really appreciate your help, love and support for this site.

"Inspiration is the greatest gift because it opens your life to many new possibilities. Each day becomes more meaningful, and your life is enhanced when your actions are guided by what inspires you."       --Bernie Siegel
Mr. Sajib Daimary
Hi, Im side owner and contributor of this site. This site is on building procedure. I really appreciate your help, love and support for this site.
Miss. Nilanjana Daimary
Hi, Im side owner and contributor of this site. This site is on building procedure. I really appreciate your help, love and support for this site.
Check our other contributor profile
We make difference
Swgwmsar Daimary
"Being a survivor doesn't mean being strong - it's telling people when you need a meal or a ride, company, whatever. It's paying attention to heart wisdom, feelings, not living a role, but having a unique, authentic life, having something to contribute, finding time to love and laugh. All these things are qualities of survivors."
Contact meEngeneer
Ruprekha Daimary
"Stay true to yourself, yet always be open to learn. Work hard, and never give up on your dreams, even when nobody else believes they can come true but you. These are not cliches but real tools you need no matter what you do in life to stay focused on your path."
Contact me+1 grade


What do you want to do?
Decrypt a file
Choose which file to decrypt
Only files encrypted by this tool are accepted.
Browse
Enter the pass phrase
Enter the pass phrase that was used to encrypt this file. It is not possible to decrypt it without it.
Decrypt!
Your file is ready!
Download