2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
20 #include <tone_player.h>
26 static GMainLoop *g_mainloop = NULL;
27 static GThread *event_thread;
29 gpointer GmainThread(gpointer data){
30 g_mainloop = g_main_loop_new (NULL, 0);
31 g_main_loop_run (g_mainloop);
36 void tone_play_test(){
39 for( i =0 ; i <= 106 ; i++){
40 printf("play %d sound\n", i);
41 tone_player_start(i, SOUND_TYPE_MEDIA ,500,NULL);
46 // tone_player_start(SOUND_TONE_DTMF_C, SOUND_TYPE_MEDIA ,100000,NULL);
50 int main(int argc, char**argv)
52 if( !g_thread_supported() )
58 event_thread = g_thread_create(GmainThread, NULL, 1, &gerr);