Underlying hardware beneath virtual Com port - serial-port

I have a device connected to USB port via USB cable to my PC and in device Manager it says - > "XYZ corp Virtual COM port (COM A)"
Is this is same as Serial Com Port.?What is the underlying hardware under it both at device side and Host Side - a Uart or a USB or both at either end respectively?

It sounds like your USB device uses a driver that provides a serial port interface inside your computer. This means that other software can use the serial port APIs that Windows provides to connect to it and use it as a serial port. That software doesn't need to know the details of your USB device; it just needs to know about using serial ports in Windows. Windows ships with a driver that is often used to do this, and that driver is named usbser.sys. Your device might be using usbser.sys or it might be using some other driver.
The serial data is transferred via your computer's USB port and a USB cable. If you look at the signals on the USB cable, you will not see typical serial signals: you will see regular USB packets that just happen to be carrying that data needed for a serial port.
The USB device on the end of that cable might then translate that data into serial signals and act like a normal serial port, or that data might just be used directly inside the device. Without a link to the product in question, it is hard to tell you more than that.

Related

USB to USB serial communication from PC to PC

I am currently connecting 2 PCs using serial communication and at this time I am using a USB to Serial converter, then a serial cable, then another USB to Serial converter going into the other PC in order to get the communication sent and received.
Is there a way to program the USB ports as COM ports without these converters and still be able to transfer the serial data over the USB using software rather than hardware, thus eliminating the need for the conversions and rather have just a straight USB cable to USB cable connection?
Thanks!

Developing my own modem

I would like to develop my own modem for a custom communication network that will be detectable on the serial port by PC automatically. What I'm uncertain about is the protocol part of the AT commands and how to make it work seamlessly so that computer will detect the modem automatically.
I plan to use ftdi UART to USB converter to interface my microcontroller with the PC using standard serial interface. The PC will then use AT commands to communicate with the microcontroller that will in turn connect to another microcontroller over radio tranceiver and establish a two way serial connection over radio. The idea is that the PC on the other end will run PPPD and listen on it's own modem connection for incoming call and then bridge the connection with it's other internet interface that is connected to internet. The first computer will get it's own IP address using PPPD and will be connected to internet over this custom microcontroller based modem.
But how do I implement the communication protocol between my controller and PC? What commands do I absolutely need to implement? How do I make sure that the computer recognises my controller which is connected over ftdi usb to serial adapter as a functional modem?
Where can I find a speciffication of the minimum command set that is required of a modem?
In practice linux usually discovers a 3G modem automatically for example. Does that have to do with the actual USB identifier of the modem? Is it possible to have linux automatically discover an ordinary serial port modem? I'm thinking that the modem will be sending an AT idle ping repeatedly when it's plugged in so that linux should be able to detect it.

Implementing I2C slave with FT201XB via USB

I've been trying to test a FT201XQ USB-I2C breakout board: UMFT201XB-01, so I can connect it to a master device such as an Arduino and sniff what that device is sending through I2C.
To see the output of the slave device I have successfully configured a Virtual COM PORT by installing the D2XX drivers provided by ftdchip.com. I can open the serial port through puTTY and everything seems fine in that regard.
Then, i've loaded the "master_writer" example on my Arduino, which sends 1 byte at a time to an address (0x22 is specified in the UM201XB-01 datasheet as the default address).
Nothing seems to happen in the COM port that i've earlier opened. Do I need to configure/program the FTDI device in some way? In that case, how can I do it, in a general way?
UMFT201XB-01 board http://www.ftdichip.com/Support/Documents/DataSheets/Modules/DS_UMFT201_220_230XB.pdf
Thank you in advance, and sorry if this is a "noob" question : P

Activesync connection between two USB-host controllers

