Christopher N. Hesse | bc52af5 | 2017-02-10 21:20:30 +0100 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2013 The CyanogenMod Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | #ifndef RIL_INTERFACE_H |
| 18 | #define RIL_INTERFACE_H |
| 19 | |
Christopher N. Hesse | 74c317d | 2017-02-15 09:47:20 +0100 | [diff] [blame] | 20 | #include <samsung_audio.h> |
Christopher N. Hesse | bc52af5 | 2017-02-10 21:20:30 +0100 | [diff] [blame] | 21 | #include <secril-client.h> |
| 22 | |
Andreas Schneider | 49b9dcb | 2017-02-13 17:15:07 +0100 | [diff] [blame] | 23 | /** |
| 24 | * @brief The callback to change to wideband which should |
| 25 | * be implemented by the audio HAL. |
| 26 | * |
| 27 | * @param[in] data User data poiner |
| 28 | * @param[in] wb_amr_type 0 = disable WB, 1 = enable WB, |
| 29 | * 2 = WB (and probably NS) |
| 30 | */ |
| 31 | typedef void (*ril_wb_amr_callback)(void *data, int wb_amr_type); |
Christopher N. Hesse | bc52af5 | 2017-02-10 21:20:30 +0100 | [diff] [blame] | 32 | |
| 33 | struct ril_handle |
| 34 | { |
| 35 | void *client; |
| 36 | int volume_steps_max; |
| 37 | }; |
| 38 | |
| 39 | |
| 40 | /* Function prototypes */ |
| 41 | int ril_open(struct ril_handle *ril); |
| 42 | |
| 43 | int ril_close(struct ril_handle *ril); |
| 44 | |
| 45 | int ril_set_call_volume(struct ril_handle *ril, |
| 46 | enum _SoundType sound_type, |
| 47 | float volume); |
| 48 | |
| 49 | int ril_set_call_audio_path(struct ril_handle *ril, |
| 50 | enum _AudioPath path); |
| 51 | |
| 52 | int ril_set_call_clock_sync(struct ril_handle *ril, |
| 53 | enum _SoundClockCondition condition); |
| 54 | |
| 55 | int ril_set_mute(struct ril_handle *ril, enum _MuteCondition condition); |
| 56 | |
| 57 | int ril_set_two_mic_control(struct ril_handle *ril, |
| 58 | enum __TwoMicSolDevice device, |
| 59 | enum __TwoMicSolReport report); |
| 60 | |
| 61 | int ril_set_wb_amr_callback(struct ril_handle *ril, |
| 62 | ril_wb_amr_callback fn, |
| 63 | void *data); |
| 64 | |
| 65 | #endif |