Zephyr Project API 3.7.0
A Scalable Open Source RTOS
|
FT8xx co-processor engine functions. More...
Macros | |
#define | FT8XX_OPT_3D 0 |
Co-processor widget is drawn in 3D effect. | |
#define | FT8XX_OPT_RGB565 0 |
Co-processor option to decode the JPEG image to RGB565 format. | |
#define | FT8XX_OPT_MONO 1 |
Co-processor option to decode the JPEG image to L8 format, i.e., monochrome. | |
#define | FT8XX_OPT_NODL 2 |
No display list commands generated for bitmap decoded from JPEG image. | |
#define | FT8XX_OPT_FLAT 256 |
Co-processor widget is drawn without 3D effect. | |
#define | FT8XX_OPT_SIGNED 256 |
The number is treated as 32 bit signed integer. | |
#define | FT8XX_OPT_CENTERX 512 |
Co-processor widget centers horizontally. | |
#define | FT8XX_OPT_CENTERY 1024 |
Co-processor widget centers vertically. | |
#define | FT8XX_OPT_CENTER 1536 |
Co-processor widget centers horizontally and vertically. | |
#define | FT8XX_OPT_RIGHTX 2048 |
The label on the Coprocessor widget is right justified. | |
#define | FT8XX_OPT_NOBACK 4096 |
Co-processor widget has no background drawn. | |
#define | FT8XX_OPT_NOTICKS 8192 |
Co-processor clock widget is drawn without hour ticks. | |
#define | FT8XX_OPT_NOHM 16384 |
Co-processor clock widget is drawn without hour and minutes hands, only seconds hand is drawn. | |
#define | FT8XX_OPT_NOPOINTER 16384 |
The Co-processor gauge has no pointer. | |
#define | FT8XX_OPT_NOSECS 32768 |
Co-processor clock widget is drawn without seconds hand. | |
#define | FT8XX_OPT_NOHANDS 49152 |
Co-processor clock widget is drawn without hour, minutes and seconds hands. | |
Functions | |
void | ft8xx_copro_cmd (uint32_t cmd) |
Execute a display list command by co-processor engine. | |
void | ft8xx_copro_cmd_dlstart (void) |
Start a new display list. | |
void | ft8xx_copro_cmd_swap (void) |
Swap the current display list. | |
void | ft8xx_copro_cmd_text (int16_t x, int16_t y, int16_t font, uint16_t options, const char *s) |
Draw text. | |
void | ft8xx_copro_cmd_number (int16_t x, int16_t y, int16_t font, uint16_t options, int32_t n) |
Draw a decimal number. | |
void | ft8xx_copro_cmd_calibrate (uint32_t *result) |
Execute the touch screen calibration routine. | |
FT8xx co-processor engine functions.
#define FT8XX_OPT_3D 0 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget is drawn in 3D effect.
#define FT8XX_OPT_CENTER 1536 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget centers horizontally and vertically.
#define FT8XX_OPT_CENTERX 512 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget centers horizontally.
#define FT8XX_OPT_CENTERY 1024 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget centers vertically.
#define FT8XX_OPT_FLAT 256 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget is drawn without 3D effect.
#define FT8XX_OPT_MONO 1 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor option to decode the JPEG image to L8 format, i.e., monochrome.
#define FT8XX_OPT_NOBACK 4096 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor widget has no background drawn.
#define FT8XX_OPT_NODL 2 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
No display list commands generated for bitmap decoded from JPEG image.
#define FT8XX_OPT_NOHANDS 49152 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor clock widget is drawn without hour, minutes and seconds hands.
#define FT8XX_OPT_NOHM 16384 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor clock widget is drawn without hour and minutes hands, only seconds hand is drawn.
#define FT8XX_OPT_NOPOINTER 16384 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
The Co-processor gauge has no pointer.
#define FT8XX_OPT_NOSECS 32768 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor clock widget is drawn without seconds hand.
#define FT8XX_OPT_NOTICKS 8192 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor clock widget is drawn without hour ticks.
Gauge widget is drawn without major and minor ticks.
#define FT8XX_OPT_RGB565 0 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Co-processor option to decode the JPEG image to RGB565 format.
#define FT8XX_OPT_RIGHTX 2048 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
The label on the Coprocessor widget is right justified.
#define FT8XX_OPT_SIGNED 256 |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
The number is treated as 32 bit signed integer.
void ft8xx_copro_cmd | ( | uint32_t | cmd | ) |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Execute a display list command by co-processor engine.
cmd | Display list command to execute |
void ft8xx_copro_cmd_calibrate | ( | uint32_t * | result | ) |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Execute the touch screen calibration routine.
The calibration procedure collects three touches from the touch screen, then computes and loads an appropriate matrix into REG_TOUCH_TRANSFORM_A-F. To use it, create a display list and then use CMD_CALIBRATE. The co-processor engine overlays the touch targets on the current display list, gathers the calibration input and updates REG_TOUCH_TRANSFORM_A-F.
result | Calibration result, written with 0 on failure of calibration |
void ft8xx_copro_cmd_dlstart | ( | void | ) |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Start a new display list.
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Draw a decimal number.
By default (x
, y
) is the top-left pixel of the text. FT8XX_OPT_CENTERX centers the text horizontally, FT8XX_OPT_CENTERY centers it vertically. FT8XX_OPT_CENTER centers the text in both directions. FT8XX_OPT_RIGHTX right-justifies the text, so that the x
is the rightmost pixel. By default the number is displayed with no leading zeroes, but if a width 1-9 is specified in the options
, then the number is padded if necessary with leading zeroes so that it has the given width. If FT8XX_OPT_SIGNED is given, the number is treated as signed, and prefixed by a minus sign if negative.
x | x-coordinate of text base, in pixels |
y | y-coordinate of text base, in pixels |
font | Font to use for text, 0-31. 16-31 are ROM fonts |
options | Options to apply |
n | The number to display. |
void ft8xx_copro_cmd_swap | ( | void | ) |
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Swap the current display list.
#include <include/zephyr/drivers/misc/ft8xx/ft8xx_copro.h>
Draw text.
By default (x
, y
) is the top-left pixel of the text and the value of options
is zero. FT8XX_OPT_CENTERX centers the text horizontally, FT8XX_OPT_CENTERY centers it vertically. FT8XX_OPT_CENTER centers the text in both directions. FT8XX_OPT_RIGHTX right-justifies the text, so that the x
is the rightmost pixel.
x | x-coordinate of text base, in pixels |
y | y-coordinate of text base, in pixels |
font | Font to use for text, 0-31. 16-31 are ROM fonts |
options | Options to apply |
s | Character string to display, terminated with a null character |