Printf | Developers

Printf

Estimated reading time: One minute

The firmware supports the PRINTF macro debugging feature, which is defined it in the Makefile.
DEFINES += HAVE_SPRINTF HAVE_PRINTF PRINTF=screen_printf

You can use PRINTF with the Speculos emulator.

Usually, PRINTF is defined as void, with this line DEFINES += PRINTF\(...\)=.
Check if PRINTF is already defined somewhere in your Makefile, and if so, comment out this definition so it doesn’t override.

Important
The PRINTF macro is a debugging feature, it must not be used in production.
When compiling an application for release, please check that PRINTF is disabled in the Makefile:
insert the line DEFINES += PRINTF\(...\)= and comment out the other one.

Did you find this page helpful?


How would you improve this page for developers?



Speculos emulator
PIN bypass
Getting Started
Theme Features
Customization

Embedded Apps