summaryrefslogtreecommitdiff
path: root/nuttx/configs/stm3210e-eval/src
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-08-02 01:12:16 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-08-02 01:12:16 +0000
commit78d83d991a664cbb4e55861d7935a3954506eb4d (patch)
tree1137af8110faf9b25a96046d270c2b7e2888a755 /nuttx/configs/stm3210e-eval/src
parentbae58be673c63bd01fc68dbfc5d44d66ab1e8070 (diff)
downloadpx4-nuttx-78d83d991a664cbb4e55861d7935a3954506eb4d.tar.gz
px4-nuttx-78d83d991a664cbb4e55861d7935a3954506eb4d.tar.bz2
px4-nuttx-78d83d991a664cbb4e55861d7935a3954506eb4d.zip
Add nxgl_splitline()
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3835 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs/stm3210e-eval/src')
-rwxr-xr-xnuttx/configs/stm3210e-eval/src/up_lcd.c26
1 files changed, 23 insertions, 3 deletions
diff --git a/nuttx/configs/stm3210e-eval/src/up_lcd.c b/nuttx/configs/stm3210e-eval/src/up_lcd.c
index a183a04cb..fccf680a5 100755
--- a/nuttx/configs/stm3210e-eval/src/up_lcd.c
+++ b/nuttx/configs/stm3210e-eval/src/up_lcd.c
@@ -33,7 +33,15 @@
* POSSIBILITY OF SUCH DAMAGE.
*
**************************************************************************************/
-
+/* This driver supports the following LCDs:
+ *
+ * 1. Ampire AM-240320LTNQW00H
+ * 2. Orise Tech SPFD5408B
+ * 3. RenesasSP R61580
+ *
+ * The driver dynamically selects the LCD based on the reported LCD ID value.
+ */
+
/**************************************************************************************
* Included Files
**************************************************************************************/
@@ -259,6 +267,11 @@
#define LCD_BL_TIMER_PERIOD 8999
+/* LCD IDs */
+
+#define SPFD5408B_ID 0x5408
+#define R61580_ID 0x1580
+
/* Debug ******************************************************************************/
#ifdef CONFIG_DEBUG_LCD
@@ -848,9 +861,16 @@ static int stm3210e_setcontrast(struct lcd_dev_s *dev, unsigned int contrast)
static inline void stm3210e_lcdinitialize(void)
{
- /* Check if the LCD is SPFD5408B Controller */
+ uint16_t id;
+
+ /* Check if the LCD is Orise Tech SPFD5408B Controller (or the compatible RenesasSP
+ * R61580).
+ */
+
+ id = stm3210e_readreg(LCD_REG_0);
+ lcddbg("ID: %04x\n", id);
- if (stm3210e_readreg(LCD_REG_0) == 0x5408)
+ if (id == SPFD5408B_ID || id == R61580_ID)
{
g_lcddev.spfd5408b = true;