Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

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.

0
votes
3answers
2k views

Boosting FM range transmission from Raspberry Pi

I want to boost FM transmission range when using Raspberry Pi as transmitter. I found this circle: Source: https://www.safaribooksonline.com/library/view/ipod-and-itunes/0596007787/ch01s07.html Will ...
0
votes
1answer
438 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, ...
1
vote
1answer
83 views

Windows 10 core with Raspberry Pi

I amusing C# UWP and i am storing sensor data to a database. What I would like to do is send the Sensor name instead of the GPIO Number. So on pin_valuechanged() I like to assign the pinNumber a ...
1
vote
1answer
82 views

RaspberryPi 2 GPIO stopped working

I have RaspberryPI with Arch Linux and everything was going well, until this morning when I tried to do my usual work on it, it sounds like nothing happening at all, I have checked with pintest (I use ...
2
votes
1answer
633 views

Accessing pwm module without root permissions

I am trying to use the hardware PWM module on my pi 3 by writing to the /sys/class/pwm/pwmchip0 directory (which I think is just a symbolic link to sys/devices/platform/soc/3f20c000.pwm/pwm/pwmchip0). ...
0
votes
1answer
104 views

Raspberry PI SPI interface

I'm looking at a Raspberry Pi and I am a bit new to Serial Peripheral Interface. I see the Rasperry Pi has two SPI interfaces on the GPIO pins. Can one SPI interface be programmed to connect to ...
1
vote
2answers
31 views

Voltage dropped significantly on GPIO 4 with a relay coil

I have a Raspberry PI 3 B+, and when I activate the GPIO 4 as output and checking agains a multimeter I get its 3.3V as expected. If I connect the GPIO4 to one end of a coil (http://www....
1
vote
1answer
37 views

Why is pigpio library not moving my servo when the same pin number works perfectly with RPi.GPIO?

I am working on a self driving rc car project and I need a servo to steer my car. As I was getting a bit jitter with RPi.GPIO I tried pigpio library. I am using a Raspbery Pi Model B. But it won't ...
1
vote
1answer
71 views

How can I connect an EasyADC board mikroe340?

I've got a 4-channel 12-bit ADC "Mikroe340" from Mikroelektronika (datasheet). I'm wondering how to wire it with GPIO.
1
vote
1answer
78 views

How to cut the power on power pin 1 programmatically?

Is there a way to cut the power on power pin 1 on Raspberry Pi 3B+, using a command or force this on reboot?
0
votes
0answers
19 views

How to get LDR sensor reading in C language [on hold]

I am currently working on a project using laser module, a capacitor and an LDR. After looking online, I found a library in Python called GPIOZero that allows me to do this directly, as follows: from ...
0
votes
1answer
213 views

Change GPIO pins for official Raspberry Pi 7" touchscreen

I need to use different GPIO pins with the Raspberry Pi official 7" touchscreen. I'm already using pins 3, 4, 5 and 6 with a hat, and it would be a pain to change them. I've looked through several ...
0
votes
0answers
23 views

How does the linux kernel handle interrupts [on hold]

A few days ago I asked a question that had (probably) had to do with en interrupt being fired by an ENC28J60 chip (SPI) and messing with the UART buffer. See here. I found a software fix for this ...
1
vote
1answer
206 views

Connecting Hifiberry Digi+ clone (PiFi Digi+ V1.0) to an Raspberry Pi 1 B (26Pin Header)

Hi I wanted to make use of an older Raspberry Pi and build an Volumio Music Player. I ordered Hifiberry Digi+ clone (PiFi Digi+ V1.0), unfortunately I forgot I own an older Raspberry Pi 1 B with the ...
0
votes
1answer
100 views

Problem with LED blink program on Pi

I am completely new to RPi and stuck unexpectedly. I am trying to create a simple python program to make my LED blink. Here are the two programs which are giving same outputs on terminal when I ...
1
vote
0answers
34 views

Getting button click type

I've been looking for a while to how to get the kind of click of a button on GPIO. Is it a single click? Double? Triple or more? Is it a long click? a very long click? a combination of them? I haven'...
0
votes
1answer
31 views

Is it possible to toggle 3.3V and 5V header pins on and off? [duplicate]

Header Pins 1, 2, 4, 17 are labled 3V3 and 5V on the schematics but the connections to the BCM and/or regulators are not in their documents. It appears the 5V node is coming from the raw USB/external ...
0
votes
1answer
26 views

False Contact Closures - Do I Need Physical Pull Up Resistors to Resolve?

I'm running Raspbian Jessie 4.9.35-v7+ on a Pi 3 Model B. I cobbled together a basic python script to monitor a GPIO pin and send a network signal to a remote application, made two copies of the ...
0
votes
1answer
24 views

Raspberry pi and microbit working together

Can I do a pin out from raspberry pi onto a breadboard and have a microbit setup to receive that pin out and have the microbit run a command on pin in? Or can I have the raspberry pi send a signal to ...
1
vote
2answers
101 views

How can I drive output voltage between 0v, +12v and -12v on a single line?

I have an appliance that needs a +12v pulse to be activated and a -12v pulse to be deactivated on the same input pin. After the pulse, the line should drop to 0v again. This voltage switching only has ...
0
votes
1answer
122 views

Can I connect GPIO pin and ground to a PC motherboard power switch to turn it on/off

I would like to use RPi to connect a jumper cable from PC Motherboard power switch to a GPIO pin and Ground to be able to turn the PC On/Off automatically and remotely. Would it work and is it safe?
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 ...
1
vote
2answers
92 views

Multiple RPi and multiple external 5V power sources. Connecting all GNDs = ok?

First off, I'm a noob when it comes to hardware/electronics. Barely started and not planning on getting too deep in it. I have a bit complex setup that boils down to multiple RPis (around 13, with ...
2
votes
1answer
97 views

Vibration-induced power loss problem

I am a pilot using a Pi 3 as an ADS-B receiver for a gyroplane. It works really well provided I don't try to have the Pi mounted to the aircraft anywhere. As soon as I do, the vibration seems to cause ...
0
votes
1answer
95 views

GPIO button to complete input prompt

I would like to prompt the user for input, then with the push of a GPIO button, submit the input value. This is tricky since the GPIO button polling is typically done in a loop. I was thinking that ...
1
vote
2answers
29 views

Can't exit my apllication in a clean way

Not sure if my problem is related to RaspberryPi, GPIO or just my understanding of Python but since I'm detecting my problem while playing with a button attached to my PI I ask it here. I have a ...
0
votes
1answer
131 views

Using I2C and the adapters

I am trying to use the GPIO pins for I2C communication between the master and the slaves and have been using this page as a reference for me on how to do it. The code is run from userspace daemon. So ...
1
vote
1answer
19 views

How to control computer fans with GPIO

I want to build a smart air conditioner with my Raspberry Pi 3b+ by using these PC Fans: https://www.amazon.de/Arctic-F12-PWM-PST-Geh%C3%A4usel%C3%BCfter/dp/B00NTUJTAK/ref=cm_wl_huc_item. What is ...
0
votes
1answer
104 views

Rasberry Pi LED GPIO using Python

In my project I invoke a python script via node.js on my Rapberrypi B+ model and what the python script does is that it turns on the BCM GPIO ports as per the python arguments passed through the ...
0
votes
1answer
145 views

How to get gpio status on an output pin in ruby

I'm using the Pi to control some decorative lights. I turn the lights on and off via cron scripts and would like to get status on the lights as well. When I run the code below, it reports 'on' if ...
1
vote
1answer
194 views

Pi 3 reboots when GPIO 13 is given 3V

simulate this circuit – Schematic created using CircuitLab I am taking the 3V from Pi and giving it to COM of a relay. The NO goes to GPIO 13 of the same Pi. I have a 120V line that triggers ...
0
votes
1answer
116 views

generated pulse with delay time before it generated

I want to generate about 16 square wave with delay time initial as the following figure .It mean each pulse generated must delay with a value of delay time before it generated with frequency about ...
3
votes
1answer
334 views

How long to wait after shutdown to cut power

I am working a problem that seems to be fairly popular with the Raspberry Pi community. In essence, I am designing a circuit that will utilize a DS3231, a 555 timer, and a load switch to cut power ...
0
votes
0answers
13 views

Reading Bytestream from GPIO / External Interrupt and CLK

So I have an external device which bangs out a byte stream (DOUT), it indicates the upcoming stream on an DRDY. The timings are given on an DCLK line. These three lines (DRDY, DCLK, DOUT) serve the ...
0
votes
1answer
269 views

Voltage High, low with 0 and 1 using python on a GPIO

Mind the variable creations as they are handled. My questions are the following. 1) Why do we have 2 whiles here? Does the sleep at the end of the first part does really anything significant? 2) ...
3
votes
1answer
139 views

