8245 views|0 replies

291

Posts

5

Resources
The OP
 

[CY8CKIT-149 PSoC 4100S Review] + LCD Usage [Copy link]

Continue to study the official routines. This time, I use the I2C_LCD example. For the opening method of the routine, please refer to the steps of opening the PWM routine before. Because there is only LCD1602 at hand and there is no I2C interface, I changed it to LCD1602 in this routine. According to the basic configuration circuit of LCD1602, I made a small adapter board for easy wiring, as shown below. The 3rd pin VO is used to adjust the brightness of the font. I found a 330 ohm resistor. The size depends on the specific LCD. It is best to connect an adjustable resistor. In addition, the pin header should be soldered on the PSoC4100 board for connecting LCD1602. Open the routine, add a Character_LCD module, and rename it LCD_1602. Double-click the module. Leave the default settings unchanged. Click Datesheet to view the LCD help document. You can find the interface usage in the document. You only need to use the 4 data bits of DB6-DB7 of LCD1602, plus 3 control bits. Go to the pin assignment page. Only care about the ones we added in the red box. You can use the default assigned pins 0.0-0.6. Let's modify the main function: int main(void) { CyGlobalIntEnable; LCD_1602_Start(); LCD_1602_Position(0,0); LCD_1602_PrintString("PSOC4100 LCD1602"); LCD_1602_Position(1,0); LCD_1602_PrintString("hello eeworld ! "); for(;;) {} } The final effect is as follows:

This post is from MCU
 

Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list