problem with communication at midnight

problem with communication at midnight

Postby mtajkov » Sat Jul 21, 2012 3:58 am

do my port through which communication with the controller (ADAM 4000). several times per second the controller sends a request (WRITECOMM (nCommIzl, "$ 02" + "6" + chr (13))) I get a response from him

function BytesAtPort( nCommIzl )

local cBufIzl := Replicate(Chr(255),1024)

ReadComm( nCommIzl, @cBufIzl ) // <<<<---- program will lock here

cBufIzl:=StrTran(cBufIzl,Chr(255),'')

if mCont=.t.
LogFile( dF, {"Response controller: " + cBufIzl } )
endif

.
.
.
.



log file:


.
.
.
.
07/19/12 23:59:58: Response controller:! 001F00
07/19/12 23:59:58: Response controller:! 001F00
07/19/12 23:59:58: Response controller:! 001F00
07/19/12 23:59:58: Response controller:! 001F00
07/19/12 23:59:59: Response controller:! 001F00
07/19/12 23:59:59: Response controller:! 001F00
07/19/12 23:59:59: Response controller:! 001F00
07/19/12 23:59:59: Response controller:! 001F00
07/19/12 23:59:59: Response controller:! 001F00

The problem is that communication stops at 23:59:59. Why?

Note that the controller does not have its clock!
Best regards
Milos

[ FWH 21.11 ] [ xHarbour 1.2.3 Intl. (SimpLex) (Build 20150603) ]
mtajkov
 
Posts: 130
Joined: Sun Mar 08, 2009 4:33 pm

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 111 guests