首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >16X02不显示任何字符

16X02不显示任何字符
EN

Stack Overflow用户
提问于 2019-05-29 18:40:03
回答 1查看 22关注 0票数 0

我想在16X02液晶屏上显示一些字符串。目前,我正在实现以下链接中给出的示例。我的16X02LCD的背光灯亮了,但是没有显示任何字符。我现在该怎么做?

https://www.losant.com/blog/how-to-connect-lcd-esp8266-nodemcu

代码语言:javascript
复制
#include <LiquidCrystal_I2C.h>

// Construct an LCD object and pass it the 
// I2C address, width (in characters) and
// height (in characters). Depending on the
// Actual device, the IC2 address may change.
LiquidCrystal_I2C lcd(0x27, 16, 2); // my lcd pin address is different from the example

void setup() {

  // The begin call takes the width and height. This
  // Should match the number provided to the constructor.

  Serial.begin(115200);
  Serial.println ("In Setup");
  lcd.begin(16,2);
  lcd.init();

  // Turn on the backlight.

  lcd.backlight();

  // Move the cursor characters to the right and
  // zero characters down (line 1).

  lcd.setCursor(5, 0);

  // Print HELLO to the screen, starting at 5,0.

  lcd.print("HELLO");

  // Move the cursor to the next line and print
  // WORLD.

  lcd.setCursor(5, 1);      
  lcd.print("WORLD");
}

void loop() {
}
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2019-06-13 15:16:53

我假设你已经验证了你的物理连接并且提供了合适的电压供应。

您是否使用与GPIO扩展模块PCF8574相同的I2C。如果没有,您可能需要修改LCD模块。

还可以通过调整pot来验证您是否设置了正确的对比度电压。您应该首先将其设置为可以看到所有背景点(像素)的值;一旦文本可见,您可以将其设置为最佳值。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/56358635

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档