1.2.4.4.13 SYS_CONSOLE_Print Function
1.2.4.4.13 C
void SYS_CONSOLE_Print(const SYS_CONSOLE_HANDLE handle, const char *format, ...)
1.2.4.4.13 Summary
Formats and prints a message with a variable number of arguments to the console.
1.2.4.4.13 Description
This function formats and prints a message with a variable number of arguments to the console.
1.2.4.4.13 Precondition
SYS_CONSOLE_Initialize must have returned a valid object handle.
1.2.4.4.13 Parameters
| Parameters | Description |
|---|---|
| handle | Handle to a console instance |
| format | Pointer to a buffer containing the format string for the message to be displayed |
| ... | Zero or more optional parameters to be formatted as defined by the format string |
1.2.4.4.13 Returns
None.
1.2.4.4.13 Example
SYS_CONSOLE_HANDLE myConsoleHandle; myConsoleHandle = SYS_CONSOLE_HandleGet(SYS_CONSOLE_INDEX_0); uint8_t num_bytes_to_enter = 10; if (myConsoleHandle != SYS_CONSOLE_HANDLE_INVALID) { // Found a valid handle to the console instance SYS_CONSOLE_Print(myConsoleHandle, "Enter %d characters", num_bytes_to_enter); }
1.2.4.4.13 Remarks
The format string and arguments follow the printf convention. Call SYS_CONSOLE_PRINT macro to print on the default console instance 0.
