Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 2 months ago.
printf: Why so much memory?
All, This may not be a problem. May be worth a (second) look by an admin
I use LPC812 max. When I include printf as a part of a serial port, it increase the code size by about 3kb. puts doesnt seem to take this much space. Given a 16kb code size, i thought this was quite high
Best Regards Siva S
3 Answers
9 years, 2 months ago.
I assume this is for display purposes?
On a more constructive note, if you are interfacing a display, then you can choose a display where you do not need to use the printf function. For instance this display:
This code works for me when using the LPC812:
https://developer.mbed.org/users/shimniok/code/DigoleSerialDisp/
Hope this helps
9 years, 2 months ago.
puts() puts out a string, printf() has to interpret the % and build a string.