writing my own print function

Status
Not open for further replies.

If I use const char, then how would I call the printf_uart function.

for example, unsigned const char *strln1="error1";

How would I call the function - printf_uart(strln1); ?
 

void printf_uart(const unsigned char *str);

...

const unsigned char *msg1 = "error1";
const unsigned char *msg2 = "error2";

...

void printf_uart(const unsigned char *str){



}

...

printf_uart(&msg1);
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…