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
2answers
21 views

GPIO is not working, 5V working, 3.3 V working, Raspberry Pi B+

I am the RPi B+ user. Feeling confused about the GPIO. GPIO isn't working. I tried checking it with multimeter by connecting the pin 21 to the gnd, not work. And then i tried the 5 v and 3.3 v, it ...
0
votes
0answers
8 views

Connect Raspberry Pi and Phone to a linux machine [on hold]

As a part of a project, I have to create a connection between my raspberry Pi, a linux server running on another network and a phone which can connect to the server. What this has to do is, if any ...
0
votes
1answer
25 views

HC-SR04 distance sensor doesnt work

I try to make HC-SR04 distance sensor on my rasp pi robot but it doesnt work and I don´t know where is problem. Here is my python code. Program stop in first while loop. VCC is connect to PIN 2. ...
0
votes
1answer
28 views

Is there a way to see which GPIO pins are inuse with the python RPi.GPIO module?

I want to be able to toggle a pin on and off for output. e.g. pin 12 Something like this import RPi.GPIO as io io.setmode(io.BOARD) if not io.pinInUse(12): io.setup(12,io.OUT) else: ...
0
votes
1answer
18 views

Power a docking speaker directly from raspberry pi GPIO pins

I have a raspberry pi plugged into a small portable philips docking station and stream music to it (it's acting as a squeezebox player). At the moment I am running to power supplies, a 9V 2amp for the ...
1
vote
1answer
24 views

Re- Wire a DAC for newer GPIO pin layout

I have a Hifiberry DAC for a model B and would like to use it on b+ or pi 2. I know the GPIO pins have changed from model B layout - would it be possible to figure out the old and new layout ...
2
votes
1answer
61 views

Write floats to gpio

I want to control an LED Strip via the gpio PIns of my Raspberry pi 2. I found some ways for example using Python or WiringPi. But I need to use "non absolute values" like "put Pin 0 to 0.2 and Pin 2 ...
1
vote
0answers
30 views

problem with LED matrix setup with raspberry pi model B+

I have a raspberry pi model B+ , and an 8x8 LED matrix(single colored) , so I connected 8 GPIO pins to the 8 row pins of the matrix and another 8 GPIO pins to the 8 colomn pins. Note that I am pretty ...
2
votes
1answer
56 views

Simulate GPIO pins

I would like to do some simulation of the Raspberry's GPIO pins, e.g. for automated testing and developing the scripts on another host that is not the RPi. Are there any existing ...
1
vote
1answer
149 views

/sys/devices/virtual/gpio dissapears after installing RPi.GPIO on Archlinux ARM

...tinkered a bit with GPIO and Piface Digital. It was all ok until I had installed RPi.GPIO via pip. After that the directory /sys/devices/virtual/gpio disappeared and never showed up again. I had it ...
0
votes
1answer
121 views

ImportError: No module named GPIO

I have install RPi.GPIO 5.3a from here: https://pypi.python.org/pypi/RPi.GPIO i ran the next code: sudo python setup.py install there are no fails on the installing. I will run the next script: ...
0
votes
1answer
33 views

Use OR Operator Between Two GPIO on python [closed]

I am writing a short program in Python on the Raspberry Pi, to stop a while loop by any of the one GPIO from two, but it is not stopping the loop. Although, if I use GPIO individually its successfully ...
3
votes
2answers
123 views

Raspberry Python Libraries

I am currently working with a Raspberry Pi (Model B+) and have some experience with Arduino (and it's derivates). Now, there are three Libs for GPIO access with Python for the Pi: WiringPi ...
1
vote
1answer
65 views

Stop while Loop by GPIO INPUT in Python [closed]

I am writing a program in python on RaspberryPi, to stop While loop through GPIO input. I don't know why it is not working. Can you please look on my coding and guide me to resolved it? import ...
0
votes
1answer
44 views

Change the GPIO pull_up_down=GPIO.PUD_UP to GPIO.PUD_DOWN?

Im working on something similar these link: Connecting a Push Switch But with few changes: LED attached and wish the LED to be high only when the switch is pressed. I tried something like ...
1
vote
2answers
64 views

what is resistance of the GPIO outputs

I am building a simple resistor / capacitor in series (RC) circuit to measure resistance with my RPi A+. RC Design This design is similar to the one used in this tutorial as suggest on this post. ...
2
votes
1answer
123 views

GPIO general use pins stuck in HIGH position

I am trying to do "LED Blink" with GPIO and Python on my RPi B+. I am using my breakout board with a breadboard and am jumping pin 11 (GPIO 17) > resistor > LED > jump to pin 9 (GND). I am using the ...
0
votes
0answers
12 views

what is the INTERRUPT_HOSTPORT?

I am understanding the interrupts in the raspberry pi B+ board and I come across this interrupt INTERRUPT_HOSTPORT And I dont know what it is for? Can u explain me once? Thanks in advance.
0
votes
1answer
64 views

GPIO Connections

I would like to use raspberry pi for measurement of Temperature,Humidity,Motion, soil moisture & distance. I would like to add three led indicators. I'll be using following sensors 1) DHT-11 ...
3
votes
1answer
88 views

Cannot use particular pin in GPIO

I am trying to blink a LED on a Raspberry Pi using GPIO 4 (P1.7). Here is my code: #include <bcm2835.h> #define PIN RPI_GPIO_P1_7 int main() { bcm2835_init(); bcm2835_gpio_fsel (PIN, ...
0
votes
1answer
38 views

How many GND does a RasPi model B rev.2 P1 header have?

I see a lot of conflicting documentation on how many GND pins are available on model B rev. 2.0. I have hardware revision "000e" and there are a lot of DNC (Do Not Connect) pins. ...
1
vote
1answer
251 views

Is it possible to use the mini UART and PL011 UART together on a rpi B+? [duplicate]

How to get more than one uart interface is a quite interesting question that I was not able to fully answer for my rPi Model B+ v.2 - the one with the extended 40pin connectors. To avoid this beeing ...
2
votes
2answers
138 views

I am getting ghosting/bouncing on my digital input

I am meassuring data pulses from my electrical meter, giving me one pulse per Watt used. I have 4 electrical meters connected to my Raspberry Pi model B. I have connected them directly like this (no ...
0
votes
1answer
105 views

i want to set the alt function for the gpio in raspberry pi

I am working on the raspberry pi, doing changes in the machine driver. And there is a hack in the machine driver to change the alt function of one gpio. So i want to remove the hack and want to call ...
5
votes
0answers
189 views

Running RPi on Solar Panel and battery [closed]

I’m quite new in electronic projects and so my basics are quite limited. I've been reading a lot regarding this topic (refer to the title) and I’m currently planning to buy the suitable Solar Panel, ...
0
votes
1answer
95 views

Enable GPCLK line for 1MHz (or greater) clock

I'm trying to drive a TLC5940 with a brand new RPi Model A+ (V1). I plan to use the Pi's SPI bus to pipe data to the chip, which I've done successfully before using an AVR. The part I'm stuck with is ...
1
vote
2answers
208 views

may connect 26 pin touchscreen display to a 40 pin raspberry pi A+?

Recently, i've got as a present a raspberry pi a+ (40 GPIO pins) and touchscreen display for older version (26 GPIO pins) I tried to google, but wherever i search it gives me description of the new A+ ...
2
votes
4answers
231 views

GPIO Pin 17 does not trigger RPi.GPIO callback

I'm trying to read from all my Raspberry Pi B+ GPIOs. Using the Python3 RPi.GPIO library, it is quite easy to do, but I've come across a problem that I can't seem to resolve : GPIO 17 does not ...
1
vote
1answer
112 views

How to get RPi to generate a triangle wave, then outputting a PWM signal

I want my Raspberry Pi B+ Model to generate a triangle wave and output a PWM signal from one of the GPIO pins, but I'm not sure how to go about doing this. All I want it to do is add some small length ...
0
votes
0answers
58 views

External power supply needed to run two stepper motors?

I am following this tutorial for a CNC laser engraver (http://funofdiy.blogspot.co.uk/2013/10/a-raspberry-pi-controlled-mini-laser.html). I have got two stepper motors from some old DVD drives and the ...
1
vote
1answer
152 views

WiringPi: Random Interrupts caused by PWM?

This program is supposed to react to rising and falling edges of an input signal. However it doesn't exactly work as expected. The expectation is that one (1) interrupt is generated for any edge, ...
0
votes
1answer
572 views

RPI B+ with connected servo is twitching

I am looking for some advice on how to properly get my servo working correctly. I have wired it up and it appears to be working correctly. The problem I have is with the signalling causing a ...
1
vote
1answer
44 views

How can i detect which board i am using through the i2c of the raspberry pi [closed]

I am working on a project where i moved from raspberry pi model B to B+. So i need to change my audio driver to work on both models by doing some GPIO changes . The requirement is, i have to find ...
0
votes
1answer
36 views

How to know which revision the rpi board belongs to using c language program

I need to do some changes in my audio card driver on the raspberry pi board. What I need to do is: I have to check which model board it is and then I have to program the GPIO's based on the revision ...
0
votes
1answer
171 views

What happened to the i2s pins which are in RPI B board and not in RPI B+ board

I'm working on RPI model B board.I've a driver for wolfson audio card,Which uses i2s pins for data transfer.Now i need to work on RPI B+ model.But there are no i2s pins in model B+.What i need to do ...
0
votes
1answer
1k views

reading pin state whether it's input or output [RPi.GPIO]

Is it possible to read pin state (1 or 0) whether it's set as output or input without setting this with RPi.GPIO.setup(pin, GPIO.IN/GPIO.OUT)? I mean i can do this via command: gpio read 2 But ...
1
vote
1answer
589 views

WiringPi + softPwm calculation to determine duty cycle

For my project we got a pre-installed rpi with all the working libraries and an example program to set a servo in middle position. The info: in a period of 20ms (50hz) we need 1,5ms to set it to ...
0
votes
0answers
48 views

Errors out with no explanation when trying to run a blinking light function in python

I have created a python script to press a button and have my light blink but it isn't working when I transported the function to my main script and it errors out with no information so I don't know ...
1
vote
2answers
119 views

My 3V relay doesn't work on GPIO but works on 5V pin with resistor

Ok, I have this awkward situation. I have a 3V relay that I need to implement in my project. When I connect it to a 5V pin on RPi, everything's working fine, I can hear the coil opening and current ...
0
votes
2answers
374 views

How can I exit a while loop at any time during the loop?

I have a python program that loops through some GPIO commands. How can I break the loop at any time during the loop by pressing the Enter key. So far I have this... import sys import select import os ...
0
votes
0answers
225 views

GPIO pins are not working

I have connected the LED as shown in picture below on GPIO #18: And I ran following program: import RPi.GPIO as GPIO, time GPIO.setmode(GPIO.BCM) GREEN_LED = 18 GPIO.setup(GREEN_LED, GPIO.OUT) ...
0
votes
1answer
104 views

Python script to conttrol GPIO

I have a very small python script to control GPIOs: pi@raspberrypi ~ $ sudo python gpio-test.py #!/usr/bin/env python try: from time import sleep import os import RPi.GPIO as GPIO ...
2
votes
3answers
2k views

RF24 communication with Arduino

I have been trying for ages to work this problem out and can't figure it out. I have two nrf24 transceivers, one connected to the raspberry pi and the other connected to an Arduino. My code for the ...
7
votes
2answers
3k views

What hardware do I need to turn Raspberry Pi into a TV remote controller?

I would like to control my TV using a Raspberry Pi. I would like my Raspberry Pi to act like a TV remote controller. What kind of hardware do I need to make it? Do I need something like IR emitter, ...
1
vote
0answers
106 views

how to read from a GPIO pin when it changes?

I create an app that must detect when the lights(LEDs) changes their status (on->off or off->on) monitor this to a site.I create this app in client side with node.js and use rpi.GPIO package from ...
1
vote
0answers
99 views

Adafruit 16x2 RGB LCD scrolling down?

So I'm working on a little project to show a fortune on this 16x2 LCD. I've been successful so far, but when it came to longer fortunes, it would just cut off. How would I go about scrolling downwards ...
0
votes
0answers
55 views

GPIO goes high on first initial run of script - please help get my ECTO 1 on the road!

I am having a few problems with my script, on a fresh boot of my pi, the GPIO Port goes High and switches my relay when I run this script, however, it doesn't do it after I initially run the script, ...
1
vote
1answer
497 views

Can't PWM LED on pin 18

Using this code, I can't use PWM on the pi. It's modified off of a Linux user article. import time import RPi.GPIO as GPIO led = 18 GPIO.setmode(GPIO.BCM) GPIO.setup(led, GPIO.OUT) ...
0
votes
1answer
179 views

display LED Blink Count on I2C 16x2 LCD

I want to blink a LED and display its count on I2C 16x2 LCD. But LED is not glowing at all. I used https://www.adafruit.com/product/1115 which uses i2c . I connected LED with 270ohm resister between ...
1
vote
1answer
97 views

Operational error when writing to database in Raspberry Pi's Python [closed]

I'm having an operational error when trying to run IDLE program (Python) in Raspberry Pi and it prompt me an error sentences: Traceback (most recent call last): File "/var/www/Sensor-LED.py", line ...