Well, one quick & dirty way to fix the name is to use a binary editor
and replace 'COM1' to 'COM2'.
'bvi' is suchs a program, and it is available for Linux & m$win.
Regards,
Ed
I'm pulling my hair out... trying to get an old PC
with two COM
ports to work with VTServer.
Setup: WinXP, AMD K6/300 CPU. Serial mouse is plugged into the
DE-9 connector and it's COM1. There is a DB-25 connector on COM2.
I can use MS-DOS COPY/B to send binary files out the COM2 port, so
I know COM2 works.
Unfortunately, after examining the C source code of VTserver, it
appears that it is hard-coded to use COM1 only. The comments are
interesting ;)
void open_port()
{
#ifdef _MSC_VER
/* The following is sort of like APL. If I have to explain it to you,
you don't deserve to know. */
/* Actually, I copied most of it from the examples, and I don't
understand it that well myself */
DCB dcb;
struct _COMMTIMEOUTS TO = {MAXDWORD,MAXDWORD,1,2,1000}; /* NOTE --
timeouts are hard wired for 9600 baud or higher */
fprintf(stderr,"Opening port %s .... ", port); fflush(stderr);
portfd =
CreateFile("COM1:",GENERIC_READ|GENERIC_WRITE,0,0,OPEN_EXISTING,FILE_FLAG_OVERLAPPED,0);
if(portfd == INVALID_HANDLE_VALUE)
{
fprintf(stderr, "can't open COM1:");
exit(1);
}
Not surprisingly, even when using an initialization line (in the
.vtrc setup file) of MODE COM2:19200,n,8,1 which does setup the
COM2 port properly, VTserver then outputs to the console:
"Opening port COM2:.... can't open COM1:"
Aaarrrgh!!!
I CANNOT get WinXP and this particular motherboard/BIOS to put the
damn mouse on COM2 so I can use COM1. IIRC I encountered this
problem years ago when last using VTserver, but that was on a
different and even older Win98 PC, and finally did manage to put
the mouse on the other port.
So the only other fix is to recompile VTserver to use port 2, and
I don't even think I have a C compiler let alone any experience
using it. Can someone *please* patch VTserver so I can use COM2
instead?
thanks for any help!
-Charles