I guess it is better to start at the beginning. 

I have been using SerialNG (free) for many years sending and receiving data to 
CNC machines. 

Now I'm doing something different and things just don't work the same. 

I'm sending 3 bytes of data from a micro. If I send data every 500 ms, I get a 
3 byte string which I decode.   SerialPortNG.NextClusterSize is triggered 
whenever data is received. If data is received every 500 ms I get valid data. 
If I speed up the micro to every 100 ms, it all changes. I start to get 2 or 3 
blocks of data coming though at one time. 

Bing - Light just went on. My array for receiving the data is only 4 long. The 
data is now is a lot longer.  Access Violation _"array exceeded" would have 
been helpful.

for i:=1 to length(sRaw) do
     try iData[i]:= byte(sRaw[i])

Never the less - Is this a Delphi, Windows or serial comms issue. Why at 500 ms 
do I get 3 bytes and 100ms get 4+ bytes ? Is the delay between the USART 
receiving data, setting a flag, signalling Delphi to execute a read longer than 
100ms ?

Anyone with any help please reply or call 03 3237449

Cheers Wallace
NZ Borland Developers Group - Delphi mailing list
Post: delphi@delphi.org.nz
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to delphi-requ...@delphi.org.nz with Subject: 

Reply via email to