Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: Reading serial port from command line.

24 Dec 2014   #1

Windows 7 Professional 64 bit
Reading serial port from command line.

Is there a way to read a line of data from the serial port from DOS/NT COMMAND. The only method I've found mentioned in my web searches is the "TYPE" command. But I've not been able to make it work. If I enter "type com1", it seems to begin reading the port, but no matter what control characters I send along with the data, nothing prints to the screen until the buffer is completely full, (I'm any case, I have to send a bunch of data before it prints to the screen). And even when it does return data to the screen, it never exits back to the command prompt...just keeps reading the port. Am I missing some parameters or switches? Or is there a better command to use for this?

My System SpecsSystem Spec
24 Dec 2014   #2

Windows 7 ultimate x64


Welcome to SF. Read this article..Might be of some help.
My System SpecsSystem Spec
24 Dec 2014   #3

Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan

Hi 777subob,

With little searching I have come across this Stackoverflow question and in the question the person uses the copy command to capture output from a serial port. So there is another method, though I don't think using copy will be any better of an option.

Note: COPY COM1 CON is the same as TYPE COM1

When done capturing data, to stop the copy/type command from endlessly attempting to receive further output from the serial port, the device on the over end should send a Ctrl Z control character. (It's Unicode codepoint integer value being 26.) This stops either command from running and returns to the interactive prompt. You can manually press Ctrl Z.

No parameter or switch is missing. There are no built-in/'better' commands readily available that address this task; there is no easy way to read data from a serial port via the command prompt.
My System SpecsSystem Spec


 Reading serial port from command line.

Thread Tools

Similar help and support threads
Thread Forum
Serial Port Not Connecting
Hi, I'm trying to use a serial port on my PC, the GB board (H97-D3H) has a COM port header and I've used a back panel connector with cable to connect to this. I checked and serial port in enabled in BIOS. The driver is the Microsoft driver serial.sys and claims it is working. I believe the...
BSOD using USB serial port
Sometimes during the debugging of a blackbox via RS-232, my PC crashes with a BSOD. The serial port is working at 9600bps 8N1. Following the instructions in i attached here the related zip file....
BSOD Help and Support
PCI Serial Port?H
Hi, I just installed Windows 7 and updated all my drivers. I am missing two drivers, and I don't know what they are: PCI Serial Port PCI Simple Communication Controller What exactly are these? I own a Lenovo X200 Tablet. Any ideas where I can find the drivers for these two things? ...
PCI Serial Port issues
LENOVO 6072BKU ThinkCentre M57 System Serial Number: LKRGBVB Enclosure Type: Desktop Processor a Main Circuit Board b 2.20 gigahertz Intel Core2 Duo 64 kilobyte primary memory cache 2048 kilobyte secondary memory cache 64-bit ready Multi-core (2 total) Not hyper-threaded Board:...
USB serial port help
So im going to try to explain this as well as i can. I am running a windows 7 and I have a radio I would like to program. The main issue is that the program needed to program it is for DOS. So I installed DOS 6.22 On my VMWare virtual machine (VMware Workstation 8.0.0) and ran the program. Now the...
Hardware & Devices

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 23:08.
Twitter Facebook Google+