Forum
  • Search
  • Member List
  • Calendar
Hello There, Guest! Login Register — Login with Facebook

[PROBLEM] ImportError: No module named RPi.GPIO
Thank you for your donation

Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Threaded Mode | Linear Mode
Problem: ImportError: No module named RPi.GPIO
18th Apr, 2015, 06:14 PM
Post: #1
Alfox Offline
Registered
Posts: 2
Joined: Apr 2015
Reputation: 0
ImportError: No module named RPi.GPIO
Can you help me?
I 've just bought a raspberry with an electronic starter kit for raspberry called Monkmakes.
I installed Xbian on Raspberry, and now I want to try some programs to controll GPIO.
I downloaded a set of programs by their site.
One of this program is
Code:
import RPi.GPIO as GPIO
import time

# Configure the Pi to use the BCM (Broadcom) pin names, rather than the pin pos$
GPIO.setmode(GPIO.BCM)

red_pin = 18

GPIO.setup(red_pin, GPIO.OUT)


try:
    while True:
        GPIO.output(red_pin, True)  # LED on
        time.sleep(0.5)             # delay 0.5 seconds
        GPIO.output(red_pin, False) # LED off
        time.sleep(0.5)             # delay 0.5 seconds
finally:
    print("Cleaning up")
    GPIO.cleanup()


I attempt to launch this code
but there is this message:

Code:
Traceback (most recent call last):
  File "01_blink.py", line 5, in <module>
    import RPi.GPIO as GPIO
ImportError: No module named RPi.GPIO
Then I followed this guide http://www.raspberrypi-spy.co.uk/2012/05/install-rpi-gpio-python-library/
Method 2 – Manual Installation

but nothing is changed

I don't understand what I must do and I don't know the version of python, and the last version of RPi.GPIO-0.5.11
Find all posts by this user
Quote this message in a reply
21st Apr, 2015, 09:47 PM
Post: #2
Alfox Offline
Registered
Posts: 2
Joined: Apr 2015
Reputation: 0
RE: ImportError: No module named RPi.GPIO
Is anyone?
Find all posts by this user
Quote this message in a reply
17th Sep, 2015, 07:07 PM
Post: #3
Skywatch Offline
Registered
Posts: 1,018
Joined: Mar 2013
Reputation: 28
RE: ImportError: No module named RPi.GPIO
I have the same issue today! Researching it now....
Find all posts by this user
Quote this message in a reply
« Next Oldest | Next Newest »
Post Reply 


  • View a Printable Version
  • Send this Thread to a Friend
  • Subscribe to this thread
Forum Jump:

Current time: 22nd May, 2025, 07:23 AM Powered By MyBB, © 2002-2025 MyBB Group.