lpcware

Indirect 8bit parallel question

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by DT1 on Tue Oct 01 08:57:45 MST 2013
Hi,

I'm currently reading the documentation and setting up my project to add graphics. I'm going to use a Sunplus SPLC501C controller and the hardware connected to it is parallel 8bit. According to what I read so far, GUIDRV_SPAGE is going to be what I need.

I'm using:
- LPC1788 (EA dev board). Ultimately, LPC1778 on custom board.

I downloaded the BSP for that board and the emWin5.22 source also. So far I think I understand a good part of the configuration process. However, there is one gray zone in my mind. Our custom board uses GPIOs for the parallel 8bit bus. I'm not sure how to tell emWin which pin is which GPIO. Looking at "LCD_X_8080_8.c", I can see how to define address pin, RW, etc.:

#define LCD_CLR_RESET()   P7 &= ~(1<<0)
#define LCD_SET_RESET()   P7 |=  (1<<0)
#define LCD_CLR_A0()      P8 &= ~(1<<0)
#define LCD_SET_A0()      P8 |=  (1<<0)
#define LCD_CLR_WR()      P8 &= ~(1<<1)
#define LCD_SET_WR()      P8 |=  (1<<1)
#define LCD_CLR_RD()      P8 &= ~(1<<2)
#define LCD_SET_RD()      P8 |=  (1<<2)
#define LCD_CLR_CS()      P8 &= ~(1<<4)
#define LCD_SET_CS()      P8 |=  (1<<4)
#define LCD_DATA_IN       P10
#define LCD_DATA_OUT      P10
#define LCD_SET_DIR_IN()  P10D = 0
#define LCD_SET_DIR_OUT() P10D = 0xff

As for the data bits, I currently have no clue on how to tell emWin which GPIO I'm using.

Any advices?

Thanks!

Outcomes