2 * Copyright (c) 2012, 2013 Samsung Electronics Co., Ltd All Rights Reserved
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 * http://www.apache.org/licenses/LICENSE-2.0
7 * Unless required by applicable law or agreed to in writing, software
8 * distributed under the License is distributed on an "AS IS" BASIS,
9 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 * See the License for the specific language governing permissions and
11 * limitations under the License.
15 #ifndef __TTSD_MAIN_H_
16 #define __TTSD_MAIN_H_
34 /* TTS Daemon Define */
35 #define BASE_DIRECTORY_DEFAULT "/usr/lib/voice/tts/1.0"
36 #define ENGINE_DIRECTORY_DEFAULT "/usr/lib/voice/tts/1.0/engine"
37 #define ENGINE_DIRECTORY_DEFAULT_SETTING "/usr/lib/voice/tts/1.0/setting"
39 #define CONFIG_DIRECTORY "/opt/home/app/.voice"
41 #define ENGINE_DIRECTORY_DOWNLOAD "/opt/usr/voice/tts/1.0/engine"
42 #define ENGINE_DIRECTORY_DOWNLOAD_SETTING "/opt/usr/voice/tts/1.0/setting"
45 /* for debug message */
49 TTSD_ERROR_NONE = 0, /**< Successful */
50 TTSD_ERROR_OUT_OF_MEMORY = -ENOMEM, /**< Out of Memory */
51 TTSD_ERROR_IO_ERROR = -EIO, /**< I/O error */
52 TTSD_ERROR_INVALID_PARAMETER = -EINVAL, /**< Invalid parameter */
53 TTSD_ERROR_OUT_OF_NETWORK = -ENETDOWN, /**< Out of network */
54 TTSD_ERROR_INVALID_STATE = -0x0100000 | 0x21, /**< Invalid state */
55 TTSD_ERROR_INVALID_VOICE = -0x0100000 | 0x22, /**< Invalid voice */
56 TTSD_ERROR_ENGINE_NOT_FOUND = -0x0100000 | 0x23, /**< No available engine */
57 TTSD_ERROR_TIMED_OUT = -0x0100000 | 0x24, /**< No answer from the daemon */
58 TTSD_ERROR_OPERATION_FAILED = -0x0100000 | 0x25 /**< Operation failed */
62 TTSD_MODE_DEFAULT = 0, /**< Default mode for normal application */
63 TTSD_MODE_NOTIFICATION, /**< Notification mode */
64 TTSD_MODE_SCREEN_READER /**< Screen reader mode */
68 TTSD_INTERRUPTED_PAUSED = 0, /**< Current state change 'Pause' */
69 TTSD_INTERRUPTED_STOPPED /**< Current state change 'Ready' */
70 }ttsd_interrupted_code_e;
81 ttsp_voice_type_e type;
89 /* get daemon mode : default, notification or screen reader */
90 ttsd_mode_e ttsd_get_mode();
92 /* Get log tag : default, notification, screen reader */
99 #endif /* __TTSD_MAIN_H_ */