Reply by Mikhail Fridberg March 28, 20022002-03-28
On 3/26/02 11:33 AM, "gary21uk2002" <> wrote:

> Hi,
>
> I seem to have endless trouble trying to use LOG_printf() to display
> a floating point value. I am using the latest and greatest CCS (2.1)
> and I'm sure I saw that this includes a fix but it still doesn't work.
>
> If I use
> LOG_printf(&trace,"value=%f",floatvalue);
> I get rubbish - quite possibly mis-interpreted bits.
>
> I'm fed up getting round it using
> LOG_printf(&trace,"value=%de-6",(int)(floatvalue*1e6));
>
> Any help would be appreciated.
>
> I am using CCS2.1 for C6x and a C6711 target via XDS510 JTAG emulator
>
> Cheers,
> ... Gary >
As far as I can remember, Log_printf doesn't support floats. It's described
somewhere in the DSP/BIOS manual. In practice, if I remember right, it was
sort of working, but you couldn't be sure that it put out proper value or
anything at all.
Mike.


Reply by gary21uk2002 March 26, 20022002-03-26
Hi,

I seem to have endless trouble trying to use LOG_printf() to display
a floating point value. I am using the latest and greatest CCS (2.1)
and I'm sure I saw that this includes a fix but it still doesn't work.

If I use
LOG_printf(&trace,"value=%f",floatvalue);
I get rubbish - quite possibly mis-interpreted bits.

I'm fed up getting round it using
LOG_printf(&trace,"value=%de-6",(int)(floatvalue*1e6));

Any help would be appreciated.

I am using CCS2.1 for C6x and a C6711 target via XDS510 JTAG emulator

Cheers,
... Gary