HD44780 Library update!

Since printing floating points is probably much more important than the speed of this library, I’ve included a new function that allows the printing of floating point numbers! The function explanation is really simple and here it is:

int8_t PNumF(float Num, uint8_t X, uint8_t Y, uint8_t Prec)
Just like with the standard PNum function, this function accepts the number, the X and Y position on the screen along with an extra parameter called “Prec” (short for precision). This Prec parameter defines to what level the screen should print to. This is currently undefined for Precs larger than the amount of decimal points. For example, printing the number “1.0001” with a Prec of 2 will print “1.00”. Printing the same number with a Prec of 4 will print “1.0001” where as printing the same number with a Prec of 5 will print “1.0001X” where the X is an undefined number.

As always, you can find the updated version of the library in my github: https://github.com/pyrohaz/STM32F0-HD44780LCD


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s