Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DOS Commands 1

Status
Not open for further replies.

acewarlock

Technical User
Sep 16, 2002
9,370
US
It's been more than 20 years since I used DOS Commands. What I want to do is hook a serial port output from a phone system to a PC COM1 port and creat a file and capture all the info that come out of the phone system. I kind of remember there was somthing like COM1,9600,8,n,1 for the port on the PC, but like I said it's beeen a long time.
 
What OS? I don't know that this would be possible through a batch file on a windows box. I may be wrong though. I'll look into it if I get a chance.

[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
 
I used to use procomm for this sort of thing.

You can set the baud rate etc. using the mode command, but generally you'll need some sort of program to read the serial port.

And one that uses interrupts to get any sort of speed.
 
I use Procomm on my computer, but this is for a laptop in the phone room and I just want to capture CRD to it to show the Boss how it works, but they don't want to spring for the cost of Procomm for a test.
 
PS This is a Win2000. I was going to use CMD mode to get to the DOS commands.
 
Did you mean to use QBasic such as in this?

Code:
CLS
Term$ = ""
CPort& = 1
COM(1) ON
PRINT "Press any key to end program"
INPUT "Press <RETURN> to start", Test$
PRINT
OPEN "com1:9600,n,8,1" FOR INPUT AS #11
OPEN "myfile.txt" FOR OUTPUT AS #10
DO
ON COM(1) GOSUB RiteIO
LOOP WHILE INKEY$ = ""
COM(1) OFF
PRINT
PRINT "Test done"
CLOSE
END

RiteIO:
    INPUT #11, CPort&
    PRINT #10, STR$(CPort&)
    PRINT STR$(CPort&)
RETURN

PS: It's just an example. I haven't tried this.



--> It's a bird! It's a plane! No, it's an OS update patch! Ahh!! <--
 
MiggyD that's what I was looking for. Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top