You are on page 1of 13

Abstract

EyeCatchingMadeEasy
ByFrancisLamotte
ChromARTAcceleratorOpensNewGraphicsPossibilities
forGUIinMicrocontrollerApplications
Thanks to the ease of implementing touch sensing and the
improved price points for displays and 32bit
microcontrollers(MCU),graphicaluserinterfaces(GUI)have
becomeincreasinglypresentinMCUapplications.
In spite of this evolution, some technical challenges have persisted. Typically GUI implementations on
microcontrollers(unlikehigherendprocessorstargetingmobileappliances)havebeenlimiteddependingonhow
muchoftheirprocessingpower,peripheralsandmemoryresourcescouldbededicatedtomanagingthedisplay
andgraphicsinanapplication.
Complexity of coding, and relatively limited memory and processing power for graphics management all
conspiredtomakeimplementationcostlyandresponsivenessoftheGUIrelativelylimited.
Theproposedarticleisaimedatapplicationdesignersusinggeneralpurposemicrocontrollers.Itillustrateshow
integrationof2DDirectMemoryAccess(DMA2D)inmicrocontrollerscreatesnewpossibilitiesforgraphicsusein
user interfaces, while limiting the cost implications in terms of core processor performance, application coding
anddevicecost.ThearticledescribesthekeyfeaturesoftheDMA2Dandtheimplementationofthesefeaturesin
application software with code examples that engineers can use in their own applications. The examples cover
techniquesfor:
Handlingofbitmaps(display,overlayingandmoving)
Usingtransparency(pixellevel,globalandblending)
DynamicversusReadOnlyobjects
Managementofobjectsandtouchsensing
Useoflayering(Zorder)
Transformationsofgraphicobjects
AnduseofmemoryspacesincludingexternalSDRAMresources.
DMA2DOpensNewGraphicsPossibilities
2
Eye Catching Made Easy
byFrancisLamotte

ChromARTAcceleratorOpensNewGraphicsPossibilitiesforGUIinMicrocontrollerApplications
Attractive, flexible, interactive graphical user interfaces are an excellent way to enhance both application
functionality and the users experience. Thanks to the ease of implementing touch sensing and the improved
price points for displays and 32bit microcontrollers (MCU), graphical user interfaces (GUI) have become
increasinglypresentinMCUapplications.
In spite of this evolution, some technical challenges have
persisted. Typical GUI implementations on microcontrollers
(unlike highend processors targeting mobile appliances)
have been limited by how much of their processing power,
peripherals and memory resources could be allocated to
managingthedisplayandgraphics.
Relatively limited memory, processing power and resulting
codecomplexityallconspiredtomakeimplementationcostly
andresponsivenessoftheGUIrelativelylimited.
Thedemonstrationdescribedhereillustrateshowanintegrated2DDirectMemoryAccess(DMA2D)andtheright
combinationofsupportingperipheralsinageneralpurposemicrocontrollersuchastheSTM32F429,canopena
newworldofpossibilitiesforgraphicsuseinmicrocontrollerapplications.
The DMA2D integration is the keystone to this graphics potential in the microcontroller we have selected.
Through a set of registers, the STM32F429 manages graphics with minimal code and impact on processor
performance.GraphicscapabilitiessupportedbytheDMA2Dinclude:
Handlingofbitmapfiles(upto32bitsperpixel),
Managementofimageoverlays,withorwithouttransparency,
Handlingofobjectdisplaytoincludemultipleobjectsandtheirpositions,sizesandlayering(Zorder).
Thisdemonstrationillustrateshowthesefeaturesvastlysimplifyimplementationandmanagementofgraphicsin
amicrocontrollerapplication.Thisdemonstrationcoverstechniquesfor:
Handlingbitmaps(display,overlayingandmoving)
Usingtransparency(pixellevel,globalandblending)
Dynamicversusreadonlyobjects
Useoflayering(Zorder)
Transformationsofgraphicobjects
Managementoftouchsensing
Anduseofmemoryspaces

