To set N800 back to OTG mode, do: # echo otg > /sys/devices/platform/musb_hdrc/mode If the system does not detect cable events after switching back to OTG mode, switch it to peripheral mode first, then to OTG mode: # echo peripheral > /sys/devices/platform/musb_hdrc/mode # echo otg > /sys/devices/platform/musb_hdrc/mode