PebbleOS v4.47.0-160-g9e782207f
Loading...
Searching...
No Matches
Print

Plain text for the system's own messages, such as the boot banner. More...

Typedefs

typedef void(* pbl_print_output_t) (const char *data, size_t len)
 Output of pbl_print().
 

Functions

void pbl_print_set_output (pbl_print_output_t output)
 Set where pbl_print() writes.
 
void pbl_print (const char *fmt,...)
 Print formatted text.
 
void pbl_vprint (const char *fmt, va_list ap)
 pbl_print() with a va_list.
 

Detailed Description

Plain text for the system's own messages, such as the boot banner.

Text goes to the output registered with pbl_print_set_output(), usually the console, before pbl_print() returns. It is never filtered or recorded: logging is for that. It works from any context, before the scheduler runs too, and is dropped while there is no output.

pbl_print("*** Booting PebbleOS %s ***\n", PBL_VERSION_TAG);
void pbl_print(const char *fmt,...)
Print formatted text.

Typedef Documentation

◆ pbl_print_output_t

typedef void(* pbl_print_output_t) (const char *data, size_t len)

Output of pbl_print().

Parameters
dataText, without a terminating NUL.
lenLength of data in bytes.

Function Documentation

◆ pbl_print()

void pbl_print ( const char *  fmt,
  ... 
)

Print formatted text.

Lines end with a newline the caller writes.

Text is cut at CONFIG_KERNEL_PRINT_BUFFER_SIZE - 1 bytes per call.

Parameters
fmtprintf-style format.
...Format arguments.

◆ pbl_print_set_output()

void pbl_print_set_output ( pbl_print_output_t  output)

Set where pbl_print() writes.

Parameters
outputOutput, or NULL to drop the text.

◆ pbl_vprint()

void pbl_vprint ( const char *  fmt,
va_list  ap 
)

pbl_print() with a va_list.

Parameters
fmtprintf-style format.
apFormat arguments.