Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

4x20 I2C LCD display (HD44780) with Banana Pi not working

Featured Replies

Hello,

 

I have a 4x20 LCD display (with an HD44780 compatible adaptor) connected to my Banana Pi. It is running (freshly installed, switched from Bananian) on the mainline kernel:

Linux bpi 4.9.7-sunxi #1 SMP Thu Feb 2 01:52:06 CET 2017 armv7l GNU/Linux

However, the display is not recognized. I checked the wire connections multiple times, they're okay and the backlight is on.

 

So I assume this is a software issue. The output of "i2cdetect -y 1" is:

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --                         

which leads me to the consideration that it is not even recognized by the system.

 

I did the following things - without success:

  • run "apt-get dist-upgrade" (where some 404 errors occured, see this topic for details)
  • installed "i2c-tools" and "python-smbus"
  • loaded "i2c-dev" kernel module

 

According to the documentation https://docs.armbian.com/Hardware_Allwinner/#connect-your-lcd-display, the I2C stuff should work out of the box in the mainline kernel.

 

Any help would be appreciated. :)

 

Best regards and thanks in advance,

Norbert Kahl

  • Author

I am using a "normal" Banana Pi, not a Pro or M2 model.

 

There are two I2C-busses here:

root@bpi:/dev# ls /dev/i2c-*
/dev/i2c-0  /dev/i2c-1

On the 0-bus, there is "something" detected but I guess it belongs to the system or internal hardware, not to the display:

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- UU -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- 

The 1-bus is just blank. :(

  • Author

Sorry for all the rush. It was the length of the cable (> 2 metres) which caused this error, since pull-up resistors and terminators are required at that length. Just another I2C-Newbie... :)

 

When using jumper wire (~ 20cm), it works, the LCD display appears as 0x27 on I2C-1.

 

Thanks for all the help!

 

Best regards,

Norbert Kahl

  • Author

Yep, and with the pull-up resistors, everything works fine now.

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.