emWin driver GUIDRV_Fujitsu_16

This driver supports the Fujitsu Graphic display controllers. It has been tested with "Jasmine", but it should also work with "Lavender", since all relevant registers are compatible.

Supported hardware

Controllers

This driver works with the following display controllers:

  • Fujitsu Jasmine
  • Fujitsu Lavender

Bits per pixel

Supported color depths are 1, 2, 4, 8 and 16 bpp.

Interfaces

The driver has been tested with a 32 bit interface to the CPU. If a 16 bit interface is used, the 32-bit accesses can be replaced by 2 16-bit accesses.

Driver selection

To use GUIDRV_Fujitsu_16 for the given display, the following command can be used e.g.:

pDevice = GUI_DEVICE_CreateAndLink(GUIDRV_Fujitsu_16, GUICC_556, 0, 0);

Available configuration macros (compile time configuration)

Controller selection

To select the desired controller the macro LCD_CONTROLLER should be used in the configuration file LCDConf_Fujitsu_16.h. The following table shows the values to be used to select the appropriate controller:

Number Supported Controller
8720 Fujitsu Jasmine
8721 Fujitsu Lavender

Display data RAM organization

The display controller uses DRAM in an optimized, non-linear way (described in the Fujitsu documentation). Direct memory access is not used by the driver.

RAM requirements of the driver

About 16 bytes for some static variables.

Hardware configuration

This driver requires a direct interface for hardware access. The following table lists the macros which must be defined for hardware access:

Macro Explanation
LCD_READ_REG Read a register of the display controller. (as 32 bit value) (optional)
LCD_WRITE_REG Write a register of the display controller. (as 32 bit value) (optional)

The driver contains a default for hardware access macros, which configures 32 bit access on the Fujistu demonstration platform (Using an MB91361 or MB91362 and a Jasmine chip at address 0x30000000); if the target hardware is compatible with these settings, then LCD_READ_REG(), LCD_WRITE_REG() do not need to be defined.

Color format (R/B swap)

It seems that on some target systems, Red and blue are swapped. This can be changed via software if the Config switch LCD_SWAP_RB is toggled in the configuration file.

Hardware initialization

The display controller requires a complicated initialization. Example code is available from Fujistu in the GDC module. This code is not part of the driver, since it depends on the actual chip used, on the clock settings, the display and a lot of other things.

We recommend using the original Fujitsu code, since the documentation of the chips is not sufficient to write this code. Before calling GUI_Init(), the GDC should be initialized using this code (typically called as GDC_Init(0xff)).

Example:

LCDConf.h for VGA display, 8bpp, Jasmine:

#define LCD_XSIZE         640 // X-resolution of LCD, Logical color
#define LCD_YSIZE         480 // Y-resolution of LCD, Logical color
#define LCD_BITSPERPIXEL    8
#define LCD_CONTROLLER   8720 // Jasmine

Additional configuration switches

The following table shows optional configuration macros available for this driver:

Macro Explanation
LCD_ON Function replacement macro which switches the display on.
LCD_OFF Function replacement macro which switches the display off.