MultiplebitmapsusedinadynamicGUIonageneralpurposeMCU
DMA2DOpensNewGraphicsPossibilities
3
STM32F429ChromARTAccelerator
TheDMA2Dhardware
ChromART Accelerator is the commercial appellation for STMicroelectronics implementation of the DMA2D
peripheral on the STM32F429. The following figure, taken from the STM32F429 reference manual, shows the
internal structure of the DMA2D and integrated features that make it particularly advantageous for managing
graphics.
Itsfeaturesinclude:
Twoinputpixelformatconverters(PFC).Theseblocksareabletoreadandtodecodebitmapfiles.
Theblender,whichcomputesandmixesthedatafromthetwoinputPFC.
TheoutputPFC,whichdecodestheinformationtobesenttothedestination.
TheFIFOsusedforboththeinputsandtheoutputsconnectedtoaspecificDMAcontroller.
Integrating blending, encoding and decoding functionality in the microcontroller itself, relieves these
requirementsfromtheapplicationcodeandthecoreprocessorthatwouldotherwiseberequiredforthis.

DMA2DOpensNewGraphicsPossibilities
4
TheDMA2DCompanionsontheSTM32F429
In addition to the DMA2D, the STM32F429 provides other integrated controllers that facilitate the optimal
implementationofaGUI.Theseinclude:
AnSDRAMcontrollerfortheadditionofcosteffectiveRAMresourcesforstockinggraphicalelements.
An LCDTFT controller to enable writing of graphics directly to the display for improved efficiency and
performance.
Adigitalcamerainterface
These types of peripherals and features were, in the past, reserved for highend or applicationspecific
processors.NotablyfortheDMA2D,thisisthefirsttimeweseeitintegratedinastandard,generalpurposeMCU
like the STM32F429. The appearance of these peripherals in a general purpose device represents a major
evolution for microcontroller users and, as we see in this demonstration, opens a range of application
possibilities.
STM32F429DMA2DintheEvoPrimerSoftware/HardwareEnvironment
This demonstration uses the EvoPrimer development platform, its CircleOS software environment and DMA2D
API.ThishassomeimpactsonthemannerinwhichtheDMA2Disusedinthedemonstration.
Avideoofthisdemonstrationisavailableonlineathttp://youtu.be/TJWeVvicvZk.Sourcecode,boardschematics,
billofmaterialsanddocumentationareavailableathttp://www.stm32circle.com.
The EvoPrimer features the STM32F429ZI
microcontroller and 2 Mbytes of additional
SDRAM. The demonstration application uses the
microcontrollers DMA2D and SDRAM controller.
The EvoPrimer already includes a controller for
its color TFT touchscreen and no camera is
available on the platform, so neither the
integratedLCDTFTcontrollerorcamerainterface
areusedhere.
For this demonstration, a software API
encapsulates the functionality of the DMA2D.
This implementation is based both on the
EvoPrimer hardware platform and the CircleOS
software environment. In addition to an API for STM32 peripherals, CircleOS provides native capabilities for
drawingobjects,lines,textandpixels.However,thesourcefilesspecifictotheDMA2Daredesignedtobeeasily
extractedandreusedwithoutCircleOS.
In this demonstration we will talk about virtual spaces called screens and displayed objects. In the
application,ScreenreferstoavirtualareathatcanbeshownontheLCDdisplay,abitlikeadesktop.Ascreen
hasavisiblezonethesizeoftheEvoPrimerLCDdisplay(240x320pixels).
Object refers to a graphic rectangle in bitmap format that can be read from memory and written to the LCD
displayusingtheDMA2D.Anobjectisdeclaredasarectangle,butanyformcouldbeconsiderediftransparency
isusedinthebitmap.Inthisdemoapplication,theseobjectssuchasiconsorabackgroundimageareattributed
DMA2DOpensNewGraphicsPossibilities
5
to a virtual screen in order to be displayed. Objects are placed in the screen by X, Y coordinates. The
coordinatescanbeoutsidethedisplayedareaofthescreen.Thevisibleareacanalsobemovedlikeawindowto
displayobjectsinvirtualspace.Thisisdemonstratedindetailinthenextsections.
Using the API provided in the DMA2D files of CircleOS is a simple way to manage the graphics capability of the
DMA2Dtoincludeuseof:
Twoormorevirtualscreens
Upto256graphicobjectsperscreen
Displayandmovementofobjectsanywhereonthe2dimensionalspaceofascreen.
Keepinmindthat,initssimplestform,an
STM32F429 application can use the
DMA2D to write a bitmap directly to the
LCD. The implementation in the
demonstration application is a little more
complex, but allows us to explore a wide
range of possibilities for DMA2D use in a
graphicalinterface.
This illustration shows how the DMA2D
and SDRAM are used in the
demonstration application. The
application calls bitmaps (objects) from memory and includes the information for their positions (X, Y
coordinates), layer (Zorder) and attributes them to a screen. The DMA2D blends the objects and stores the
resultingobjectdirectlytoSDRAM.Inthisdemonstrationapplication,theDMAisusedtotransfertheobjectto
the display. SDRAM is alsoused to storedynamic objects such as texts or forms that are created using CircleOS
nativedrawcapabilitiesforrenderingforms,text,linesorpixels.
DirectHandlingBitmaps
Displayofapicture
The DMA2D peripheral allows a bitmap file (the legacy
.BMP format) to be loaded almost directly onto an LCD.
The DMA2D does not decode the header of the bitmap.
This must be managed by the application software, which
initializes a set of registers that have been read from the
header. The image is then displayed totally or partially on
theLCDbytheDMA2D.
The DMA2D manages most of the possible formats for
bitmaps including: 8, 16, 24 and 32bit, direct colors and
indexedcolors(usingapalette).
In the C program, a bitmap must be declared as a byte array initialized by the contents of the binary file
(translated into a .h text file). This example describes the code used to display the 640 by 320 pixel bitmap
("photo_x8 with 8bit indexed color palette) shown here, on a display that is 320 by 240 pixels. Because the
imageislargerthanthesizeoftheLCDpanel,itwillbeautomaticallycroppedbytheDMA2DAPI,asshownhere.
DMA2DOpensNewGraphicsPossibilities
6
Belowisthecodetodeclareforboththisbackgroundimageandabirdcharacter(bird_A888)thatisusedlaterin
thedemonstration:
const unsi gned char phot o_x8[ ] = / / A pi ct ur e f r oma camer a. . .
{ / / I ndexed col or s ( 8- bi t pal et t e)
0xf f , 0xf f , / / 32- bi t al i gnment r equi r ed f or t he pal et t e
#i ncl ude " i mage\ backgr ound\ phot o640X320_x8. h" / / The l egacy . bmp f i l e
};

const unsi gned char bi r d_A888[ ] = / / A smal l bi r d i l l ust r at i on
{ / / . bmp f i l e wi t h 32 bi t ( A888) col or s.
0xf f , 0xf f , / / f or 32- bi t al i gnment of t he bi t map dat a.
#i ncl ude " i mage\ f or egr ound\ bi r d_A888. h" / / . bmp f i l e cont ent s
};

Todisplaythepicturephoto_x8asthebackgroundofascreen,allyouhavetodoistocreateanobject,createa
linkbetweentheobjectandthebitmap,thentomakethebitmapvisible.
BG_I mage = DMA2D_Obj ect Cr eat e( 640, 320, 1) ; / / Cr eat e an empt y obj ect
DMA2D_Obj ect Assi gnBi t map( BG_I mage, phot o_x8, 0) ; / / Li nk bi t map and obj ect
DMA2D_Obj ect Set ToScr een( BG_I mage, SCREEN_I D) ; / / At t ach t he obj ect t o a scr een
DMA2D_Obj ect Set Vi si bl e( BG_I mage, 1) ; / / Make t he obj ect vi si bl e
DMA2D_Scr eenRedr aw( SCREEN_I D) ; / / and r epai nt t he whol e scr een.

The palette for the bitmap is loaded automatically by the DMA2D, based on the header information that is
decodedbytheapplicationsoftware(inthiscasetheAPI).
The last command (DMA2D_ScreenRedraw) scans the list of objects assigned to a screen and repaints all the
visibleones.Notethatthesizeofthebackgroundimage(640x420pixelsinthisexample)canbebiggerthanthe
sizeofthescreen(320x240forourdemonstrationplatform).
Thebitmapcanbepositionedbasedonprovidedcoordinates.0forXandYaxesarethelowerlefthadcornerof
the LCD. To fill the entire display area of the LCD, the coordinates X and Y must be negative (or equal to 0).
Positivecoordinateswillleaveanareathathasnotbeendrawnstartinginthelowerleftcornerofthedisplayto
thecoordinatewherethelowerleftcornerofthebackgroundimageisdisplayed.
Ifyouwanttocentertheimage,youcan"move"thebackgroundbeforeredrawing:
DMA2D_Obj ect Move( BG_I mage, PosX_BG = - 160, PosY_BG = - 120 ) ; / / set t he posi t i on

Becausetheoverallobjectistoobigtobedisplayedinourscreen,itisautomaticallycroppedatthebordersof
theLCDpanel.

DMA2DOpensNewGraphicsPossibilities
7
OverlayingBitmaps
The DMA2D allows other objects to be placed on the
background. Overlaying objects on a background or on
other objects is particularly advantageous with the
DMA2D because only the areas affected by a
modification are redrawn. Without the DMA2D,
changing the position of a displayed object requires
either pixelbypixel redrawing of the full display, or
complexapplicationcode(andalotofprocessortime)to
manage this functionality in the same manner as the
DMA2D.With our STM32F429, the DMA2D peripheral writes only the affected pixels. So, to add an object over
thisbackground,wesimplycreateit,settheposition(relativetothedisplayandnotthebackground)andmakeit
visible:
i nt x_bi r d = 100, y_bi r d = 100;
FG_Bi r d = DMA2D_Obj ect Cr eat e( 48, 48 , 1) ;
DMA2D_Obj ect Assi gnBi t map( FG_Bi r d, bi r d_A888, 0) ;
DMA2D_Obj ect Set ToScr een( FG_Bi r d, SCREEN_I D) ;
DMA2D_Obj ect Set Vi si bl e( FG_Bi r d, 1) ;
DMA2D_Obj ect Move( FG_Bi r d, x_bi r d, y_bi r d) ;

MovingObjects
Tomakeanobjectmovethroughthedisplay(forexampletomakeourbirdfly),itisonlynecessarytoperiodically
recallthelastlinewithanew,differentposition(x_bird,y_bird):
DMA2D_Obj ect Move( FG_Bi r d, x_bi r d++, y_bi r d++) ; / / t he bi r d moves t o up- r i ght .
. . .
DMA2D_Scr eenRedr aw( SCREEN_I D) ; / / and r epai nt t he whol e scr een.
TheDMA2Dhardwareperipheralisaddressedonlywhen
calling the DMA2D_ScreenRedraw function. The rest of
the API functions just configure the descriptions of the
objectsthatwillbeusedbytheDMA2D.
Note that it is possible to animate the flying bird by
managing several bitmaps, each showing the bird in a
different state of movement. Then we periodically
change the bitmap assignment. This is how the butterfly
ishandledinthedemonstration:


DMA2D_Obj ect Assi gnBi t map( FG_Bi r d, bi r d_f l y_A888[ n] , 0) ;
. . .
DMA2DOpensNewGraphicsPossibilities
8
DMA2D_Scr eenRedr aw( SCREEN_I D) ; / / and r epai nt t he whol e scr een.
ThankstotheintegrationoftheDMA2Dperipheral,thedisplaychangesthatallowustoanimatemovementare
representedbyjustafewlinesofsimplecode.
Transparency
Alphacomponentforthepixel
Transparencyofanobjectthatisoverlayedonthebackgroundishandledatdifferentlevels.
First, transparency may be native to the original bitmap. A 32bit bitmap file contains 8bit transparency
information for each pixel (24bit color plus an 8bit alpha). The transparency is also referred to as the "alpha"
component. If you choose a file in a 32bit format for display using the DMA2D, the original transparency for
eachpixelismanagedbuttheDMA2D.Ifyouchooseanyother,smallerformat,thealphaconstantisnotdefined
inthebitmapandthereforeisassumedtobeequalto255(anopaqueobject)whendisplayedusingtheDMA2D.
In addition to the native transparency of a specific bitmap, the DMA2D can be used to manage transparency
accordingtoaglobalalphaconstant.
Globalconstantalpha
Globalalphaconstantisusedtodefinetheglobaltransparencyofanobjectwhenitisdisplayed.Ifanobjecthas
boththeoriginalbitmaptransparencyandaglobaltransparency,theresultingalphavalueforeachpixelwillbe
thecombinationofthetwoparameters.Thetwoalphavaluesaremultipliedandtheresultdividedby256:
alpha
out
=
(alpha
pixel
alpha
global
)
256

Thismeansthatafullytransparent(invisible)pixelinthebitmap(alpha=0inthebitmapfile)remainsinvisible
regardlessoftheglobaltransparencyoftheobject.
Blending
This example shows how alpha factors are combined when
objects are overlayed. The DMA2D allows complex
combinationsinblending,whicharenotexploredhere.
Forthepurposeofthisdemonstration,eachtimeanobject
is displayed, the API assumes that the "current background"
is opaque (alpha = 255). "Current background" is the term
that we use for the result of the display of all the previous
layers/objects.
Thefinalpixelistheresultofthecombinationofallthealpha
valuesoftheoriginalbitmaps,weightedbytheglobalalphavaluesofeachobject.Notethat,iftheobjectatthe
top level (the highest zorder) is opaque (alpha=255 for both the object and the pixel), this object is displayed
withoutanyinterferencefromthelowerobjects.
Thefollowingcodeshowshowtocreate,inaneditableobject,afullytransparentpart,andanopaquepartthat
willbegloballytunablebytheglobaltransparencyratio:
DMA2D_Obj ect Set Tr anspar ency( FG_Text , 0) ; / / Ful l t r anspar ency f or t he next command
LCD_Fi l l Rect ( 0, 0, 220, 80, RGB_RED) ; / / Fi l l as t r anspar ent t he whol e obj ect
DMA2DOpensNewGraphicsPossibilities
9
DMA2D_Obj ect Set Tr anspar ency( FG_Text , 0xf f ) ; / / The el l i pt i c sur f ace wi l l be opaque
DRAW_El l i pse( 110, 30, 110, 35, RGB_RED, RGB_RED, 1, 1) ; / / Dr aw a cent er ed opaque el l i pse
DMA2D_Obj ect Set Tr anspar ency( FG_Text , 0x80) ; / / Set t he gl obal t r anspar ency

Editableobjects
DynamicvsReadOnlyObjects
Up to this point, we have only handled graphics that were
edited on a PC and saved in BMP format. The bitmap was
included as a ".h" file into the FLASH that is treated by the
applicationasreadonlymemory.
The API allows objects to be handled in RAM as well. These
objects can be dynamically edited bythe application. In the
imageattheright,thetextiswrittendirectlyontoadynamic
object. The red ellipse itself has been drawn using the
standardlibraryfunctionsasshowninthiscode:
FG_Text = DMA2D_Obj ect Cr eat e( 220, 80 , 0) ; / / The 3r d par amet er means " r ead- onl y==0"
DMA2D_Obj ect Set ToScr een( FG_Text , SCREEN_I D) ;
/ / Al l t he f ol l owi ng commands wi l l be appl i ed t o t he obj ect i nst ead of t he scr een
DMA2D_Obj ect Sel ect ( FG_Text ) ;
DMA2D_Obj ect Set Tr anspar ency( FG_Text , 0) ;
LCD_Fi l l Rect ( 0, 0, 220, 80, RGB_RED) ;
DMA2D_Obj ect Set Tr anspar ency( FG_Text , 0xf f ) ;
DRAW_El l i pse( 110, 30, 110, 35, RGB_RED, RGB_RED, 1, 1) ;
DRAW_Set BGndCol or ( RGB_RED) ; / / Backgr ound col or f or t he t ext
DRAW_Set Text Col or ( RGB_WHI TE) ;
DRAW_Di spl aySt r i ngWi t hMode( 60, 45, " Dynami c" , 0, NORMAL_TEXT, LEFT) ;
DRAW_Di spl aySt r i ngWi t hMode( 57, 30, " l ayer ed" , 0, NORMAL_TEXT, LEFT) ;
DRAW_Di spl aySt r i ngWi t hMode( 50, 15, " gr aphi cs" , 0, NORMAL_TEXT, LEFT) ;

Editingadynamicobject
The DRAW commands shown above typically pertain to the whole screen. The coordinates x =0, y =0 are the
coordinatesofthelowerleftcorneroftheLCD.AftercallingDMA2D_ObjectSelect(),theseDRAW_xxxcommands
are assigned to the currently selected object. The coordinates are considered relative to the object and (0,0)
matcheswiththelowerleftcorneroftherectanglecontainingtheobject.
Whenadynamicobjectisdeclared,amovecommandisappliedtothewholeobject.Thismeansthattheobject
willmovewithitscontents(theellipseandthetext).
DMA2DOpensNewGraphicsPossibilities
10
Note that the object is always stored in RAM as a 32 bit image. Each pixel has a 24bit color and a 8bit alpha
component.

Advancedfeatures
ZOrder
Theobjectsaresortedtodefinetheorderofdrawing.Theyarestoredinanarray,andtheindexinthisarrayis
namedZorder.Graphically,theZorderspecifiestherelativepositionoftheobjectlayer(eg.ItspositionontheZ
axis)."Zorder==0"correspondstothefirstdrawnobject(typicallythebackground).
TheAPIprovidesfunctionstoincrement/decrementtheobjectsZorder.Twoothersfunctionsallowplacement
oftheobjectattheupperlayer,orasthebackground.
DMA2D_Obj ect PushZ( Bi r d2_I mage, SCREEN_SLI DE) ;


Touchscreenandobjects
Whenimplementingobjectsinatouchscreeninterface,thefunctionDMA2D_ObjectFindreturnsapointertothe
objectthatistheownerofthepixellocatedat(x,y).Whenseveralobjectsarelayeredatthesameposition,the
uppermostlayerisconsidered.
So,whenthetouchscreenispressed,it'squitesimpletodetectwhichobjecthasbeentouched:
i f ( TOUCHSCR_I sPr essed( ) )
{
posx = TOUCHSCR_Get PosX( ) ;
posy = TOUCHSCR_Get PosY( ) ;
Sel ect edObj ect = DMA2D_Obj ect Fi nd( Cur r ent Scr een, posx, posy ) ;
i f ( Sel ect edObj ect == FG_Bi r d )
{
bi r d_hi t = 1;
. . . .
Objecttransformations
DMA2DOpensNewGraphicsPossibilities
11
A wide range of object transformations are possible. Transformations of objections are enabled by two basic,
genericactions:
Eitherspecifyingthecontentsofthedestinationpixel,
Orspecifyingwhereasourcepixelwillbecopiedtoadestinationobject.
Afewexamplesshowthevarietyofobjecttransformationsthatresultfromthesetwoprinciples,including:
Copyingthecontentsofanobjectontoanotherobject,
Rotatinganobjectonitself(withoutusinganintermediatebuffer),
Shrinking/expandingthesizeofanobject,
Modifyingsomecolors/alphacharacteristicforanypixel.
Theseexamplesarenotexhaustive.CircleOSallowsspecificationononehandofthesourceanddestination
objects(orapartofanobject),andontheotherhandthetransformationoperationtoapply.Thetransformation
isfullydefinedbytheprogrammer,andonlythecorefunctionsareembeddedinCircleOS.
ManagingmemorycapabilitieswiththeSTM32F429
LargeInternalMemory
New microcontroller families embed very large internal FLASH memory. The STM32F429contains up to2MB of
internalFLASH.
InFLASH,a320x240pixelimagerequiresabitmorethan75Kbyteswhenthecolorsareindexedina256byte
palette.Therefore,afewbackgroundimagescanbestoredwithoutproblems.
SDRAMController
StoringbitmapsinFLASHiseasyaslongastherearenottoomanybigpictures.Butstoringaneditableobjectin
RAMismoredifficulttomanage,sincethesizeoftheinternalSRAMisalwaysmuchsmallerthanthesizeofthe
internalFLASH.
Instead of embedding a very large internal SRAM, the new STM32F429 features an internal controller for an
externalSDRAM.BecauseSDRAMisverycheap,thisisasimplewaytoprovideafewmegabytesofdynamicRAM
thatcanbeusedforlargedynamicgraphicobjects.
ScreenImagesinRAM
For the purposes of this demonstration with EvoPrimer, an image of the screen is kept in the SDRAM. This is
becauseitisnotconvenienttoaddresstheRAMoftheLCDonthishardwareplatform.Thisimageissent(using
the DMA) to the LCD when a DMA2D_ScreenRedraw has been executed. This mode allows management of
severalscreenimagesinSDRAM,andperformingofrapidswitchesbetweenthesescreens.
InthecaseofCircleOS,oneMegabyte(halfoftheSDRAM)isreservedfortheuseoftheDMA2D:
Twoscreenimagesoccupy300Kbytes(2x320x240x16bitpixels)
Therest(724Kbytes)canbeusedforobjects

DMA2DOpensNewGraphicsPossibilities
12
TheDMA2DGraphicsRevolutioninGeneralPurposeMicrocontrollers
The revolutions that the DMA2D represents are both its adaptation to a specific use (in our case the display of
graphicsontheLCD)anditsinclusioninageneralpurposemicrocontroller.Asshowninthisdemonstration,the
DMA2D enables a range of GUI possibilities (extensive use of bitmaps for graphic objects, management of
movement, transparency and layering) that is a vast improvement over the possibilities presented by
microcontrollerswithoutaDMA2D.
Inaddition,asavvyimplementationoftheDMA2DreducesthecostofGUIimplementation.Itmakeshardware
morecosteffectivethroughaffordabilityofthegeneralpurposeMCU,lowcostexternalmemoryandelimination
of external LCD controller. It also reduces development and maintenance cost with code that is simple and
accessible.
The source code used for this demonstration is currently available at www.stm32circle.com and the hardware
platformisavailablefromSTMicroelectronics,theirdistributorsandatRaisonance.com.

AbouttheAuthor:
FrancisLamotte
FrancisLamotteservesasKEOLABSVicePresident.Withmorethan20yearsofexperience
in technology research with partners that include the STMicroeletronics and NXP, Francis
guidesKEOLABSR&Dactivitieswithaneyeondevelopingfuturebusinessopportunities.In
addition he serves in an oversight role, defining the business and technology priorities for
thecompanies'microcontrollertoolactivity.
Prior to KEOLABS, Francis directed Raisonance S.A.S., the microelectronics tool company
thathefoundedin1988.Heleadthecompanythroughits24yearhistoryasitsprincipletechnicalandbusiness
director. Prior to Raisonances merger with Soliatis in 2012, Francis had expanded the company activities to
encompassbothhardwareandsoftwaredesign.ThispositionedRaisonancetoprovideacompleterangeoftools
(compilers,assemblers,debuggersandemulators)forcreatingmicrocontrollerapplicationsandarangeofsignal
analyzersandemulatorsusedinthevalidationofsmartcardsandrelatedtechnologies.

DMA2DOpensNewGraphicsPossibilities
13

You might also like