Reactive Programming

The examples I see for the GPIO input are based on a loop which waits and check if the GPIO is receiving any info. Is there a way of just detecting when a button was pressed without using a loop under ...
0
votes
2answers
128 views

Can't turn on LEDs through terminal with PWM

I wrote a crappy Python script that should turn on LEDs connected to the GPIO interface. import RPi.GPIO as GPIO import time, sys, json GPIO.setmode(GPIO.BCM) GPIO.setwarnings(False) gpioPorts = [...
2
votes
1answer
107 views

Export GPIO pins from extender

I have PCF8574 GPIO extender connected to RPi. I use GPIO Sysfs. It is possible to write/read to/from extender pins, using command like this: gpio -x pcf8574:352:32 read 358 But i can not export ...
1
vote
1answer
206 views

GPIO Input Not Detected Within While Loop

Hi I'm having a problem with trying to detect GPIO input on a PIN within a while loop. Turnstile B Entry button is what I am troubleshooting the statement if tsB_entry_button == False: import RPi....
2
votes
1answer
58 views

outb() equivalent in Python for GPIO

I am a very beginner on programming and raspberry usage, tho I think I learn fast. I am trying to convert an old program (not mine) that was written for Linux on C++ for communication with a printer ...
3
votes
2answers
68 views

Run the program in the laptop and use the raspberry gpios

I'm working with face tracking and I want to activate some servomotors depending the motion of my face. For facetracking I'm using, an usb cam, opencv and dlib. Now results the raspberry can't run my ...
7
votes
3answers
19k views

Setting GPIO value on boot

I'm a semi-linux newcomer and i have a question: I need to set some GPIO pins in this way: (pin 18 out, pin 17 in) (actually i'm doing this via WiringPi(pyton) trought this commands) gpio export 18 ...
0
votes
1answer
28 views

