Re: [fpc-pascal] Reading Serial Hex Data

2020-12-28 Thread José Mejuto via fpc-pascal
El 28/12/2020 a las 2:02, James Richters via fpc-pascal escribió: I think I figured out why my writeln's are causing an issue.. they are introducing a delay between the SerWrite and SerRead... and the device I am reading is timing out and sending it's response a second time. Hello, None of

Re: [fpc-pascal] Reading Serial Hex Data

2020-12-28 Thread Bo Berglund via fpc-pascal
On Mon, 28 Dec 2020 14:12:02 +0100, Jean SUZINEAU via fpc-pascal wrote: >Le 28/12/2020 à 13:16, Bo Berglund via fpc-pascal a écrit : >> Synchronize(CallEvent); //Supply received data in FBuffer to >> caller > >You are using TThread.Synchronize. > >In a console app, it's likely that

Re: [fpc-pascal] Reading Serial Hex Data

2020-12-28 Thread Jean SUZINEAU via fpc-pascal
Le 28/12/2020 à 13:16, Bo Berglund via fpc-pascal a écrit : Synchronize(CallEvent); //Supply received data in FBuffer to caller You are using TThread.Synchronize. In a console app, it's likely that somewhere else in your main thread you'll need to call regularly

Re: [fpc-pascal] Reading Serial Hex Data

2020-12-28 Thread Bo Berglund via fpc-pascal
On Sun, 27 Dec 2020 18:20:32 -0500, James Richters via fpc-pascal wrote: >>On Sun, 27 Dec 2020 10:47:59 -0500, James Richters via fpc-pascal >> wrote: >> >>>I'm trying to figure out how to read a packet of HEX Bytes of an >>>unknown length that have no specific termination character over a

Re: [fpc-pascal] Reading Serial Hex Data

2020-12-28 Thread Marco van de Voort via fpc-pascal
Op 12/27/2020 om 4:47 PM schreef James Richters via fpc-pascal: I'm trying to figure out how to read a packet of HEX Bytes of an unknown length that have no specific termination character over a serial port as efficiently as practical. The packet ends when there is just no more data to read. I