Patch oled help

I have a patch. I have the DaisySP installed and setup. I have the DaisyExamples. I have a simple program running and flashed. It’s working but the oled is not displays a variable value. I’m reading a control knob value but oled doesn’t display the value.

Here is a snippet from the while loop in main(). The value of formula_index displays but the value of speed does not display.

patch.display.Fill(false);
patch.display.SetCursor(0, 0);
patch.display.WriteString("Bytebeat Synth", Font_7x10, true);

char buffer[32];  
snprintf(buffer, sizeof(buffer), "Speed: %.2f", speed); // !!! Doesn't display !!!
patch.display.SetCursor(0, 12);
patch.display.WriteString(buffer, Font_7x10, true);

snprintf(buffer, sizeof(buffer), "Formula: %d", formula_index); // *** Does display ***
patch.display.SetCursor(0, 24);
patch.display.WriteString(buffer, Font_7x10, true);

speed is declared at the top as: float speed = 0.0f;. I’m getting the knob value with speed = patch.GetKnobValue(static_cast<DaisyPatch::Ctrl>(0)) * 4.0f + 0.1f;

libDaisy doesn’t include float formatting by default, for efficient RAM use.
If you want float support, add this line to the project Makefile:
LDFLAGS = -u _printf_float

Thanks for the reply. Is there another alternative to handle this more efficiently?

Try Google ‘printing floats without printf’.