
I received an ezLCD01 2.7" color display in the mail last week and am now trying to figure out how to control it. The controller board has an Atmel ATMega128L that drives the display through high-level commands (e.g., line, text, put_bitmap) received on a serial (RS232) or USB port. My current setup connects to it via a 115200b serial connection.
Several options exist for serial port communication in C#. There are a number of commercial libraries which I did not try out. On the freebie side, a tutorial at devhood.com cover the basics of using a COM object from Visual Studio 6.0.
Another tutorial for C# mentions the System.IO.Ports package for .NET 2.0. This package will be available for Visual Studio .NET 2005 but is NOT part of the current 2003 version.
Finally, there is a Sourceforge project called SerialPortNet which provides the .NET 2.0 functionality for .NET 1.1. (The project also makes use of the NUnit unit-testing framework which I installed.) Compiling from the CVS sources was a snap and I was able to put together a simple test app that sends strings to COM1 in no time.
In Java, the javax.comm package supports serial I/O.
A third option would be to open /dev/ttyS0 using a gcc/Cygwin setup, at the cose of nice development environments.
To troubleshoot my connections I am using a trial version of Aggsoft's Adanced Serial Port Monitor which has a snooping mode.
Posted by Bjoern Hartmann at March 20, 2005 1:02 AM