User avatar
gdw35
Posts: 29
Joined: Thu Nov 15, 2012 10:46 am
Location: Paris, France

Adafruit_CharLCD fails due to get_platform_gpio error. Help!

Sun Apr 29, 2018 12:44 pm

Since updating my Pi to Raspbian Jessie my Adafruit RBG LCD panel has not worked. Everything is up to date but when trying to run the apps I developed and even the test applications they all fail.

The error is always the same:

Code: Select all

...
File "/home/pi/Lib/Adafruit_CharLCD.py", line 95, in Adafruit_CharLCD
    gpio=GPIO.get_platform_gpio(),
 File "build/bdist.linux-armv7l/egg/Adafruit_GPIO/GPIO.py", line 420, in get_platform_gpio
ImportError: No module named Adafruit_BBIO.GPIO
Doing a search for fixes I have been able to determine that the problem exists because get_platform_gpio is failing, or returning the wrong platform information, so it is trying to load the code for a Beagle Board, which I do not have.

Is someone able to offer some advice on how I can fix this? I tried digging into the Adafruit distribution to look at the code where it failed but it is stored in an egg and I do not know how to access to manipulate these.

Thanks in advance for any help.

User avatar
B.Goode
Posts: 10356
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Adafruit_CharLCD fails due to get_platform_gpio error. Help!

Sun Apr 29, 2018 12:51 pm

You will certainly find previous discussions of the same issue in these forums.

I can't easily check the details just now, but I have a feeling that the Adafruit code you are using has been superceded by a later version that does not have the platform detection bug you are experiencing.

User avatar
gdw35
Posts: 29
Joined: Thu Nov 15, 2012 10:46 am
Location: Paris, France

Re: Adafruit_CharLCD fails due to get_platform_gpio error. Help!

Sun Apr 29, 2018 3:42 pm

Thanks for your reply.

Your mention that the Adafruit code had been updated made me think about it a bit more. I had only updated the Adafruit_CharLCD packages. I updated the Adafruit_GPIO package as well and the problem was resolved.

User avatar
B.Goode
Posts: 10356
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Adafruit_CharLCD fails due to get_platform_gpio error. Help!

Sun Apr 29, 2018 3:55 pm

Thanks for the feedback and explanation. Congratulations on resolving your problem.

Return to “Troubleshooting”