zephyr/samples/subsys/display/cfb_custom_font
Alain Volmat 5c856ca532 samples: display: cfb_custom_font: allow -ENOSYS blanking error
The display blanking API mentions that display_blanking_on
and display_blanking_off should return -ENOSYS if it is not
implemented by the driver. It should not be considered as
an error since it might not be needed in order to have the
display work correctly.

Signed-off-by: Alain Volmat <alain.volmat@foss.st.com>
2025-05-07 08:17:52 +01:00
..
fonts
src samples: display: cfb_custom_font: allow -ENOSYS blanking error 2025-05-07 08:17:52 +01:00
CMakeLists.txt
prj.conf
README.rst
sample.yaml

.. zephyr:code-sample:: cfb-custom-fonts
   :name: Custom fonts
   :relevant-api: monochrome_character_framebuffer

   Generate and use a custom font.

Overview
********
A simple example showing how to generate Character Framebuffer (CFB)
font headers automatically at build time.

This example generates a font with font elements for 6 sided dice from
a PNG image, and then uses the generated header (``cfb_font_dice.h``)
to show the font elements on the display of a supported board.

The source code for this sample application can be found at:
:zephyr_file:`samples/subsys/display/cfb_custom_font`.

Building and Running
********************

There are different configuration files in the cfb_custom_font
directory:

- :file:`prj.conf`
  Generic config file, normally you should use this.

- :file:`boards/reel_board.conf`
  This overlay config enables support for SSD16XX display controller
  on the reel_board.


Example building for the reel_board with SSD16XX display support:

.. zephyr-app-commands::
   :zephyr-app: samples/subsys/display/cfb_custom_font
   :host-os: unix
   :board: reel_board
   :goals: flash
   :compact: