Microchip® Advanced Software Framework

Quick Start Guide for the ILI9341 Display Controller Component Driver

This is the quick start guide for the ILI9341 Display Controller Component Driver, with step-by-step instructions on how to configure and use the component driver for specific use cases.

The section described below can be compiled into e.g. the main application loop or any other function that will need to interface non-volatile memory.

Basic usage of the ILI9341 component driver

This section will present one use cases of the ILI9341 component driver. It will first turn on the backlight and then fill the screen with a solid color.

Use case 1: Fill Screen Color

The ILI9341 component driver contains a basic backlight control as well as functions to draw pixels of various colors within a given pixel boundary. This use case will turn on the backlight and fill the entire display with a single color.

Prerequisites

The conf_ili9341.h configuration file must be present in your application, and should be set to use the correct SPI interface of your chosen microcontroller.

Your application should configure the display SPI, reset, command/data and backlight pins as appropriate. If you are using the mXT143E Xplained kit, this can be achieved by defining:

#define CONF_BOARD_MXT143E_XPLAINED

in your conf_board.h header file.

Setup

Code

Workflow

  1. First, we must initialize the display so that it is correctly configured and ready to receive commands:
  2. Next, the display backlight is enabled, turning it on:

Example code

Workflow

  1. First the screen drawing limits are set to start from the upper-left pixel coordinate, and end at the lower right screen boundary:
  2. Next, the display is filled with 240*320 (the screen's pixel dimensions) pixels of the same RGB color of (255, 0, 0), a bright red.