4 static void print_menu(void)
6 printf("Which do you want to do?\n");
7 printf("\t0 : Play\n");
8 printf("\t1 : Change the path\n");
9 printf("\t2 : Reset the path\n");
10 printf("\tothers : quit\n");
13 static void print_play_menu(void)
15 printf("Which do you want to do?\n");
17 printf("\t1. sound\n");
18 printf("\t2. vibration\n");
20 printf("\tothers. quit\n");
23 static void play(void)
29 printf("Please enter the play menu : ");
33 printf("Please input value (exit:-1) : ");
39 val = feedback_play(b);
41 val = feedback_play_type(a, b);
43 printf("ret value : %d\n", val);
47 int main(int argc, char* argv[])
49 char buf[4096] = {0,};
53 val = feedback_initialize();
54 if (val != FEEDBACK_ERROR_NONE) {
55 printf("feedback_initialize error : %d\n", val);
61 printf("Please input value : ");
69 printf("Please input type(sound:0,vib:1), enum, new path : ");
70 scanf("%d %d %s", &a, &b, buf);
71 val = feedback_set_resource_path((a == 0) ? FEEDBACK_TYPE_SOUND : FEEDBACK_TYPE_VIBRATION, b, buf);
72 printf("ret value : %d\n", val);
75 printf("Please input type(sound:0,vib:1), enum : ");
76 scanf("%d %d", &a, &b);
77 val = feedback_set_resource_path((a == 0) ? FEEDBACK_TYPE_SOUND : FEEDBACK_TYPE_VIBRATION, b, NULL);
78 printf("ret value : %d\n", val);
86 val = feedback_deinitialize();
87 if (val != FEEDBACK_ERROR_NONE) {
88 printf("feedback_initialize error : %d\n", val);