what is the difference between otg cable and usb cable?
This is where USB-on-the-go (OTG) comes in. It adds an extra pin to the micro-USB socket. If you plug a normal A-to-B USB cable, the device acts in peripheral mode. If you connect a special USB-OTG cable, it has the pin connected at one end, and the device at that end acts in host mode.