Wireless doorbell using gpiod

Good Morning, I have a non issue that I am just curious how its working. So I have a wireless doorbell that I built. It works using the gpiod and remote gpio. So I have a chime unit that I built with ...
0
votes
1answer
190 views

Is there any way to find out which GPIO pin of raspberry pi busy?

We will get many times "Device or resource busy" error, when try to read or write GPIO pin of raspberry pi. So, Is there any way to find out which GPIO pin of raspberry pi busy? Thanks in advance.
2
votes
0answers
20 views

SPI NOR Flash: Unstable reads

So I hooked up an Winbond 25Q256JVEQ to my Raspi3 via SPI (spi0.0) and want to read its content. I use the jedec-nor-spi dtoverlay so its available as MTD. However when I want to read the chips ...
0
votes
2answers
150 views

BCM 12 broken on RPI 3?

I'm having trouble using one of the GPIO pins. When trying to use BCM 12 (PIN 32 in BOARD mode, name: GPIO26) as an output, I get the warning: RuntimeWarning: This channel is already in use, ...
1
vote
2answers
255 views

Why does my raspberry pi zero w crashes when controlling a DC motor with an L9232D and a 9g Servo motor?

I use this simple circuit to control a DC motor with an L293D, and a 9g servo motor with a Raspberry PI Zero W: I use the simple following code to test the circuit: from time import sleep import RPi....
1
vote
1answer
22 views

Is it possible to use BCM 3 for IR Remote Receiver?

I have connected an IR remote receiver to my Rasberry Pi's GPIO BCM 3 on. The receiver works as expected and I have the wanted side effect, that if off as soon as an arbitrary key on the remote is ...
0
votes
1answer
129 views

HTML doesn't show button if not in a local network using webiopi.js, how show it on the browser?

I followed a tutorial made by Jerry Hildenbrand, where he teaches how to control a LED via local network. His tutorial works perfectly, I just need to type tightvncserver in the raspberry and open ...
-1
votes
1answer
219 views

How to restart the GPIO after shutdown() called

After I call the following Java code: gpio.shutdown() The GPIO turns off. How can I restart it? I need to restart it because of this problem. In the problem the light does not turn off with led.low(...