Path: chuka.playstation.co.uk!news1.scei.co.jp!usenet From: hashimoto Newsgroups: playstation.ny.program.labo Subject: =?iso-2022-jp?B?GyRCREw/LiRLJEQkJCRGGyhK?= Date: Sat, 31 Jan 1998 21:51:53 +0900 Organization: PlayStation Net Yarouze Lines: 84 Message-ID: <34D31E69.2769@syshp.tm.chiba-u.ac.jp> NNTP-Posting-Host: 133.82.179.247 Mime-Version: 1.0 Content-Type: text/plain; charset=iso-2022-jp Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 3.01 [ja] (Win95; I) CC: hasimoto@syshp.tm.chiba-u.ac.jp こんにちは,橋本と申します. 私は今,PCとPSで通信を行うプログラムを作っているのですが, そのプログラムで9バイト以上のデータをPCからPSに送ると, PSが通信を行わなくなるという問題に悩んでいます. どなたか詳しい方がいましたら教えていただけないでしょうか. PC:Windows95 Borland C++ Builder にて開発 CreateFile("COM1", GENERIC_READ | GENERIC_WRITE, 0, NULL, OPEN_EXISTING, NULL, NULL); で,ポートオープン 設定は (siocons for Windows95を参照しました.) dcb.fBinary = TRUE; dcb.fParity = FALSE; dcb.fOutxCtsFlow = TRUE; dcb.fOutxDsrFlow = FALSE; dcb.fDsrSensitivity = FALSE; dcb.fTXContinueOnXoff = TRUE; dcb.fOutX = FALSE; dcb.fInX = FALSE; dcb.fErrorChar = FALSE; dcb.fNull = TRUE; dcb.fRtsControl = RTS_CONTROL_TOGGLE; dcb.fAbortOnError = TRUE; dcb.ByteSize = 8; dcb.Parity = NOPARITY; dcb.StopBits = ONESTOPBIT; CommTimeouts.ReadIntervalTimeout=MAXDWORD; CommTimeouts.ReadTotalTimeoutMultiplier=0; CommTimeouts.ReadTotalTimeoutConstant=0; CommTimeouts.WriteTotalTimeoutMultiplier=10; CommTimeouts.WriteTotalTimeoutConstant=10; 書き込みは WriteFile を使い, void __fastcall TForm1::SerialWrite(int CommNo,char *buf, int length) { int i,j; DWORD dwbuf; for( i=0; i