Greatings
I have some application qhen use the comm.c:TransmitCommChar function, but this function are not implemented.
anybody have one ideia to me go around this problem...?
thaks and sorry per my litle english
Marcelo Welter
Hi Marcelo,
Does this help things? It's not perfect, but it should be better than nothing...
Mike
Marcelo Welter wrote:
Greatings
I have some application qhen use the comm.c:TransmitCommChar function, but this function are not implemented.
anybody have one ideia to me go around this problem...?
thaks and sorry per my litle english
Marcelo Welter
Index: dlls/kernel/comm.c =================================================================== RCS file: /home/wine/wine/dlls/kernel/comm.c,v retrieving revision 1.57 diff -u -r1.57 comm.c --- dlls/kernel/comm.c 22 Apr 2002 22:32:13 -0000 1.57 +++ dlls/kernel/comm.c 23 Apr 2002 23:24:45 -0000 @@ -1435,9 +1435,23 @@ HANDLE hComm, /* [in] The communication device in need of a command character. */ CHAR chTransmit) /* [in] The character to transmit. */ { - FIXME("(%x,'%c'), stub ! Use win32 handle!\n",hComm,chTransmit); - return TRUE; + BOOL r = FALSE; + int fd; + + WARN("(%x,'%c') not perfect!\n",hComm,chTransmit); + + fd = FILE_GetUnixHandle( hComm, GENERIC_READ ); + if ( fd < 0 ) + SetLastError ( ERROR_INVALID_PARAMETER ); + else + { + r = (1 == write(fd, &chTransmit, 1)); + close(fd); + } + + return r; } +
/***************************************************************************** * GetCommTimeouts (KERNEL32.@)
On April 23, 2002 07:26 pm, Mike McCormack wrote:
Hi Marcelo,
Does this help things? It's not perfect, but it should be better than nothing...
A comment saying why it's not perfect would be nice... ;)
Hi Dimi,
It's not perfect because TransmitCommChar should bypass the Linux kernel's internal transmit buffer as well as any pending overlapped operations. The characters should be treated the same way as a flow control character.
Unfortunately, that probably requires a hack in the serial driver. Actually I should get all these hacks together (including the one for polling on RTS,DTR,CD,RI deltas) and submit a patch for Linux 2.5.*... in my copious amounts of spare time ;-)
Mike
Dimitrie O. Paun wrote:
On April 23, 2002 07:26 pm, Mike McCormack wrote:
Hi Marcelo,
Does this help things? It's not perfect, but it should be better than nothing...
A comment saying why it's not perfect would be nice... ;)
On April 24, 2002 10:58 am, Mike McCormack wrote:
Unfortunately, that probably requires a hack in the serial driver. Actually I should get all these hacks together (including the one for polling on RTS,DTR,CD,RI deltas) and submit a patch for Linux 2.5.*... in my copious amounts of spare time ;-)
That'd be real nice, as there was much talk in modifying the serial driver some time ago. It also looks like the kernel people are willing to help out Wine. Since we've missed 2.4, maybe we can get them in in time for 2.6 :)
If i send this char to the end of current sended string..
something like writefile
i need a way to send this char to serial, and i can't call writefile directly
anybody help me...????
I have a serial printer used in Point-of-Sale and the factory software needs this F$@*# function.
thanks
Marcelo
Em Qua 24 Abr 2002 12:10, vocĂȘ escreceu:
On April 24, 2002 10:58 am, Mike McCormack wrote:
Unfortunately, that probably requires a hack in the serial driver. Actually I should get all these hacks together (including the one for polling on RTS,DTR,CD,RI deltas) and submit a patch for Linux 2.5.*... in my copious amounts of spare time ;-)
That'd be real nice, as there was much talk in modifying the serial driver some time ago. It also looks like the kernel people are willing to help out Wine. Since we've missed 2.4, maybe we can get them in in time for 2.6 :)
Hi Marcelo,
1. apply my patch 2. test the program 3. if it doesn't work, send me marcelo.log.gz from
wine -debugmsg +file,+comm,+server app.exe > marcelo.log
obrigado,
Mike
Marcelo Welter wrote:
If i send this char to the end of current sended string..
something like writefile
i need a way to send this char to serial, and i can't call writefile directly
anybody help me...????
I have a serial printer used in Point-of-Sale and the factory software needs this F$@*# function.
thanks
Marcelo