summaryrefslogtreecommitdiff
path: root/src/include/radio_hal_interface.h
blob: 68bfb149a25363a5773ed267d023b626d45d6954 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/*
 * radio_hal_interface.h
 *
 * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
 *
 * 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.
 *
 */

#ifdef __cplusplus
extern "C" {
#endif

#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include "tizen-radio.h"

typedef enum _seek_direction_type {
	SEEK_DIRECTION_UP,	/**< Seek upward */
	SEEK_DIRECTION_DOWN	/**< Seek downward */
} seek_direction_type_t;

typedef struct _mmradio_hal_interface {
	void *dl_handle;
	void *rh_handle;
	radio_interface_t intf;
} mm_radio_hal_interface;

int radio_hal_interface_init(mm_radio_hal_interface **handle);
int radio_hal_interface_deinit(mm_radio_hal_interface *handle);
int radio_hal_open(mm_radio_hal_interface *radio_handle);
int radio_hal_prepare(mm_radio_hal_interface *radio_handle);
int radio_hal_unprepare(mm_radio_hal_interface *radio_handle);
int radio_hal_close(mm_radio_hal_interface *radio_handle);
int radio_hal_start(mm_radio_hal_interface *radio_handle);
int radio_hal_stop(mm_radio_hal_interface *radio_handle);
int radio_hal_seek(mm_radio_hal_interface *radio_handle, seek_direction_type_t direction);
int radio_hal_get_frequency(mm_radio_hal_interface *radio_handle, uint32_t *frequency);
int radio_hal_set_frequency(mm_radio_hal_interface *radio_handle, uint32_t frequency);
int radio_hal_get_signal_strength(mm_radio_hal_interface *radio_handle, uint32_t *strength);
int radio_hal_mute(mm_radio_hal_interface *radio_handle);
int radio_hal_unmute(mm_radio_hal_interface *radio_handle);
#ifdef __cplusplus
}
#endif