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
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
1k views

Correctly grounding a circuit

I have a very simple circuit using the Adafruit breakout Pi cobbler kit with a HC-SR04 ultrasound module. The circuit works fine (I can trigger and read the echo back) but it doesn't seem to be ...
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
2answers
9k views

Where is the GPIO header file (“linux/gpio.h”)?

I've been reading about the linux GPIO functions and tried to make a small example using the function gpio_is_valid, but the compile fails because it can't find linux/gpio.h. #include <iostream>...
5
votes
1answer
2k views

Pi to Pi Communication over GPIO / USB

I have a Pi Zero that I would like to use to communicate with a B+. In theory I can connect an adaptor cable and a WiFi or Ethernet USB dongle to the Zero, and do the same on the B+. However, as an ...
5
votes
1answer
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 ...
5
votes
1answer
363 views

Adafruit LED Backpack with Windows 10 core

I have purchased the 4-digit 0.54" 14-segment Alphanumeric (https://www.adafruit.com/products/1911). I noticed there are helper classes for Python and Ardunio, but there isn't anything for Windows 10 ...
5
votes
1answer
1k views

How can I use the RPi GPIO to make a headphone sensing audio jack?

I am working on a project that involves a raspberry pi acting as an internet radio client which the public can access by plugging their own headphones into a 3.5mm (1/8”) jack. They will have access ...
5
votes
0answers
112 views

Raspberry as I2C Slave, how to slow down transfer rate?

I have had minor success using the PIGPIO library and interfacing the Pi as an I2C Slave (Using GPIO Pins 18 and 19 as SDA and SCL) with a Campbell CR1000X Datalogger I am encountering a problem ...
5
votes
2answers
317 views

Pi4J kills USB bus?

Hello fellow Pi enthusiasts :) I am currently attempting to control a standard 16x2 character LCD display from the PI's GPIO pins from Java. I downloaded Pi4J and wrote a small program to initialize ...
5
votes
1answer
3k views

Reading HC-SR04 echo with wiringPiISR()

The following code works with the busy wait, but if I replace the while loop with a call to wiringPiISR() it always returns 0 for the distance. I also tried calling wiringPiISR() before raising the ...
5
votes
2answers
2k views

Impossible to scan RFID tags using libnfc, PN532, and RPi3

I recently bought this NFC/RFID reader PN532 module V3 I want to use it with my raspberry pi 3. I have install and configured the library libnfc. The PN532 is connected with I2C. I have well enabled ...
4
votes
3answers
2k views

rPi2 model B v1.1 smoke comes out near power port

I am trying to control 2 motors using the E-gizmo Motor driver shield but suddenly smoke comes out near the power port of the raspberry pi 2 so I immediately unplugged the power supply. After that, I ...
4
votes
3answers
18k views

Plug a 5 V fan to GPIO 1 and 2

Regarding to the following picture, I understand that I can plug a 5 V fan by plugging it in between pins 1 and 2. Is this right (+ on 1 and - on 2?)? My need: Plug a 5 V fan to run all the time the ...
4
votes
4answers
3k views

How do I control GPIO-connected fan via code at a certain CPU temperature?

I have just bought a 5v Pi fan for my Pi3. I'm using Retropie 4.1 for the OS. I have connected the red and black wires of the fan to ground and GPIO 18 respectively. How can I get the fan to start ...
4
votes
6answers
18k views

Raspberry pi maximum relays that I can connect

I want to control multiple relays in my house using the raspberry pi. How manny relays can I control using it ?
4
votes
3answers
6k views

Is there any reason to use multiple ground pins on the P1 header?

I'm building a Pandora device based on the Pi which uses the P1 header with Adafruit's Pi T-Cobbler breakout. The 3.3V pin (P1-01) powers 6 momentary buttons each with the following circuit: The 5V ...
4
votes
3answers
2k views

Powering multiple PI's with one power source

here is an unusual question. I have NOT found ANYTHING answering my question which is why I'm here. My question is this: I am about to make a server cabinet for 4 Raspberry PI's it USED TO BE the 2 ...
4
votes
4answers
4k views

Infrared NodeJS

