X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;ds=sidebyside;f=ss_usb_handler.c;h=13b51a0a5f9173f7a56e0a9f1bf0c46328864558;hb=HEAD;hp=94a61af9e0863d1c89b91cb9ad09aa3c2af0f542;hpb=bfc407295d754c365cf3201350d531d3b2c864c6;p=framework%2Fsystem%2Fsystem-server.git diff --git a/ss_usb_handler.c b/ss_usb_handler.c index 94a61af..13b51a0 100644 --- a/ss_usb_handler.c +++ b/ss_usb_handler.c @@ -24,8 +24,8 @@ #include "ss_launch.h" #include "include/ss_data.h" -#define USBCON_EXEC_PATH PREFIX"/bin/usb_setting" -#define RETRY 3 +#define USBCON_EXEC_PATH PREFIX"/bin/usb-server" +#define RETRY 3 int ss_usb_init() { @@ -33,11 +33,11 @@ int ss_usb_init() PRT_TRACE("check usb connection"); if (plugin_intf->OEM_sys_get_jack_usb_online(&val) == 0) { - if (val) { + if (val==1) { vconf_set_int(VCONFKEY_SYSMAN_USB_STATUS, - VCONFKEY_SYSMAN_USB_AVAILABLE); + VCONFKEY_SYSMAN_USB_AVAILABLE); while (i < RETRY - && pm_lock_state(LCD_OFF, STAY_CUR_STATE, + && pm_lock_state(LCD_OFF, STAY_CUR_STATE, 0) == -1) { i++; sleep(1); @@ -48,6 +48,8 @@ int ss_usb_init() return -1; } } + else if (val==0) + vconf_set_int(VCONFKEY_SYSMAN_USB_STATUS,VCONFKEY_SYSMAN_USB_DISCONNECTED); } return 0;