예제 #1
0
/**@brief Function to initialize tone to be played.
 *
 * @param[in]  tone_id Tone identifier.
 * @param[in]  priv Additional data. NULL if not used.
 * @return   none
 */
static void ui_tone_play_init(uint8_t tone_id, void *priv)
{
    audio_port_t port;

    tone_stream = as_stream_create("Audio Tone Resp");

    pr_debug(LOG_MODULE_UI_SVC,
        "Audio: init play tone id 0x%x stream 0x%x",
        tone_id,
        tone_stream);

    as_stream_init(audio_client_cfw_hdl,
               tone_stream,
               AUDIO_STREAM_MEDIA,
               &port);

    /* FIXME: audio port structure not finalized yet. */
    /*        To be completed here once available.    */
}
예제 #2
0
/**@brief Function to initialize speech sequence to be played.
 *
 * @param[in]  sequence_id Speech sequence identifier.
 * @param[in]  priv Additional data. NULL if not used.
 * @return   none
 */
static void ui_sps_play_init(uint8_t sequence_id, void *priv)
{
    audio_port_t port;

    sps_stream = as_stream_create("Audio UI Sps resp");

    pr_debug(LOG_MODULE_UI_SVC,
        "Audio: init play sps id 0x%x stream 0x%x",
        sequence_id,
        sps_stream);

    as_stream_init(audio_client_cfw_hdl,
               sps_stream,
               AUDIO_STREAM_VOICE,
               &port);

    /* FIXME: audio port structure not finalized yet. */
    /*        To be completed here once available.    */
}
예제 #3
0
as_stream * consumer_stream_init(as_stream * s, consumer_callback f) {
    return as_stream_init(s, f, &consumer_stream_hooks);
}
예제 #4
0
as_stream * producer_stream_init(as_stream * s, producer_callback f) {
    return as_stream_init(s, f, &producer_stream_hooks);
}