TFT colour display development - TftAVR

TrxAVR supports a 480x272 colour TFT display with touch panel..

For screenshots from TrxAVR-Picastar see:   Colour TFT screenshots.

The TrxAVR code to drive these display was developed using an eDIPTFT43-ATP 480 x272 intelligent
colour display from Electronic Assembly. These cost 200ukp. A few builders use these.

A large number of builders are using the TftA display driver board which was developed to provide
a low cost way of achieving a 480x272 colour Tft display.

The initial development using the EA display is described further down this page

TftA - achieving a low cost TFT display

480x282 colour TFT displays can be abtained on eBay for as little as 20ukp. The displays used are
4.3 inch (as the EA display) or more commonly 5inch. They can have an optional touch panel.
They are mass produced for use in GPS navigator units etc.
The total cost is in the order of 30ukp + display cost.

This controller board project is named TftA. (The protoype was TftAVR)

Glenn, VK3PE has provided an excellent description / construction manual for TftA at:

         http://www.carnut.info/tftpcb/tft.htm

Further construction information and the software is on the TftA_Central yahoo group

I therefore make no attempt to repeat Glenn's information here. - Just some useful backgroud information:

There is the need to load fonts etc into the flash memory on the display controller board (both for EA and TftA).
This can be done in a single operation from Hobcat.
                                
(The route is:   PC file > Hobcat > USB > TrxAVR > I2C > TftA )
This has removed the need for a separate programmer (thus keeping costs down)

Epson S1D13781

TftA uses a very recent display driver chip from Epson. this is the S1D13781. The development was done
on samples which were begged from Epson agents before the chips were commercially available.
Most of the S1D13781s have been been bought in bulk purchases from Rutronik UK. The price is aprrox. 6.00ukp.

TftA controller board

Full construction infomation at: http://www.carnut.info/tftpcb/tft.htm


TftA top view   ATXmega128A1 on the left. Epson S1D13781 on the right

TftA components include:

Programming the display flash memory

The flash programming code is in a zip files on the downloads page.
It is also distributed by HobcatSetup.exe.

It is possible to program the display via its I2C interface.
I have therefore created a TFT flash programming window in Hobcat.

   
Hobcat's display flash programming window

The flash file    travr.DF   is generated by the compile button in the EA Kit Editor software.
(An error report occurs because te USB programmer is not found)
trxavr.DF is currently 98kbyte. Hobcat transmits it to TrxAVR via USB and then TrxAVR
send it via I2C to the display.
- so you dont need the USB programmer and there is no interface mode switching needed.

History - initial development


The inital development display: an EA eDIPTFT43A display
mounted on an optional
USB programmer back-board from EA.

This was purchased in the UK from MMS Electronics (supply of displays from Electronic Assembly).
The cost is 180ukp + VAT (plus 20ukp for the USB programmer ... if purchased with the display)
A blank (unpopulated) backboard - (same as the USB programmer) can be purchased for  11ukp.

eDIPTFT43-ATP 480 x272 intelligent colour display.

The display data sheet is: http://www.lcd-module.de/eng/pdf/grafik/ediptft43-ae.pdf

This is an excellent piece of kit ... and I cant find anything else like it on the web.

Hardware:
Most colour TFT panels (including those on offer on eBay) have a RGB scanning interface - typically
a 6 bit connection for each of Red green and Blue.
They are not intended to be connected direct to a microcontroller.
An interface chip is needed with an 8 bit microcontroller interface, display memory and scanning hardware.
Epson provide a range of such controllers.
TrxAVR-Picastar could drive such a controller .... but the eDIPTFT43-ATP makes things much easier.

The eDIPTFT43-ATP hardware includes:


Rear view of display. The chip with the label is an ATmega1280.

It has interfaces for:

TrxAVR-Picastar uses the I2C interface.
I2C allows bidriectional inter-processor communication using a simple two wire connection.
Eight devices can be paralleled on the bus. TrxAVR's 24LC512 eeprom is hard-wired to address 0.
The EA display defaults to address 7.

In my test rig, I interposed an additional turned pin 8-way DIL socket beneath the 24LC512 eeprom
and soldered wires to the clock, data and ground pins.
Glenn's boards provide a four pin socket for I2C.

Interfacing

The display is driven by simple ESC command sequences which can be ASCII text or binary.
I have chosen the use ASCII text.

For example:

TrxAVR-Picastar code contains functions to generate these commands from the C code:

Display Flash memory:
The display's 4Mbyte flash memory can be used to store fonts, macros (command sequences), fill-patterns, images etc.

Macros
Macros are command sequences that are programmed into the display flash memory.
The macro language supports C type arithmetic manipulations.
There are no loop structures, but the use of the i++ structure as in C allows repetive tasks to be generated
quickly by copy and paste. eg: from file trxavr.kmc

   ;DSP monitor cailbration mark, two pixel vertical lines
   ; top and bottom of each bar
   i=1
   #GD L+X2+20*i,y,L+X2+20*i,y+2
   #GD L+X2+20*i,y+GS-2,L+X2+20*i++,y+GS-1
   #GD L+X2+20*i,y,L+X2+20*i,y+2
   #GD L+X2+20*i,y+GS-2,L+X2+20*i++,y+GS-1
   #GD L+X2+20*i,y,L+X2+20*i,y+2
   #GD L+X2+20*i,y+GS-2,L+X2+20*i++,y+GS-1
      
etc.......

The above is a sequence of identical command pairs.
The i++ increments i for the next pair and so simulates the effect of:    for i = 1 to n

For illustration purposes, links to the two macro-language files are here.
( Do not use these links for flash programming as they might not be the latest)
     trxavr.kmc          trxavr_font.kmi       ( *.kmi signifies a file 'included' in a *kmc file)

In the TrxAVR-Picastar C code, a macro sequence is simply called by:

         etcMacro(n)      where n s the macro number.

Fonts
The display comes loaded with eight fonts - two of which are big fonts for numerics (and +/- ) only.
The EA software kit includes   FontConvert.kmc   which will convert any Windows font into a *.FXT bitmap file
for use in the display.

TrxAVR-Picastar uses Arial14, Arial16, Arial18 and Arial20 for most of the text
and OldSansBlack 42 and 28 for the frequency display.

 

TrxAVR-Picastar home page