Alexa Auto SDK  4.3
Public Member Functions | List of all members
aace::alexa::AlexaSpeaker Class Reference

Public Member Functions

virtual void speakerSettingsChanged (SpeakerType type, bool local, int8_t volume, bool mute)
 
void localSetVolume (SpeakerType type, int8_t volume)
 
void localAdjustVolume (SpeakerType type, int8_t delta)
 
void localSetMute (SpeakerType type, bool mute)
 

Detailed Description

AlexaSpeaker is the interface for setting the Alexa volume and mute controls.

Deprecated:
This platform interface is deprecated. Use the Alexa Auto Services Bridge (AASB) message broker to publish and subscribe to AASB messages instead.
See also
aace::core::MessageBroker

Member Function Documentation

◆ speakerSettingsChanged()

void aace::alexa::AlexaSpeaker::speakerSettingsChanged ( SpeakerType  type,
bool  local,
int8_t  volume,
bool  mute 
)
virtual

Notifies the platform implementation that the speaker settings have changed for a specific speaker type.

Note
Calling AlexaSpeaker::localSetVolume, AlexaSpeaker::localAdjustVolume, or AlexaSpeaker::localSetMute from inside this function will cause deadlock.
Parameters
[in]typeThe type of Alexa speaker being set.
[in]localtrue if the change originated from calling AlexaSpeaker::localSetVolume, AlexaSpeaker::localAdjustVolume, or AlexaSpeaker::localSetMute.
[in]volumeThe new volume setting of the Speaker. The volume reported will be scaled to the range [0,100].
[in]muteThe mute setting of the Speaker. true when the Speaker is muted, else false.

◆ localSetVolume()

void aace::alexa::AlexaSpeaker::localSetVolume ( SpeakerType  type,
int8_t  volume 
)

Notifies the Engine of a volume change event originating on the platform, such as a user pressing a "volume up" or "volume down" button. If the Speaker is Type::ALEXA_VOLUME, the Engine will respond with a call to setVolume() on each AVS-synced Speaker.

Parameters
[in]typeThe type of Alexa speaker being set.
[in]volumeThe new volume setting of the Speaker. The volume reported must be scaled to the range [0,100].

◆ localAdjustVolume()

void aace::alexa::AlexaSpeaker::localAdjustVolume ( SpeakerType  type,
int8_t  delta 
)

Notifies the Engine of a relative adjustment to the volume setting of the Speaker, originating on the platform. The delta value is relative to the current volume setting and is positive to increase volume or negative to reduce volume. The volume delta value should be scaled to fit the needs of the platform.

Parameters
[in]typeThe type of Alexa speaker being set.
[in]deltaThe volume adjustment to apply to the Speaker. delta is in the range [-100, 100].

◆ localSetMute()

void aace::alexa::AlexaSpeaker::localSetMute ( SpeakerType  type,
bool  mute 
)

Notifies the Engine of a mute setting change event originating on the platform, such as a user pressing a "mute" button. If the Speaker is Type::ALEXA_VOLUME, the Engine will respond with a call to setMute() on each AVS-synced Speaker.

Parameters
[in]typeThe type of Alexa speaker being set.
[in]muteThe new mute setting of the Speaker. true when the Speaker is muted, else false

Alexa Auto SDK 4.3 - Copyright 2017-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0