Re: [avr-gcc-list] sprintf problem

2006-01-25 Thread Parthasaradhi Nayani
Hello all,The problem I posted here has been rectified by using a dummy malloc, allocating about 10 bytes. This is for information only. Thank you.RegardsNayani P Bring words and photos together (easily) with PhotoMail - it's free and works with Yahoo! Mail._

Re: [avr-gcc-list] sprintf problem

2006-01-24 Thread Parthasaradhi Nayani
Joerg Wunsch <[EMAIL PROTECTED]> wrote:<[EMAIL PROTECTED]>Are you running out of memory? Seems like the malloc() of theconversion buffer failed.-- Hello,I have checked .data and .bss sizes both put together ocupy 2200 bytes approximately. I have also checked the Stack Pointer by sending its conten

Re: [avr-gcc-list] sprintf problem

2006-01-24 Thread Joerg Wunsch
Parthasaradhi Nayani <[EMAIL PROTECTED]> wrote: > The float converted string is missing. Are you running out of memory? Seems like the malloc() of the conversion buffer failed. -- cheers, J"org .-.-. --... ...-- -.. . DL8DTL http://www.sax.de/~joerg/N

Re: [avr-gcc-list] sprintf problem

2006-01-24 Thread Parthasaradhi Nayani
Hello all,The problem resurfaced after little more code is added to my program. Optimisation is set to s. Sprintf behaves funny with %f. I am giving below sample code and the outputunsigned char buffer[100];sprintf (buffer,"Hello %f hello\n\r", 34.56);send_2_serial (buffer);the output for the first

[avr-gcc-list] sprintf problem

2006-01-18 Thread Parthasaradhi Nayani
Hello all, In one of my projects (ATMega128 based) I am using floating point numbers and sprintf to write a formatted record to a buffer. Tthe buffer contents is then sent to a mini printer. The first two records print properly and thereafter I am getting garbage from sprintf!! The optimisatio