How to convert a PC into a USB device

I am working on an embedded PC application and would like to turn my mini-computer into a USB device.  This means that it can be plugged into another computer and then recognized as a device - just like a printer is automatically recognized.

I run custom software on the mini-computer and want to output a string from the mini-computer to another computer via the USB cable.  The other computer will also have a custom software program which is able to read the string coming from the USB cable.

My question is: is there some type of off the shelf product which I can use with the mini-computer to easily do this?  If so, is there a brand which you would recommend?  I would like it as easy as possible without needing to create custom drivers - if possible.

The software in which the device needs to interface with is VB6 as well as VB.NET.

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Ph0en1x3College InstructorCommented:
This is easier said then done...    You need a PC USB driver and some kind of app interface on the master device.    I recently did a custom driver that connected a PC with an app (to send the string to the USB stack) and an embedded slave device which received the command and did something....      It was more work then I expected.      USB is different then serial (rx/tx) because the slave "can't" advertise that it needs to send information, the master has to go into USB read mode and read a specific amt of characters..     This site was a life saver as microsoft staff responded to my tough questions...
If the USB port is not an OTG , you also need to modify the hardware - slave devices needs a pullup resistor that master devices doesn't have.
Leaping-DogAuthor Commented:
I was hoping that there was an off the shelf product black box in which you plug into the slave device's USB port to turn it into a USB device.

 Then you can plug your other computer into the black box's female USB port, in order for your second computer to communicate with your slave computer.

I thought I saw a product like this, which included all drivers and stuff, but the search terms are so common, I am finding it difficult to find any relevant off the shelf products.

Also, what I am attempting to do should be trivial, at least it was using RS-232.  I just need to send a string from one computer to another, as well as have the USB device recognition.  Should be such a common task that someone commercialized a solution - I hope?

I just can't imagine being forced to engineer a costly solution for such a trivial and commonly needed task.

Please share your thoughts...
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

You could use an USB to serial converter with the USB side to the PC and the serial cable on the other side.
Or you can use two usb to serial cables.
This is the easiest solution.
I know nothing about the box you told about, but I never had the needs to search it.
Leaping-DogAuthor Commented:
Interesting ideas HappyCactus.

What I need to construct is a peripheral device (sort of like a printer) which has an embedded mini-pc and has a female USB port.  Then you just plug in another computer into the new "device" and it automatically recognizes it and using software drivers a VB.Net program can then read the data stream coming from the new device.

Can your solution which you mentioned above achieve this?
BTW, first check that your embedded device doesn't already have a OTG usb port - if it has one, it can be used as an USB device. You only need the drivers.

Regarding your problem, with a pair of usb-to-serial converter you can "simulate" the plug-in in two ways:
First way: use the serial signals - DTR/DCD etc...
Second way: use a software protocol like this one:
Every time the USB serial device is plugged, start a program that periodically send a "wake-up" packet to the serial. When the device receive a "wake-up" packet, it sends a response and establish the connection.
After every data packet, wait for an ACK. When you do not receive the ACK, send a "goodbye" packet and put the device in the "wake-up" state. When a side receive a "goodbye" packet, put it on the wake-yp state.
This way you can simulate by software the connection and disconnection of the devices.

The easiest and most effective way is the first one.
Leaping-DogAuthor Commented:
The mini-pc does not have a  OTG usb port, just a regular USB ports.  So your first solution will not work.

Thank you very much for your second solution, but I don't think it will work for me.  I can not use a work around solution, I need the absolute standard practice solution for this.
Wait, the "first" solution - not the OTG, but the Hardware handshake signals - ARE a standard solution, because they was used on the very old, good days to detect a connected modem (DCE) . In facts, when you open a serial port, the DTR signal goes automatically up.
Leaping-DogAuthor Commented:
Cactus, I know what you are saying.  Its just that there must be standard USB protocol to achieve what I need.  This is a job for the US military, and I can not be using work around to get it to work, even though it is possible.  I am sure there is standard protocol which will work, its just a matter of being pointed in right direction.
Ph0en1x3College InstructorCommented:
Most PC and mini-pc devices with USB ports have drivers available from the manufacturer.    What it sounds like you are asking for is an user app that gives you the ability to transfer data???  If so check out   I took her c# application and modified it to work my my custom usb driver.  

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Leaping-Dog, really US army uses USB devices?? yep...

So: does your mini-pc have some expansion slot (PCI/PCIExpress/PCMCIA) ? Can you eventually develop some custom electronics?
Leaping-DogAuthor Commented:
Can anyone help me with this question???
Leaping-DogAuthor Commented:
Ok solution
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Embedded Hardware

From novice to tech pro — start learning today.