Interfacing Toshiba T6963C LCD to Atmel AT91SAM ARM microcontroller

Introduction

LCD displays with Toshiba T6963 controller are ones of the most popular LCD displays. On this page You will find ready-to-use source code for Atmel AT91SAM microcontrollers with ARM core written in C language for arm-elf-gcc compiler (WinARM).

 

I divide source code for following files :

  • T6963C.h - configuration and functions declarations for T6963.c file
  • T6963C.c - all functions specific for T6963 controller
  • graphic.c - functions for drawing lines, circles and rectangles
  • graphic.h - functions declarations for graphic.c file

 

All source codes are available in Download section. After download all files to folder with Your project and add T6963.c and graphic.c files to project tree and to  makefile)and place in file with the main() function calls to functions which You would to use. Code is work currently only with 240x64 pixels displays. With other resolutions can work wrong.

For example, code shown below :

#include "build/board.h"
#include "T6963C.h"
#include "graph.h"

extern void Init(void);

int main(void)
{
int i;
Init();

GLCD_Initalize();
GLCD_Clear_Graphic();
GLCD_Clear_Text();
GLCD_Clear_CG();

GLCD_Line(0,0, 239, 0);
GLCD_Line(0,0,0,63);
GLCD_Line(239,0, 239, 63);
GLCD_Line(239, 63, 0, 63);

GLCD_Circle(30,30,20);
GLCD_Line(30, 10, 30, 20);

GLCD_Circle(209,30,20);
GLCD_Line(209, 10, 209, 20);

GLCD_Rectangle(60, 6, 120, 48);

GLCD_Text_GoTo(13,1);
GLCD_Write_String("radzio.dxp.pl");

GLCD_Text_GoTo(13,3);
GLCD_Write_String("TOSHIBA T6963C");

GLCD_Text_GoTo(11,5);
GLCD_Write_String("AT91SAM7 & arm-gcc");

while(1);
return 0;
}

...will produced following image :



 

Download

Source code for arm-elf-gcc compiler from WinARM package. It can be ported for others compilers and other ARM-based microcontrollers. Tested with AT91SAM7S256 and Optrex DMF-5005 display.

If You have questions or suggestions about this site and source codes, You can contact me by e-mail (only in Polish or English language) :

Last modification : 24-05-2008 10:30:12
(c) Radosław Kwiecień
Privacy policy