Electronics > Projects, Designs, and Technical Stuff

Trick USB Device Into Thinking it is Plugged Into a Computer

(1/4) > >>

Bigjoe11:
I was wondering if anyone knew how I could potentially trick a USB device into thinking it's plugged into a computer when, in reality, I am only providing it with power.

The device in question is the following (I am not advertising this product): https://www.amazon.com/EACHINE-ROTG02-Receiver-Android-Smartphone/dp/B07NNH93NX

There are USB and AVI outputs on the device. I would like to use the AVI output only, but the device won't power up unless the micro-USB is plugged into a computer.or a phone.  Even if I provide power through the micro-USB or AVI ports, it will not power up unless the micro-usb is plugged into a phone or a laptop. The phone/laptop recognizes the device as a webcam.

This is a huge pain, so if there is any way I could modify the device or the plug to trick it that would be awesome. I have already attempted to make it work by connecting the sense pin to ground through a resistor and by connecting resistors between the data and ground pins to no avail.

Here is a guide for the USB pinouts: https://www.electroschematics.com/usb-how-things-work/

Has anyone done something like this before? I have done extensive searches and creating this account is my last resort.

Please let me know if pictures or more info would help. Thanks!

tooki:
It sounds to me like the AV output* is a secondary function of that webcam chipset, and that the chipset is correctly only drawing >100mA after negotiating with the USB host.

If they never intended for it to be used without a computer host, then they likely never designed it to look for a dumb battery charger (i.e. using the USB Battery Charging protocol, like the bridged data pins). My hunch is that what you're seeking to do is categorically impossible.


*When you say "AVI", I assume you mean something like analog (CVBS/composite) video. (AVI is a file format.)

Bigjoe11:
Hi tooki,

Thank you so much for the reply. Yes, I did mean AV, not AVI. I know that it does not work with a dumb battery charger, but I came here to see if I could trick it by adding resistors or some type of simple logic. Are you familiar with the protocol it would use establish and confirm a connection with a computer?

NiHaoMike:
Open it up and take a picture of both sides of the board. There might be an easy mod to bypass the switching so that the receiver part just needs power to run.

tooki:

--- Quote from: Bigjoe11 on May 14, 2020, 09:58:27 pm ---Hi tooki,

Thank you so much for the reply. Yes, I did mean AV, not AVI. I know that it does not work with a dumb battery charger, but I came here to see if I could trick it by adding resistors or some type of simple logic. Are you familiar with the protocol it would use establish and confirm a connection with a computer?

--- End quote ---
"Adding resistors" is what a dumb charger already does, other than the basic 1A current level signaled by shorting the D+/D- lines.

I don't know the exact handshaking process, but you'd be getting into the nitty-gritty of USB signaling, which is decidedly non-trivial. When you plug a device in, the device is only allowed to draw 100mA of power initially. If it wants more, then it has to talk to the USB host (possibly even involving the driver; I'm quite unsure about this point), and request a higher power level (500mA in USB 1-2, up to 900mA in USB 3, and higher current and voltage in USB Power Delivery with USB-C). If declined, the device is not supposed to draw any extra power and the port may shut down if it tries anyway. If the device gets the OK, then it fully powers up and continues configuration.

USB is nothing close to what can be done with "simple logic", alas. Heck, even just looking at the signals requires very expensive oscilloscopes. (It's kinda crazy that a USB host IC that costs just a few bucks can decode the multi-GHz USB 3 signals, but visualizing them requires a scope worth more than a Tesla…)

It'd be infinitely simpler to just get a tiny USB host (like a Raspberry Pi or some dirt-cheap Android phone) that it can talk to.

Navigation

[0] Message Index

[#] Next page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod