aboutsummaryrefslogtreecommitdiffstats
path: root/src/sm-def.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/sm-def.h')
-rw-r--r--src/sm-def.h70
1 files changed, 67 insertions, 3 deletions
diff --git a/src/sm-def.h b/src/sm-def.h
index 9d4acb5..bd565d5 100644
--- a/src/sm-def.h
+++ b/src/sm-def.h
@@ -1,3 +1,18 @@
+/*
+ * Copyright (c) 2017 TOYOTA MOTOR CORPORATION
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef SOUNDMANAGER_DEFINE_H
#define SOUNDMANAGER_DEFINE_H
@@ -38,7 +53,7 @@
#define KEY_DOMAIN_ID "domainID"
#define KEY_HANDLE "handle"
-#define KEY_APPNAME "appname"
+#define KEY_APPNAME "audio_role"
#define KEY_RAMP "ramp"
#define KEY_TIME "time"
#define KEY_SOURCE_STATE "sourceState"
@@ -55,15 +70,64 @@
#define KEY_CONNECTION_FORMAT "connectionFormat"
#define KEY_EVENT "event"
+#define KEY_RESPONSE "response"
+
+#define SM_EVENT_VOLUME_CHANGED "volumeChanged"
+#define SM_EVENT_NEW_MAIN_CONNECTION "newMainConnection"
+#define SM_EVENT_REMOVED_MAIN_CONNECTION "removedMainConnection"
+#define SM_EVENT_SINK_MUTE_STATE_CHANGED "sinkMuteStateChanged"
+#define SM_EVENT_MAIN_CONNECTION_STATE_CHANGED "mainConnectionStateChanged"
+/* Routing event*/
+#define SM_EVENT_SET_ROUTING_READY "setRoutingReady"
+#define SM_EVENT_SET_ROUTING_RUNDOWN "setRoutingRundown"
+#define SM_EVENT_ASYNC_CONNECT "asyncConnect"
+#define SM_EVENT_ASYNC_SET_SOURCE_STATE "asyncSetSourceState"
+#define SM_EVENT_ASYNC_DISCONNECT "asyncDisconnect"
+#define SM_EVENT_STREAM_STATE_EVENT "stream_state_event"
+
+#ifdef ENABLE_AGL_AHL
#define KEY_AHL_AUDIO_ROLE "audio_role"
#define KEY_AHL_ENDPOINT_ID "endpoint_id"
#define KEY_AHL_ENDPOINT_TYPE "endpoint_type"
+#define KEY_AHL_REP_STREAM_ID "stream_id"
+#define KEY_AHL_EVENT_NAME "event_name"
+#define KEY_AHL_STATE_EVENT "state_event"
+#define AHL_EVENT_NAME "ahl_stream_state_event"
+#define KEY_AHL_MUTE "mute"
+#define AHL_STREAM_UNMUTE 0
+#define AHL_STREAM_MUTE 1
typedef enum {
ENDPOINT_SINK,
ENDPOINT_SOURCE,
} EndPointType;
+#endif
+
+typedef enum {
+ NOT_INITIALIZED = -2,
+ UNABLE_SEND,
+ OK = 0,
+ UNKNOWN,
+ OUT_RANGE,
+ NOT_USED,
+ DATABASE_ERR,
+ OBJECT_ALREADY_EXIST,
+ NO_CHANGE,
+ ACTION_IMPOSSIBLE,
+ OBJECT_NOT_EXIST,
+ ASYNC_ACTION_ABORTED,
+ CONNECTION_FORMAT_ERR,
+ COMMUNICATION_ERR,
+ EVENT_NOT_EXIST = 100
+} ErrorCode;
+
+typedef enum {
+ REQ_FAIL,
+ OUT_OF_RANGE,
+ NOT_NUMBER,
+ REQ_OK
+} REQ_ERROR;
-#define MAX_LENGTH_STRING 256
+#define MAX_LENGTH_STR 256
-#endif // SOUNDMANAGER_DEFINE_H
+#endif // SOUNDMANAGER_DEFINE_H \ No newline at end of file