Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

writing my own print function

Status
Not open for further replies.
RFDATA_BUF[102]; Is there enough ram available?

Try const unsigned char for all your messages and use const unsigned char * as argument for your function. RFDATA_BUF[] has consumed 102 bytes of RAM. Remove your function and Compile and see how much RAM and ROM is left free.

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

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top