Display text on LCD displays (even on multiple ones). Allow to create windows (frames) on display, and to combine them (split, add, duplicate, scroll). See http://mbed.org/users/hlipka/notebook/lcdwindow/ for more information.
Diff: dogm_spi.cpp
- Revision:
- 9:2fe93daa2106
- Parent:
- 3:e5d5e2fe4bf6
--- a/dogm_spi.cpp Mon Jan 10 22:57:59 2011 +0000 +++ b/dogm_spi.cpp Tue Feb 22 22:57:44 2011 +0000 @@ -50,7 +50,8 @@ void DogmLCDSPI::character(int column, int row, int c) { int address=(row)*0x40+(column); - _guard->take(); + if (!_guard->take()) + return; sendCmd((char)address|0x80); wait_ms(1); sendData(c); @@ -61,7 +62,8 @@ void DogmLCDSPI::writeText(const unsigned int column, const unsigned int row, const char text[]) { int address=(row)*0x40+(column); - _guard->take(); + if (!_guard->take()) + return; sendCmd((char)address|0x80); wait_ms(1); @@ -77,7 +79,8 @@ void DogmLCDSPI::clear() { - _guard->take(); + if (!_guard->take()) + return; sendCmd(1); _guard->release(); }