Topic : using sprintf to convert float to string

Forum : Ride IDE

Original Post
Post Information Post
March 28, 2019 - 3:00pm
Sylvain LAURENT

Hi,

I'm using sprintf to convert a float variable into a string buffer.

Float vFloat = 10.3;

unsigned char vChaine[10];

sprintf(vChaine,"valeur=%f",vFloat);

--------------------------------

This example send into the buffer : "valeur=f", and I don't understand why ?