Is there a difference in OTG and Usb extension cable?
I'm trying to connect my Android phone with some IoT device and when I connect it via OTG cable it works fine, but with regular extension cable it doesn't. I assume there is a reason, right?
USB extension cables are simply pass through cables - they have the same pin connections on both ends.
OTG cables however, stand for On The Go, and have an extra pin on the micro-USB socket. This allows devices (such as Android phones) to act as hosts to other devices (such as an IoT device).
Side note - this question is probably more suited for https://electronics.stackexchange.com.