summaryrefslogtreecommitdiff
path: root/include/IAmControl.h
diff options
context:
space:
mode:
authorMartin Koch <martin.koch@ese.de>2020-06-19 16:01:19 +0200
committerMartin Koch <martin.koch@ese.de>2020-07-01 14:37:32 +0200
commit066c3f7f16ef69e80376942e8d6b8c4944b8ed08 (patch)
treed7d6ee7e5591e6915865ff0b0fa67191091032ca /include/IAmControl.h
parent4b34f9dc67e4ff1948d233346c2e5e3b14b8e78a (diff)
downloadaudiomanager-066c3f7f16ef69e80376942e8d6b8c4944b8ed08.tar.gz
Add support for announcement and handling of pre-established audio connections through routing side
As the complete initialization of the cockpit system takes some time, a few use-cases exist where information needs to be audible (or visible) right before the system is fully started. Here we mainly have: - system alerts + door open + seat belt missing + engine faults - parking assistant warnings + rear view camera screen + beeps if distance goes below limit Both routing- and control-side are extended to allow notifying about such connections Signed-off-by: Martin Koch <martin.koch@ese.de>
Diffstat (limited to 'include/IAmControl.h')
-rw-r--r--include/IAmControl.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/include/IAmControl.h b/include/IAmControl.h
index 32008a0..e8545ad 100644
--- a/include/IAmControl.h
+++ b/include/IAmControl.h
@@ -554,6 +554,20 @@ public:
* confirmRoutingRundown.
*/
virtual void setRoutingRundown() =0;
+
+ /**
+ * Hand-over to routing-side application any connection meant to survive AM shutdown
+ *
+ * @param handle: composite identifier used to map the response
+ * @param domainID: target domain which shall take over
+ * @param mainConnectionID: subject of this request
+ *
+ * @return E_OK if command was forwarded to routing adapter successfully,
+ * E_COMMUNICATION or other meaningful value otherwise
+ */
+ virtual am_Error_e transferConnection(const am_Handle_s handle
+ , am_mainConnectionID_t mainConnectionID, am_domainID_t domainID) = 0;
+
/**
* acknowledges the setControllerReady call.
*/
@@ -858,6 +872,24 @@ public:
* @return E_OK on success, E_UNKNOWN on error, E_NON_EXISTENT if not found
*/
virtual am_Error_e hookSystemDeregisterCrossfader(const am_crossfaderID_t crossfaderID) =0;
+
+ /**
+ * Support announcement of audio connections already active at AM startup
+ *
+ * @param domainID: home domain announcing this early connection
+ * @param mainConnectionData: details of main connection
+ *
+ * @return success indicator. Controller should use E_OK on success,
+ * E_ALREADY_EXISTS or E_NO_CHANGE if given connection is already registered,
+ * E_DATABASE_ERROR if any of the listed sources or sinks does not exist in the data base,
+ * E_NOT_POSSIBLE if feature is not supported by the controller
+ */
+ virtual am_Error_e hookSystemRegisterEarlyMainConnection(am_domainID_t domainID
+ , const am_MainConnection_s &mainConnectionData)
+ {
+ return E_NOT_POSSIBLE; // empty default implementation
+ }
+
/**
* volumeticks. therse are used to indicate volumechanges during a ramp
*/
@@ -905,6 +937,19 @@ public:
* ack for disconnect
*/
virtual void cbAckDisconnect(const am_Handle_s handle, const am_Error_e errorID) =0;
+
+ /**
+ * Hand-over acknowledgment of connections surviving shutdown of the AM,
+ * forwarded from routing side (see @ref IAmRoutingReceive::ackTransferConnection)
+ *
+ * @param handle: composite identifier mirrored from request
+ * @param errorID: success indicator as obtained from routing side application
+ */
+ virtual void cbAckTransferConnection(const am_Handle_s /* handle */, const am_Error_e /* errorID */)
+ {
+ // empty default implementation
+ }
+
/**
* ack for crossfading
*/