I have an application that sends data over various communications mechanisms (ie: Serial, Named Pipes, Tcp, etc). In each case though, the application simply allows the user to read and/or write data to the data source using the communication mechanism.
Ex:
Serial.Read(7, 1000, 1); # Read 7 bytes from the serial port. Wait 1000 ms for those 7 bytes. Allow only 1 retry.
Tcp.Write(00-11-22-33-44-55, 1000, 2); # Write the list of bytes to the configured tcp port. Allow 1000 ms maximum for the write to take place and 2 retries before failing and ending the script.
My problem is, sometimes the script can be quite long, and their can be a lot of bytes read. Tcp can sometimes read up to 4096 bytes each read. Displaying these bytes to the user takes time, and the longer those bytes take to display, the less 'real-time' the script is run.
I require only read only. I'll never be changing the data once it's displayed to the user. Has anyone done something similar with good results?
I'm looking for as near 'real-time' display of data as possible. Hopefully being able to display as many bytes as I require within milliseconds, or perhaps a way of optimizing an existing control so that if a script runs and generates 100,000 lines of data overnight, the control will not slow down, and continue to update in near real-time.
I've tried a text box, listview, and datagridview with mixed results. In the end, they all fell short somewhere.