[Lazarus] Reading and writing TMemoryStream in events?

Paul Breneman list2010 at BrenemanLabs.com
Mon Nov 15 04:55:41 CET 2010


Bo Berglund wrote:
> On Tue, 09 Nov 2010 08:45:48 -0500, Paul Breneman
> <list2010 at BrenemanLabs.com> wrote:
...
>> It is a little hard to explain since my Comm DataModule has 2200 lines 
>> with input and output threads and a TThreadList for each, and that 
>> DataModule is created by another thread with message processing.  The 
>> same unit works with AsyncPro in Windows (Delphi) and SynaSer in Linux 
>> (Free Pascal and fpGUI for GUI programs).  There are console and GUI 
>> programs in each OS.
> 
> Did you do conditionals in the code to mask out AsyncPro in Linux and
> SynaSer on Windows?

Yes I use conditionals.  Isn't too much of a mess.

...
> I took your advice on the ARM based dev board with touch screen, which
> is now sitting on my desk. Just have to get my code right and then try
> to push it onto this little gadget. Hope it will work OK for my
> purposes as a front-end to the DA system.

Technologic Systems has been a good supplier for a long time for one of 
my clients so I'm happy to recommend them.

...
> BTW I see you mention AsyncPro, is it ported to FPC for multi-platform
> use? Just curious, but I won't use it here because of the unneeded
> complexity of that piece of software...

I doubt AsyncPro will get ported, but someone on this list said they 
might duplicate all the top-level API so that might work.

> Instead I will package the SdpoSerial and my CommBuf class together in
> a communications handler class that understands the actual protocol of
> the DA system. Then I will move up the ladder to the application and
> start using it to do actual comm stuff.

SdpoSerial sounds interesting and I need to check it out more.

> I am still at the comm handler class stage, though. Soon reaching the
> stage where I can do actual tests...

Please let me know how things work out.




More information about the Lazarus mailing list