Article View: comp.lang.basic.visual.3rdparty
Article #36VB5 Oncomm and Timer Question
From: GRAHAME DUKE
Date: Sun, 27 Sep 1998 00:00
Date: Sun, 27 Sep 1998 00:00
26 lines
1916 bytes
1916 bytes
I have a program which will interrigate a piece of hardware for inforamtion. The recieved data has no handshaking protocol. Here's the problem. I want to run a few lines of program on a button click), look at the Rx comm1 buffer. If empty, wait indefinatly. If something present, run the Oncomm_event for a time (about 1 or 2 secs) which will store each piece of data into a array. As the data stream lasts only a second or two, continue storing data. After 2 secs, go back to where I left off, run some more program, clear buffer and repeat. In other words, on button click, test Rx buffer. If charatcer in buffer, collect all characters recieved for 2 secs, Go back to program, reset buffer and repeat, Any ideas? Grahame. How can I, on a button click, let a program wait until the comm1 recieve buffer (which starts empty), wait until something arrives, then with the Oncomm event, collect all the information (and store them into a dimensioned variable) which
Technical Details
Message-ID:
<6urh44$npl$1@nclient3-gui.server.virgin.net>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10f5f9,9ea5c81679c8d790,start X-Google-Attributes: gid10f5f9,public X-Google-Thread: f5f6f,9ea5c81679c8d790,start X-Google-Attributes: gidf5f6f,public X-Google-Thread: 108062,9ea5c81679c8d790,start X-Google-Attributes: gid108062,public X-Google-Thread: 110e3b,9ea5c81679c8d790,start X-Google-Attributes: gid110e3b,public X-Google-Thread: 11629a,9ea5c81679c8d790,start X-Google-Attributes: gid11629a,public From: "GRAHAME DUKE" <grahame.d@virgin.net> Subject: VB5 Oncomm and Timer Question Date: 1998/09/27 Message-ID: <6urh44$npl$1@nclient3-gui.server.virgin.net> X-Deja-AN: 396103561 Organization: Virgin News Service X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 Newsgroups: comp.lang.basic.visual.3rdparty,comp.lang.basic.visual.misc,comp.lang.clipper.visual-objects,cz.comp.lang.basic.visual,microsoft.public.visualj.misc-tools