rpi.gpio refers to the package name of a Python module for accessing the Raspberry Pi's GPIO pins. The module allows GPIO pins to be initialised, turned on, and turned off. It uses a functional programming style.

learn more… | top users | synonyms

0
votes
1answer
11 views

Multiple rotary encoder raspberry pi 12C GPIO

I found this PEC11-4215F-S24 rotary encoder on Adafruit (https://www.adafruit.com/products/377) and I want to use three of them - or another rotary encoder - to use it in my Raspberry Pi project. I ...
1
vote
0answers
8 views

Hardware Volume Control - Runeaudio - HifiBerry Amp+ - Python

Okay, so I am building a sweet vintage style boombox for my nana using a RCA Victor X551 case, a Rpi3, running runeaudio. I have most of everything figured out, but could use some help with the ...
1
vote
0answers
19 views

Web interface to monitor and execute python script [duplicate]

I am building an automated piece of lab equipment. Overall the system works as follows: Python -> Rpi GPIO -> relays -> Actuators (on delay-> off delay, repeat) This loop runs for about 48 hours. I ...
0
votes
0answers
13 views

Do I need any driver to use this display with rpi 2b+? [duplicate]

Can i use a mpu-8080 8-bit parallel interface driven with the DA8620 driver ic with the rpi 2B+ without any driver, just after first boot by connecting the display to the rpi. And second question: how ...
0
votes
0answers
15 views

Serial data rate change intInterface using pi zero

I have serial control link between operator's control panel and explosives handling robot vehicle. Both control and robot use old microprocessor/firmware limited to 4800 baud rate. Needed upgrade ...
1
vote
1answer
37 views

Python picamera exposure_mode night not working

This program is coded within Python. As I wanted to get my raspberry to be aware of the current time(night or day) and being able to upload a video that is using night vision from the normal cam....
1
vote
1answer
33 views

Using a Pi B with a 40pin GPIO paddleboard?

I posted a question a while back about interfacing GPIO pins directly into a breadboard. Someone replied use a paddleboard/cobblerboard! and so I did. I bought this paddleboard. But... It'...
2
votes
1answer
46 views

Why can I connect to the GPIO pins using the gpio program, but not with the Python package RPi.GPIO?

I have a Raspberry Pi A+ and I'm running Raspbian GNU/Linux 8.0 (jessie). When I use the gpio command in bash I can connect to the GPIO ports, for example turning on a LED: gpio mode 25 out gpio ...
0
votes
1answer
35 views

Sunfounder temperature sensor module

I have a Sunfounder temperature sensor module and a Raspberry Pi 2 Model B. I want to use this to create a temperature logger, but nothing is working as I expected it too. The temperature sensor has ...
1
vote
0answers
20 views

Building MRAA for Java on Pi 2 B (raspbian)

i'm trying to use the MRAA lib to program the pins with java, but when I built the files, I can't find where the path was set, idealy it would be set on /usr/lib, but there's no mraa. Without it I can'...
1
vote
0answers
40 views

GPIO unexpected behaviour after 10 hours of running python script

I have a python script running as a service on Raspbian Jessie that watches for a button being pressed and lights an LED when it is done. Initially everything works as designed, however I have found ...
0
votes
1answer
48 views

GPIO not working as i want

Yesterday I received my raspberry pi 3 and installed Raspbian. I am trying to use it with this relay, but when i tried to use GPIO using the commands like echo 4 > /sys/class/gpio/export The ...
1
vote
1answer
21 views

Raspberry pi 2 - Check if anything is connected to the pin

I am making a game with the raspberry pi, which can be played for 1-4 players. I just wanted to know, if there is a way to count the number of buttons connected. I want to determine the number of ...
0
votes
2answers
70 views

GPIO control relay with button

I'm wondering if it's possible to have my momentary button control a relay in Python whilst I'm holding the button down? Currently, I'm able to control the relay with a small python script, switching ...
1
vote
1answer
54 views

TypeError: not all arguments converted during string formatting Raspberry Pi

This program is pretty simple. Whenever a user waves both hands across 2 PIR sensors, it should print out a message in console that displays which GPIO ports has being activated. The raspberry pi uses ...
1
vote
0answers
31 views

Why do I need to run GPIO as root even with GPIO Ver 0.6.2? [duplicate]

Trying to use GPIO in Python, but it only works if I change to root. Why? The description for GPIO Ver 0.6.2 indicates that root is no longer needed?
1
vote
1answer
47 views

Detect GPIO button press within time limit

I've got a photo booth program I'm working on that takes the photo of the user and displays it on the screen for 5-10 seconds. At the end of that 5-10 seconds, I'd like the booth to reset unless a ...
1
vote
1answer
71 views

SPI control of WS2801 LEDs, fails when using GPIO interrupts

I have three libraries (is library the right word?) that I'm using in my Python code: An Adafruit NeoPixels library, which comes from the rpi_281x library to control them via PWM, on GPIO pin 18. ...
1
vote
1answer
100 views

How would I make this python script keep running and not just stop after running once?

Im working on a game for my RPi3 B running raspbian, whenever I run this py script from the command line it runs once and stops, I would like it to stay open and keep running as it waits for a knock ...
0
votes
1answer
94 views

Problems with GPIO Edge Interrupts

I have the following circuit hooked up with a big button. Note: I am actually using a Pi Zero, not a Pi 2. I took some code from this example to run the following python script: #!/usr/bin/env ...
0
votes
0answers
42 views

Why after adding GPIO.cleanup to my code it still show the GPIO channel warning?

I wrote some python to blink a led. Without the GPIO.cleanup method, I had the following warning: "This channel is already in use, continuing anyway". Then I did tempo=1 import RPi.GPIO as GPIO ...
1
vote
1answer
170 views

PIR Sensor Consistent False Positives

So, I'm trying to set up my raspberry pi to take input from a PIR sensor in order to automatically turn on a monitor when it detects motion. If no motion has been detected in 60 seconds, the monitor ...
0
votes
0answers
23 views

Why do my motors stop running properly upon second click?

My PHP files run motors, Forward.php makes them go one direction and Backward.php in the opposite. For some reason when I open the page and I for example press the up button it works fine, the motors ...
1
vote
1answer
56 views

GPIO pin Status

Is it possible to know if there is something plugged on the pins ? I made a web interface to control the Raspberry pi 3 remotely and I want to activate the pin where the relay is pluged but I don't ...
5
votes
1answer
66 views

How to Check GPIO pins simultaneously?

Can you give me an idea on how to check the statuses of specific GPIO pins if it is HIGH or LOW? My project is all about checking the statuses of GPIO pins (6 GPIO pins). I want to check all of the ...
0
votes
0answers
123 views

ImportError: No module named RPi.GPIO

I have installed RPi.GPIO. The RPi.GPIO works on python independently, but when I try to import RPi.GPIO on opencv2, I get an error: Traceback (most recent call last): File "cam.py", line 2, in <...
0
votes
0answers
31 views

Callback fired multiple times for GPIO

I put together a relay controller for some light and sound effects for a parent production at my son's school. I have very lax timing requirements, but my callbacks are intermittently firing 1,2, and ...
2
votes
0answers
43 views

How Can I Properly Ground My RPI To Avoid Static Interference?

I have researched every where for this problem and cannot find a direct answer. I am currently working on a project which involves a large 20ft conveyor belt transferring product into a Plexiglas box ...
0
votes
1answer
61 views

Raspberry Pi 2 Pin once set to high does not return to low

I'm using a Raspberry Pi 2. Part of my project requires the Pi to activate relays, for which I intend to make a pin high for a while and then return to low. However once I set a pin to high, it ...
0
votes
2answers
48 views

Using GPIO pins 14 and 15 as general purpose

I understand that in order to use these two pins as general purpose I will need to disable UART. I tried following these instructions but /etc/inittab doesn't exist on raspberry pi 2 as far as I can ...
0
votes
1answer
239 views

I can't get three LED lights to turn off and on in an order

I'm setting up 3 LED lights to turn on automatically in a specific order using a Raspberry Pi 3. I coded it with Python. At first I had two and it worked. Then, I added a third with the same program ...
0
votes
0answers
92 views

unable to fix ERROR Can't open the device /dev/ttyUSB0 (No such file or directory)

I tried running an object file which worked before but now when I run it it throws an error stating ERROR Can't open the device /dev/ttyUSB0 (No such file or directory).I'm using Jessie lite. pi@...
3
votes
2answers
348 views

How do I make a device tree overlay for just a single GPIO?

How do I make a device tree overlay which turns GPIO 7 on my Raspberry Pi Rev 2 Model B to a HIGH OUTPUT pin? EDIT: I require the pin to be this way as early as possible. That is why I am thinking of ...
0
votes
1answer
24 views

Which GPIOs are OUTPUT and HIGH at startup?

I need such a GPIO for an LED that must be on as soon as possible after the PI is started up. I've played with the device trees but documentation on those is sparse (in my opinion).
1
vote
1answer
309 views

i2cdetect on Raspberry Pi kernel 4.1.18-v7+ takes 115 seconds

I have tried on two different Pi's (2 and zero) with fresh installs and have the same problem. I have i2c enabled via device tree via raspi-config. When I run i2cdetect -y 1 without anything plugged ...
4
votes
1answer
149 views

Can you connect multiple GPIO pins, to one ground pin?

I'm questioning whether connecting multiple GPIO pins (which to my knowledge are 3 volts), to one ground pin, is going to damage my Raspberry? I want to connect GPIO pins to breadboard, pass the ...
0
votes
0answers
45 views

L298N Stepper Driver in separate thread

I have a 2 NEMA 17 stepper motors and for each motor I'm using the L298N driver. It works great on my rpi using gpio and I'm able to have decent control of the steppers. My question is how can I ...
-1
votes
1answer
108 views

webiopi simple 3 wheeled robot, not functioning

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; ...
0
votes
1answer
198 views

GPIO.wait_for_edge on 2 channels at once?

So, I have 2 buttons set up on pins 17 and 27. buttons = (17, 27) GPIO.setup(buttons, GPIO.IN, pull_up_down=GPIO.PUD_UP) I need to accept input from EITHER of these for a set period of time. I ...
0
votes
1answer
80 views

Blink script gives me “name error 'BCM' is not defined”

I recently purchased a Raspberry Pi 2 and I am trying to run a simple a simple Blink program but getting this error: name error 'BCM' is not defined This is my script import RPi.GPIO as GPIO ...
2
votes
2answers
170 views

How can I disable GPIO warnings?

I get the following warning: Python says to add this command GPIO.setwarnings(False). Where do I put this command, in the file or in some system file?
1
vote
0answers
67 views

starting and ending a script with a buttonpress

I'm trying to integrate a button into a simple alarm project of mine but am having trouble activating/deactivating the alarm with a button press. Using Raspberry Pi 2 - Raspbian Jessie My wiring is ...
1
vote
2answers
765 views

GPIO=webiopi.GPIO, attribute error : module object has no attribute 'GPIO'

With this Python script I am getting errors: import webiopi import math GPIO = webiopi.GPIO # Left motor GPIOs L1=4 L2=17 # Right motor GPIOs R1=19 R2=21 def left_stop(): GPIO.output(L1,...
0
votes
0answers
45 views

R-Pi B+ PWM pulse outputted counter

I am relatively new to using R-Pis I have a question with counting number of pulses. The task that I have is counting the number of pulses that the R-Pi is outputting. I am using the .PWM function. ...
0
votes
2answers
49 views

Driving a 4 digit 7 segment common cathode from GPIO

I have 8 330 ohm resistors wired up to 8 gpio pins (8 anodes), then I have the 4 cathodes wired to 4 other gpio pins. I tested all my connections with a multimeter and everything looks good. Then when ...
0
votes
1answer
88 views

Wiegand GPIO read not working all the time. Works most times but hangs on some reads

I'm extremely new to Python, I've been learning a bit over the last couple weeks. This is what I've managed to come up with. I'm pretty over the moon the code works most of the time but it doesnt work ...
5
votes
1answer
572 views

I need to control 8 LED's but I can only control 3? [helpful pictures attached]

I'm very new to electronics in general, but I want to build a small project where I can individually control (from a GPIO pin) 8 LED's. From what I understand, each GPIO pin on the Pi (Pi2 model B V1....
1
vote
1answer
283 views

GPIO True and False seem to be reversed

I'm using the GPIO pins on my Pi under Raspian to control a relay and a computer fan. In Python 2, the command GPIO.setup (18, GPIO.OUT) Immediately supplies power to the pin and triggers the relay....
1
vote
1answer
48 views

Issue with reading GPIO pin with GPIO.IN

In one of scripts we are sending HIGH to pin 17, import RPi.GPIO as GPIO GPIO.setmode(GPIO.BCM) GPIO.setup(17, GPIO.OUT) GPIO.output(17,GPIO.HIGH) And in another script reading GPIO as, import ...
1
vote
4answers
516 views

How to connect a graphic card to Raspberry pi?

I want a way to connect a graphic card like nvidia or amd to raspberry pi do you think has a way to do that?