Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
8 years, 5 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.