summaryrefslogtreecommitdiff
path: root/nuttx/configs/open1788
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2013-03-26 20:06:53 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2013-03-26 20:06:53 +0000
commit7dd1e8bf754ae9e5ccef8441877a53faa50d5bc2 (patch)
treee6ee32c654a56fcc0b89607abcc7f422d85947a0 /nuttx/configs/open1788
parent5e03aead9c9e4b44148a651952dfc09851927106 (diff)
downloadpx4-nuttx-7dd1e8bf754ae9e5ccef8441877a53faa50d5bc2.tar.gz
px4-nuttx-7dd1e8bf754ae9e5ccef8441877a53faa50d5bc2.tar.bz2
px4-nuttx-7dd1e8bf754ae9e5ccef8441877a53faa50d5bc2.zip
LPC17 LCD driver is code complete and in need of testing
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5788 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs/open1788')
-rwxr-xr-xnuttx/configs/open1788/knsh/defconfig2
-rw-r--r--nuttx/configs/open1788/nsh/defconfig2
-rw-r--r--nuttx/configs/open1788/src/lpc17_boardinitialize.c15
-rw-r--r--nuttx/configs/open1788/src/open1788.h5
4 files changed, 22 insertions, 2 deletions
diff --git a/nuttx/configs/open1788/knsh/defconfig b/nuttx/configs/open1788/knsh/defconfig
index 291740f8e..9fef87f5b 100755
--- a/nuttx/configs/open1788/knsh/defconfig
+++ b/nuttx/configs/open1788/knsh/defconfig
@@ -191,7 +191,7 @@ CONFIG_LPC17_GPDMA=y
#
# SDIO Configuration
#
-# CONFIG_SDIO_DMA is not defined
+# CONFIG_SDIO_DMA is not set
# CONFIG_SDIO_WIDTH_D1_ONLY is not set
#
diff --git a/nuttx/configs/open1788/nsh/defconfig b/nuttx/configs/open1788/nsh/defconfig
index 27ae85829..03c7a22b9 100644
--- a/nuttx/configs/open1788/nsh/defconfig
+++ b/nuttx/configs/open1788/nsh/defconfig
@@ -185,7 +185,7 @@ CONFIG_LPC17_GPDMA=y
#
# SDIO Configuration
#
-# CONFIG_SDIO_DMA is not defined
+# CONFIG_SDIO_DMA is not set
# CONFIG_SDIO_WIDTH_D1_ONLY is not set
#
diff --git a/nuttx/configs/open1788/src/lpc17_boardinitialize.c b/nuttx/configs/open1788/src/lpc17_boardinitialize.c
index ac0417a65..a16f83024 100644
--- a/nuttx/configs/open1788/src/lpc17_boardinitialize.c
+++ b/nuttx/configs/open1788/src/lpc17_boardinitialize.c
@@ -48,6 +48,7 @@
#include "up_internal.h"
#include "lpc17_emc.h"
+#include "lpc17_gpio.h"
#include "open1788.h"
@@ -106,6 +107,14 @@ void lpc17_boardinitialize(void)
#ifdef CONFIG_ARCH_LEDS
up_ledinit();
#endif
+
+ /* Enable the LCD backlight (unless we can defer this to a later
+ * initialization phase.
+ */
+
+#if defined(CONFIG_LPC17_LCD) && !defined(CONFIG_BOARD_INITIALIZE)
+ lpc17_configgpio(GPIO_LCD_BL);
+#endif
}
/****************************************************************************
@@ -124,6 +133,12 @@ void lpc17_boardinitialize(void)
#ifdef CONFIG_BOARD_INITIALIZE
void board_initialize(void)
{
+ /* Enable the LCD backlight */
+
+#ifdef CONFIG_LPC17_LCD
+ lpc17_configgpio(GPIO_LCD_BL);
+#endif
+
/* Perform NSH initialization here instead of from the NSH. This
* alternative NSH initialization is necessary when NSH is ran in user-space
* but the initialization function must run in kernel space.
diff --git a/nuttx/configs/open1788/src/open1788.h b/nuttx/configs/open1788/src/open1788.h
index 8078fe9c5..ccac52db4 100644
--- a/nuttx/configs/open1788/src/open1788.h
+++ b/nuttx/configs/open1788/src/open1788.h
@@ -111,6 +111,11 @@
#define GPIO_SD_CD (GPIO_INTBOTH | GPIO_PULLUP | GPIO_PORT0 | GPIO_PIN13)
+/* LCD ******************************************************************************/
+/* Backlight enable, P2[1]. Initial state is ON */
+
+#define GPIO_LCD_BL (GPIO_OUTPUT | GPIO_VALUE_ONE | GPIO_PORT2 | GPIO_PIN1)
+
/************************************************************************************
* Public Types
************************************************************************************/