Multi-digit number for block


#1

I am currently trying to make an extension for mBlock5 with the Extension Builder, which allows to swipe different palettes of custom char for LCD Screens. So that it is possible to save more than 8 different char on the LCD screen. One block requires a 5-digit entry of ones or zeros. (1st line: 00101 …)

How do I get this done?
I could not use a string, otherwise the output is “00101”?

And I couldn’t use Numbers because it only prints 101? (00101 is the “same number” as 101)


byte “obj”[8] =
{
B"00000", B"00000", B"00000", B"00000", B"00000", B"00000", B"00000", B"00000"
};

and

lcd.createChar(1, “obj”);


#2

Hi Ckoever,
Do you mean to convert binary strings into decimal digits?
You can use parseInt(num,2)
image
Thanks.