I just orded my RPI a while ago (Haven't recieved it yet), and this is just completely out of curiosity, but will I be able to connect some sort of IR receiver, and get it's input in Node? Or is this ...
4
votes
2answers
337 views

Random GPIO values when ribbon cable is connected

I've installed the GPIO python library to read/write to GPIO pins. To get the state of the pins I'm using "gpio readall" which displays a table with all the pins from the RPI and I can see which pin ...
4
votes
1answer
17k views

GPIO pin states on powerup [duplicate]

Can't seem to find a solid answer to the power on state (before the O/S loads) of the GPIO pins. IE Do the pins default state set to input/output pull ups enabled etc.. My quick analysis has shown ...
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
2answers
4k views

100% processor usage with WHILE loop in Raspberry Pi

I am using wiringPi Library and using this library to read data from GPIO Pins attached to a PIR Sensor. I am using a while loop which reads input data. If there is a motion it will print motion. ...
4
votes
1answer
3k views

Using Pi's built-in audio as general-purpose DAC?

Any common Audio output on any electronic device is in essence a two-channel Digital-to-Analog converter, where the voltage sent to each of the channels (Left, Right) powers the electromagnet that ...
4
votes
2answers
8k views

How do I wait for interrupts in different languages?

I have a IR photo gate sensor that I have attached to my Raspberry Pi, and it is working nicely as I test with WebIOPi and a C program using the wiringPi library. I would like to use some other ...
4
votes
4answers
2k views

“Blinking” relay by toggling pins between input and output

Edit for searches: This question is about using a 5v relay with Raspberry Pi GPIO pins that outputs 3.3v. There are a number of great questions below, read them through to understand whats going on. ...
4
votes
4answers
7k views

Android Things: How many PWM pins on Pi 3 Model B?

I'm interested in using the Android Things on the Pi 3 Model B, but I need to access a minimum of 4 pins and use them for PWM control. On the pin-out diagram on Google's Android Things site, there ...
4
votes
1answer
3k views

How to use Arduino devices with Raspberry Pi?

I bought "RFID RC522" & "GY-NEO6MV2", and I need a useful guide for both of them in order to use them with Raspberry Pi 3 Model B. I also want to know if there is a guide or a course for using ...
4
votes
2answers
1k views

Use 3.3V regulator on 5V rail with GPIO

I would like to run a the LD1117H linear 3.3V regulator on my Pi's 5V rail in order to provide more current than the 50mA that the onboard 3.3V rail provides. My concern is that this is not entirely ...
4
votes
1answer
1k views

Can I write and read the pins of the GPIO just by using the shell?

I do not have programming skills, but I have some knowledge using the command line of the shell. Is it possible to get access to the GPIO just from the shell ?
4
votes
6answers
3k views

Connecting multiple ds18b20 digital temperature sensors to different GPIO ports

There are loads of examples of using the ds18b20 temp probe, or even multiples all to GPIO pin 4, and then running: modprobe w1-gpio modprobe w1-therm cat /sys/bus/w1/devices/28-*/w1_slave The ...
4
votes
3answers
1k views

Does Raspbian come out of the box with some GPIO C library?

Does Raspbian come out of the box with some GPIO library for C, or if not, does it have any in the standard repository? Sure I could just download and compile any of the libs on my own from .tgz but ...
4
votes
2answers
15k views

How to trigger GPIO event using an active infrared sensor

Trying to get an active infrared sensor to trigger an event on a GPIO pin. I'm using python and the RPi.GPIO library on an RPi model B. Some background info, not sure how relevant it is, but I'm a ...
4
votes
1answer
1k views

how to set and read the value for a gpio pin?

I got a new raspberry-pi and I am playing with LED's. I am trying to understand how the gpio-pin value is set. Does it read somewhere from the file system? I was going through a node.js module which ...
4
votes
3answers
6k views

Connect sim800 to Raspberry PI (RX, TX)

I've been trying to connect my sim800L to my Raspberry pi 3 model B (rasbian) but without success... I'm at the very first step, and since I'm new to Raspberry pi, I don't understand very well how it ...
4
votes
2answers
243 views

Solution to limited GPIO pins

I am working on a project in which I need to accept 64 ON/OFF input signals into my Raspberry Pi. Is it possible by using four 16 channel multiplexers? How? If not, then I have found out in other ...
4
votes
2answers
715 views

Prevent wake-from-halt

I have an SMBUS (I2C, SMART Battery/charger) communication connected to the RPi: Pin 3 GPIO2 SMBUS SDA Pin 5 GPIO3 SMBUS SCL When pin 5 is connected, the system will wake up after approx 5-20 secs ...
4
votes
1answer
699 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

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
6k views

How to connect single GPIO pins?

I want to connect an IR receiver and a gas meter impluse reader to the GPIO port. I saw those ribbon cables, but they have much more wires than needed. Can I by these small connectors for single ...
4
votes
2answers
1k 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
1answer
55 views

How to Monitor GPIO Input Indefinitely Without Recursion

I actually joined StackOverflow to ask this question because I wasn't sure it was RPi specific, but as I was thinking about how to form the question, I realized it might be GPIO specific (for some ...
4
votes
1answer
84 views

Is Fingerprint Scanner - TTL (GT-511C3) compatible with Raspberry Pi Zero

I have a question regarding Fingerprint Scanner - TTL (GT-511C3). Here is a link. Please help me. Is this fingerprint scanner compatible with Raspberry Pi Zero? please give me the answer.
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
1answer
2k views

pigpio - set_PWM_dutycycle vs hardware_PWM

What is the difference between the set_PWM_dutycycle function and the hardware_PWM function in the pigpio python library when assuming the same frequency is set for both the functions. Will I get a ...
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
3k views

Power on from idle with gpio3, undocumented?

Reading this thread I found out that you can power on the rpi from idle by connecting gpio3 (pin5 revB) to ground, tested it and it works great. I didn't read that anywhere else, including in the ...
4
votes
1answer
284 views

Looking for Raspberry Pi pinout image map showing all components

I'm looking for a link to a picture of a Raspberry Pi that has HTML pop-ups (mouseover and it tells you exactly what everything was depending on what you mouse was over). I can't remember what ...
4
votes
3answers
1k views

Controlling a relay with GPIO

Is it possible, using the GPIO Port to power a relay. I have read things about the GPIO port saying it is very easy to mess up, and seeing that activating a relay (basically a short circuit through a ...
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 ...