We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Greetings,
I'm still not able to get my printf to work.
I have found a few threads within regarding changing the putchar (and getchar) - that is - changing the names of sbuf within.
Here's what I tried:
char putchar(char c) { while (!TI); /* wait until transmitter ready */ TI = 0; SBUF0 = c; /* output character */ return (c); }
This is from a thread here on this forum. I see nothing out of txd with my scope.
I have confirmed that this bit of code works: while (TI); /* wait until transmitter ready */ SBUF0 = 0x0D; /* output character */ while (!TI); /* wait until transmitter ready */ TI = 0;
so I know my txd works.
I think my program is still going to a different putchar routine.
How do I "tell" it to go to my new putchar. I have the putchar within my .c program and have moved the .lib to a different location.
Thanks -Chuck