We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [gpio]

GPIO stands for General Purpose Input Output and can be used to receive and send digital signals to and from simple electronics from the Raspberry Pi.

Filter by
Sorted by
Tagged with
0
votes
1answer
264 views

Do I need a resistor for a 3v3 led? [duplicate]

Begginer question, if the output voltage of the raspberry pi is 3.3v and my led voltage is 3.3v, do I still need a resistor? As far as I understand, if the voltage is the same you don't need to add a ...
0
votes
4answers
489 views

Is it possible to shut off a Raspberry Pi 2 b using the GPIO pins?

I know there are plenty of guides out there for making a switch that uses the GPIO pins to shut down the Pi, but all of them use quite a lot of circuitry, but what I want is to just put a paper clip ...
0
votes
1answer
1k views

Using a switch, not push button, to play mp3s

I'm trying to setup a switch on a breakout board which, upon flicking the switch, will allow me to play a short mp3, then loop a second mp3 until I switch it off. When I do so, I want it to play a ...
0
votes
1answer
250 views

GPIO outputs not changing on specific GPIO ports

I'm using a Rpi B rev2 and I'm having problems changing the output of ports 2,3,4,5,6 (BCM). All the other ports work perfectly. I searched for documentation and I see the only thing that sets these ...
0
votes
1answer
501 views

How to measure mains frequency safely via GPIO

I would like to measure the mains power (120vac/60hz) to know precisely when the voltage drops to 0, but in a safe manner for the pi - one solution would be to use a high-value resistor bridge that ...
0
votes
1answer
723 views

Waveshare GSM/GPRS/GNSS HAT not connecting to Cellular network

I have this HAT i bought for a pi project I am working on. I get the device to power on, I can connect via USB from PC, and can connect from pi too. However, the NET LED just blinks every second, ...
6
votes
1answer
2k views

AD7705 analog to digital converter with RPi, viable?

I have a couple of AD7705 chips I'm attempting to use with my RPi to read the analog pins from a sensor that spits out 0~4V. Nice, detailed datasheet for the ADC is here: http://www.analog.com/...
6
votes
1answer
6k views

Raspberry Pi as slave

I am using a Pi compute module and wish to make two of them to communicate to each other. I have hooked up some slave I2C devices to it (RTC, Temperature sensor). So I don't think making Pi as slave ...
5
votes
1answer
3k views

Using BCM GPIO pin numbers with wiringPi C library

I'm a GPIO newbie experimenting with getting my Raspberry Pi to blink an LED with C using the wiringPi library. The example code at http://wiringpi.com/examples/blink/ (blink.c) compiles perfectly and ...
5
votes
2answers
1k views

Are there any GPIO pins guaranteed to stay low during startup?

As usual, this is a huge project and rather than have the entire thing on here, I'll try to keep it short but try to get all the pertinent information included. I have a mobile robot chassis with ...
5
votes
1answer
3k 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 ...
5
votes
2answers
3k views

Electrical characteristics of GPIO

Is there a spec sheet anywhere which lists the electrical specifications for the varios GPIO pins on the RPi revision B? For example, if they are open collector etc, output voltage, max input voltage, ...
5
votes
3answers
4k views

Connecting blue LED (3.3V)

I've recently started doing basic diode connections (red and green diodes). I've also got blue diodes, but there's one thing that prevented me from connecting them already, namely - the specs say they'...
5
votes
2answers
1k views

Accidentally connected 3.3v gpio pin to 5v gpio pin

So I had the GPIO diagram upside down (haha). SO I connected the 5V Power pin on the header to the 3.3V Power pin on the GPIO. It was only for a second or less. My RPi still works fine, but I wonder ...
4
votes
1answer
4k views

how to generate smooth frequency ramp

I want to drive a stepper motor driver hardware by its pulse and direction inputs. I need to use a ramp function in order not to make stepper motor stuck. I need to increase the pulse frequency ...
4
votes
2answers
2k views

Outb in C to access GPIO

I have a basic understanding of the GPIO on the RPi. I want to adapt some of my previous software which interfaced my project board via the Parallel port via direct output to the PP address (0x378) ...
4
votes
4answers
2k views

Raspberry Pi GPIO input voltage Limit

I am doing a project in which I have a component that outputs a 5 Volt signal. Since the Pi is only able to handle 3.3 V I connected the signal to a voltage divider. I used a 4.7 kiloOhm and a 2.2 ...
4
votes
3answers
4k views

