So far I am a user of the existing libraries but didn't try myself to write one…
do you know where to download the source in order to understand it ?
I have to complain that either ks0108 or glcd library (if they're not the same) is pretty big in SRAM so hope two instances will work. Essentially like what floresta pointed out (the post), if you can, instantiate two GLCDs and with same data lines but different CS1 and CS2.
HelloI plan to control 2 graphic LCD (http://www.sparkfun.com/products/710) using the KS0108 Graphics LCD library (http://www.arduino.cc/playground/Code/GLCDks0108).The library assumes you use one port (A,B or C) to connect one LCD.I would like to know what I should modify in the library to use 2 LCDs?Do I need to duplicate the library changing all functions name to address LCD 1 or LCD 2 (e.g. GLCD.ClearScreen1() for LCD 1 and GLCD.ClearScreen2() for LCD 2) ? Or is there any more elegant way to do it?So far I am a user of the existing libraries but didn't try myself to write one…Thank you for your support.Raoul.Note: I am using a Mega 2560
If you don't mind using an extra chip per display, you could have a lot of them. I did an article about driving graphical LCD displays using I2C or SPI here:http://www.gammon.com.au/forum/?id=10940With I2C you could potentially have 8 displays (since you share the same 2 pins: SDA/SCL) and you can configure the chip to have up to 8 addresses. With SPI you can have as many displays as you can spare SS pins for (3 wires for MOSI/MISO/SCK plus one extra one for SS per display).With a Mega you might not need to bother because you have some spare pins, but it is an idea.
Please enter a valid email to subscribe
We need to confirm your email address.
To complete the subscription, please click the link in the
email we just sent you.
Thank you for subscribing!
via Egeo 16