12 years ago.

Terminal Buffer?

Hi all,

as my first question I am looking for a solution to my problem with the mbed LPC1768. I connected it both to my Windows PC running TeraTerm and Linux Terminal and it seems that the Terminal in both cases is buffering the "printf's" which I have written in my mbed program. So the Terminal seems to wait for/buffer a specific amount of characters and THEN writes it on the Terminal Screen. Why? And how can I fix this problem?

Thanks in advance!

Hello,

can you share how you print, do you flush the buffer? Or do you use "\n" ?

Regards,
0xc0170

posted by Martin Kojtal 26 Sep 2013

2 Answers

MX MXX
poster
12 years ago.

Great, it works now. Problem was the missing "\n". Thanks for prompt replies!

12 years ago.

It could also be the mbed that is doing it, depending on how the printf is called iirc (and can be manually changed).

If you end your printf statements with \n it should work correctly.