LIRC remote control won't send (irsend: hardware does not support sending)

I'm trying to build a TV remote control using Raspberry Pi, and I get the following error when I try to send a command: pi@raspberrypi:~$ irsend SEND_ONCE Samsung_BN59-00937A KEY_POWER irsend: ...
4
votes
3answers
3k views

Multiplexing 4-digit 7-segment display is flickering

I connected a 4-digit 7-segment display to the GPIO-port. It uses 8 ports for the LEDs and 4 ports for multiplexing via PNP-transistors. It is running so far with a loop written in C program: while(1)...
4
votes
5answers
5k views

DS18B20 w1-gpio Device Tree gpiopin NOT = 4

I have a HAT which blocks GPIO4 so I cannot use the default pin for the temperature sensor, but I just cannot get it to work on another pin! I just get lots of 00- instead of 28- in /sys/bus/w1/...
4
votes
2answers
3k views

How to connect a 12V fan sensor wire to the Pi

I have a 3-wire 12v DC fan (Sanyo Denki 9S1212M4011). It's actually getting 15V because my "12V" wall wart isn't accurate. When the fan is not running my multimeter tells me there is 14V on the ...
4
votes
1answer
5k views

Read the value of an GPIO output pin

I've made a program using the wiringPi library that assigns GPIO pins to toggle at the press of associated number keys. I'd like my program to show the current status of the pins, even if they are ...
4
votes
2answers
2k views

Is there a max current that can be supplied when powering the Pi from the pins?

I want to power my Pi Zero from the header pins, pin 2 and pin 6 specifically. I know that my Pi Zero can consume up to 120mA, and my power supply can provide up to 500mA. I've heard that the 3.3v ...
4
votes
1answer
731 views

GPIO stuck in High Mode

I'm new to this whole RP world, and I'm trying to learn it. I've been trying to follow this post, and connected my Pi this image below Connection between Pi and Adafruit T-Cobbler Plus Wiring ...
4
votes
2answers
3k views

Read status of power led using sysfs

I want to read the status of GPIO35 on a Raspberry Pi 2 Model B using the sysfs on Raspbian with a 4.0.8-v7+ kernel. I can access other GPIO pins using /sys/class/gpio but the two leds are already ...
4
votes
4answers
12k views

How to wirelessly transmit data in between Raspberry Pis?

Is there a way to wirelessly transmit data (preferably a string but numbers will do) in between 2 Raspberry Pis? The data must be transmitted without use of bluetooth or internet and have a range of ...
3
votes
1answer
6k views

Closing a circuit with GPIO

I'd like to use the GPIO pins on my RasPi to close a circuit. I don't want any power applied to the circuit either from or to the RasPi, just something as simple as touching two wires together to ...
3
votes
1answer
412 views

Does select/multithreading make sense when dealing with multiple DS18B20 and GPIO reads simultaneously?

As you may know, DS18B20 is not the quickest sensor and answers after around 750ms delay but, afaik, 1-wire is a relatively quick bus. I have multiple sensors connected to the board, which means if I ...
3
votes
1answer
354 views

GPIO affected by audio playback

I recently found the PiFm project which sends a FM signal through a GPIO pin to effectively create a FM transmitter out of the Pi. A problem arises when you do a normal playback of a .wav audio ...
3
votes
1answer
8k views

Measure Voltage with Raspberry Pi? Using a MCP3008?

I have an MCP3008 ic. I am pretty new to the Raspberry Pi world, as anyone ever used the MCP3008 to simply measure voltage? I just am really not sure how I would go about doing it. Any advice would ...
3
votes
3answers
852 views

GPIO.input in a while loop without sleep

I need to catch a fast GPIO pulse in a while loop like so while True: if GPIO.input(11) == 1: sys.exit(0) the pulse is so fast (magnet passing by a switch), that if I add a sleep in the ...
3
votes
1answer
344 views

Strange I2C behaviour

First of all: sorry for the title, I don't know how to describe further... Background: I'm working with the RDA5807M FM receiver chip. It worked fine for at least one month now. I just had jumper ...
3
votes
1answer
466 views

What's the difference between soft PWM and PWM

What's the difference between soft pwm and pwm(maybe hardware pwm) in raspberry 3 b+. From the pinout (https://pinout.xyz), it seam that there are only 2 pwm pin, pin 32 for pwm0 and 33 for pwm1. But ...
3
votes
4answers
25k views

