summaryrefslogtreecommitdiff
path: root/nuttx/drivers/lcd/skeleton.c
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2010-05-11 03:55:28 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2010-05-11 03:55:28 +0000
commit708a2202668c666ea0dc430d2e395e6bf6203b12 (patch)
treee57b17b6c060cebc47ccb85d1c666b0dad6e64d3 /nuttx/drivers/lcd/skeleton.c
parent9087e891c87e6ea92b2f6c290164630fb59fea60 (diff)
downloadpx4-nuttx-708a2202668c666ea0dc430d2e395e6bf6203b12.tar.gz
px4-nuttx-708a2202668c666ea0dc430d2e395e6bf6203b12.tar.bz2
px4-nuttx-708a2202668c666ea0dc430d2e395e6bf6203b12.zip
Add skeleton of P14201 driver
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2664 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/drivers/lcd/skeleton.c')
-rwxr-xr-xnuttx/drivers/lcd/skeleton.c53
1 files changed, 10 insertions, 43 deletions
diff --git a/nuttx/drivers/lcd/skeleton.c b/nuttx/drivers/lcd/skeleton.c
index b42d7f869..15c3739cd 100755
--- a/nuttx/drivers/lcd/skeleton.c
+++ b/nuttx/drivers/lcd/skeleton.c
@@ -47,10 +47,9 @@
#include <debug.h>
#include <nuttx/arch.h>
+#include <nuttx/spi.h>
#include <nuttx/lcd.h>
-#include <arch/irq.h>
-
#include "up_arch.h"
/**************************************************************************************
@@ -153,7 +152,7 @@ static int skel_setcontrast(struct lcd_dev_s *dev, unsigned int contrast);
/* This is working memory allocated by the LCD driver for each LCD device
* and for each color plane. This memory will hold one raster line of data.
- * The size of the allocated run buffer must therefor be at least
+ * The size of the allocated run buffer must therefore be at least
* (bpp * xres / 8). Actual alignment of the buffer must conform to the
* bitwidth of the underlying pixel type.
*
@@ -236,7 +235,7 @@ static int skel_putrun(fb_coord_t row, fb_coord_t col, FAR const uint8_t *buffer
/* Set up to write the run. */
/* Write the run to GRAM. */
-
+#warning "Missing logic"
return OK;
}
@@ -262,11 +261,11 @@ static int skel_getrun(fb_coord_t row, fb_coord_t col, FAR uint8_t *buffer,
gvdbg("row: %d col: %d npixels: %d\n", row, col, npixels);
DEBUGASSERT(buffer && ((uintptr_t)buffer & 1) == 0);
- /* Set up to read the run */
+ /* When the SPI interfacee is used, the SD1329 controller does not support reading
+ * from GDDRAM.
+ */
- /* Read the run from GRAM. */
-
- return OK;
+ return -ENOSYS;
}
/**************************************************************************************
@@ -374,7 +373,7 @@ static int skel_setcontrast(struct lcd_dev_s *dev, unsigned int contrast)
**************************************************************************************/
/**************************************************************************************
- * Name: up_lcdinitialize
+ * Name: up_oledinitialize
*
* Description:
* Initialize the LCD video hardware. The initial state of the LCD is fully
@@ -383,47 +382,15 @@ static int skel_setcontrast(struct lcd_dev_s *dev, unsigned int contrast)
*
**************************************************************************************/
-int up_lcdinitialize(void)
+FAR struct lcd_dev_s *up_oledinitialize(FAR struct spi_dev_s *spi)
{
gvdbg("Initializing\n");
/* Configure GPIO pins */
-
+#warning "Missing logic"
/* Enable clocking /
/* Configure and enable LCD */
- return OK;
-}
-
-/**************************************************************************************
- * Name: up_lcdgetdev
- *
- * Description:
- * Return a a reference to the LCD object for the specified LCD. This allows
- * support for multiple LCD devices.
- *
- **************************************************************************************/
-
-FAR struct lcd_dev_s *up_lcdgetdev(int lcddev)
-{
- gvdbg("lcddev: %d\n", lcddev);
return lcddev == 0 ? &g_lcddev_s.dev : NULL;
}
-
-/**************************************************************************************
- * Name: up_lcduninitialize
- *
- * Description:
- * Unitialize the framebuffer support.
- *
- **************************************************************************************/
-
-void up_lcduninitialize(void)
-{
- /* Turn the LCD off */
-
- /* Disable clocking */
-}
-
-