7 years, 9 months ago.

Text Render Problem With HD44780 16x2 LCD

Hello.

I have an HD44780 compatible, 16x2 text LCD connected to my FRDM-KL25Z. And regardless of what I try, the LCD will render a line of blocks, or incorrect characters. My code is thus:

#include "mbed.h"
#include "TextLCD.h"

TextLCD lcd( PTE0, PTE1, PTE2, PTE3, PTE4, PTE5, TextLCD::LCD16x2 );

int main() {
    lcd.printf( "Hello World" );
}

When run, the LCD displays a line of blocks on the first line, and an empty second line. If I replace "Hello World" with "?", it displays the number 3. I believe I am probably overlooking something glaringly obvious, but I cannot figure out what it is. I am fairly new to MCU development and very new to mbed, having just acquired the FRDM-KL25Z yesterday.

Any insight would be greatly appreciated.

https://goo.gl/photos/qbVRBoAFrHtq3oeUA

Question relating to:

The FRDM-KL25Z is an ultra-low-cost development platform for Kinetis L Series KL1x (KL14/15) and KL2x (KL24/25) MCUs built on ARM® Cortex™-M0+ processor. Features include easy access to MCU I/O, battery-ready, …
Be the first to answer this question.