Can't Access TTY: Job Control Turned Off

I have a new Raspberry Pi with Raspian Wheezy installed and has several cables connected to it via the GPIO pins. However, I noticed if I have anything connected to them during boot up, the device ...
3
votes
2answers
7k views

Female Breadboard Jumper Cables

Can I use the inexpensive female/male or female/female breadboard jumper cables to temporarily wire sensors to the GPIO pins? http://www.ebay.ca/itm/QTY30-Breadboard-Jumpers-Wires-Male-Female-Arduino-...
3
votes
1answer
2k views

Power an 8-channel relay without drawing power from the RPi

I've recently acquired an 8-channel relay from China. I've been reading and watching a lot about how to connect them to the RPi. For now I've only tried it out on an old RPi Model B (I didn't want to ...
3
votes
2answers
400 views

Using Transistors and the GPIO, can someone please check my math?

I've done a couple of new schematics, this is my first time doing this, I was wondering if somebody could double check my math? Powering the RGB LED straight off the GPIO pins: Using the 5V rail and ...
3
votes
2answers
670 views

Using an L293D chip (to control a motor) with a separate power supply

I've got an L293D Motor Driver chip powered by 4.5v via some batteries and am trying to send high signals via the GPIO library in Python to control a motor, however this does not seem to work. My code ...
3
votes
3answers
488 views

Is there any change in the GPIO mapping between Raspberry Pi 1 and Zero?

I'm currently building a hygrometer (according to tutorials like this https://www.sweetpi.de/blog/436/luftfeuchtigkeit-und-temperatur-mit-dem-raspberry-pi-messen) All tutorials are using the "normal" ...
3
votes
3answers
5k views

Can we determine the mode of a GPIO pin?

As I understand it, the mode of a GPIO pin can be INPUT or OUTPUT (and I think there may be other modes such as PWM and I2C). I believe that the mode of a pin is a global and that if two applications ...
3
votes
1answer
2k views

Raspberry Pi Camera Not Showing Preview Onto Touch Screen

I have a 2.8 inch touch screen that plugs into the GPIO pins on my Raspberry Pi 3. https://www.adafruit.com/product/1601. I have a raspberry pi camera that I attached to the pi. I am using the ...
2
votes
2answers
3k views

controlling two motors with an L293D

Update: Can I possibly use the TLC5940 to control two motors? So there is a lot of talk about controlling two motors. My plan is two build a RPi robot and at minimum I need to have it control ...
2
votes
1answer
7k views

Problems Regarding Raspberry Pi Project with MQ-2 Gas Sensor

Recently I have been learning Python implementations on Raspberry Pi's GPIO system. I'm interested in wireless sensor network examples and decided to make a fire alarm system using MQ-2 sensor as the ...
2
votes
2answers
353 views

GPIO Display an Buttons dont work

i bought a pi 2 B last week with a ready to use 16x2 Display + Keyboard wich i pluged in the gpio pins. It looks exactly like this picture: When i start the pi, the background display lights up like ...
2
votes
2answers
4k views

How to change gpio directory for node.js pi-gpio?

I was wondering how to change the gpio directory for the node.js pi-gpio library. Whenever I try to run the script to change the pin it returns this error: "Error when trying to open pin 40 gpio-...
2
votes
1answer
542 views

GPIO stopped working under Python after using SPI

I'm using a Gertboard, and the GPIO Python demos were running fine. I started using/modifying the DAC and ADC demo code, and now I can't output to GPIO using Python (e.g. the Gertboard leds-rg.py ...
2
votes
2answers
1k views

Risk of damage soldering directly to GPIO

I am thinking of removing the headers on some HATS and soldering them directly to the Pi. Is there a risk of damaging the pi if I overheat the pins or board? What's the best way to remove the headers ...
2
votes
1answer
601 views

Other hardware for camera slots?

I think the raspberry should get more cool hardware like the camera that works with the slot onboard. I'd love to get a fast RS485 onto this slot because i need all my GPIOs for LEDs. Currently I use ...
2
votes
0answers
31 views

Is this a bug in sysfs? - GPIO access control problems [duplicate]

Here's the code: #include <stdlib.h> #include <stdio.h> #include <sys/stat.h> #include <fcntl.h> int main(int argc, char** argv) { char buf[1024]; int fd = open("/sys/...
2
votes
1answer
2k 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 ...