For a hobby project I wish to develop some stuff for a WinCE 6.0 device. Ideally, I would have an activesync connection to debug from Visual Studio. The OS appears to have all the prerequisites in place, but I'm not sure about the transport. What are my options?
The device has a USB port which can be used to connect e.g. flash drives for mp3 playback, so this seems to be a USB host port. Can I use this to obtain an activesync connection? I guess using a usb-to-serial cable on both pc and WinCE device could work. Or is there a RNDIS way perhaps?
If possible I rather not disassemble the unit, but if my chances of finding a USB client port or wired ethernet are nonzero I could consider that. Any thoughts?
You can not use USB host port for Activesync connection.
But if it is USB OTG (Both host and client) port, you can use activesync using USB OTG or USB Client functionality.
Your BSP should support USB Serial Client functionality (Search SYSGEN_USBFN_SERIAL sysgen variable in catalog items).
Also, your USB driver (lower level driver) should support USB Client functionality.
ActiveSync will work on a serial cable, so the idea of using an USB-to-serial adapter may work. But you need to have drivers for it in the OS image. There are some CDC drivers and FTDI provides drivers for their chips. You may be able to load them on the device, copying them using a USB thumbdrive and modifying the registry using a registry editor for windows CE, but that's not granted. Windows CE also supports RNDIS compatible USB to ethernet adapter but honestly I don't know if any device of this kind is currently available on the market. If your device has wi-fi connectivity you can skip using ActiveSync and debug over the network.

What kind of port is the USB port?

I am developing a serial port communication java-J2ME-J2SE application. There is a mobile phone and a computer ( running Windows XP ). These two machines are communicating through the phone mobile's cable. And the phone mobile's cable is a USB cable. So what is the type of the port : is it COM1 or something else ?
I looked the device manager and I found that the mobile phone ( Alcatel OT-806D ) is in port COM4. Here is a captured image of the device manager:
An USB port is a kind of serial port that computers and devices can use to communicate. It defines the connectors and cables, as well as the physical and link layer protocols that devices must use to communicate over USB. In this sense, it's similar to Ethernet, Firewire or other communication protocols.
At a physical level, USB is a serial protocol, meaning that bits are sent in a serial fashion. Old serial RS-232 ports (traditionally named COMx under Windows) are not related to modern USB architecture. Old serial ports used a simpler and slower communication protocol (RS-232) that was usually handled by a family of chips called UARTs, whereas USB communication requires more complex hardware.
So, the physical and link-layer characteristics of these two protocols are very different. While both are serial protocols, USB allows for several devices to share the same bus (traditional serial ports don't) and communication speed is much higher in USB. Error detection and correction, flow control and other data transfer concerns are better handled in USB.
COM ports are a Windows abstraction to represent any communication port. In other operating systems other names are used. In Linux, the COM1 port is represented by the device /dev/ttyS0.
Note that this is no more than an abstraction. It is possible (and often done) to use serial ports that are not using the traditional, physical, serial port. In fact, you can create operating system drivers that provide serial ports that are in fact communicating over Ethernet, USB, IP or any other communication layer. The COM port at operating system level is no more than an abstraction to represent a communications port.
Mobile phones offer a variety of services through their USB port. This often includes raw serial communication (which you can use in your application), but in many other cases the USB port provides other "profiles" (usb mass storage, headphones, or whatever). All those profiles are standarized so you can plug your phone to a computer and establish a "serial communication" channel, among other things, without having to code communication drivers for the computer or the phone.
So, to answer your question, no, an USB port is not a COM port. It is an USB port. You can use it for serial communications, but you can also use it for other things.
USB means Universal Serial Bus. Generally all os the USB connections on PC will be linked on the same bus. All devices connected to the bus are assigned virtual port numbers. These port numbers will change depending on what is connected to the bus.
However, you won't be communicating with the phone directly but with any driver that is installed for it, unless you're writing the driver itself.
Some phones are not controllable in any way, others may appear as a modem, because that is the functionality that their manufacturer has assigned them through the drive.
My current phone installs as a device in itself (for use with a manufacturers piece of software), a modem and a storage device.
Have a look here for some more information.
um, depends what you mean by "type of port". I think you want to know the name of the port, but what you really need to know is what protocol your phone will understand.
You need to know what protocol (if any) the phone can communicate with over USB. Just because you can connect the phone to a USB cable doesn't mean that you can control the phone. This depends on the phone. Not all phones are built to understand the same protocols.
Also, USB is a serial bus because it transmits data serially on a single line (as opposed to transmitting in parallel over multiple lines), but it doesn't (necessarily) use the same RS-232 protocol as a computer's serial port. If you had a RS-232 device connected to a USB port, then you would connect to it using COM1 (or COM2 or COM3, your operating system assigns this port name).

Resources