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

pin state after shutdown

i am on Ubuntu 20.04 on RPI4. I am driving a 4 PWM motor driver using PWM on pins 22,23,26,27. When i turn off the raspberry, the driver being still powered, go off. I suppose some of this pins change ...
Stefano Mutti's user avatar
0 votes
1 answer
218 views

Raspberry Power Supply via GPIO. No HDMI or Ethernet

for my current project I need to supply the Pi via the GPIO pins with power. I know that I'm bypassing some security features, but my circuit has new ones implemented. The problem is, that I'm hocking ...
Andreas's user avatar
1 vote
1 answer
1k views

libgpiod read value Operation not permitted

Trying to read the values from gpio chips in a Python script using the gpiod python module. When calling get_value() we are getting "Operation not permitted". Have tried running the python ...
DJViking's user avatar
  • 111
0 votes
1 answer
39 views

LED In series with input pin

I was wondering if anyone here may be able to help me. I currently have a C# program running on a raspberry pi, that detects the state of a toggle switch connected to pin 13, and ground. I have an LED ...
John Reid's user avatar
0 votes
1 answer
127 views

How to control existing button with a Raspberry Pi? [closed]

I've got a simple standing with two buttons up/down. It has built in overload protection, i.e. when it's blocked. I'm pretty sure the controller behind the up/down button does that. As my first Pico ...
Boland's user avatar
  • 111
0 votes
0 answers
87 views

How can I figure out my Python code with Kivy and Raspberry Pi GPIO?

I try to add actionbar to all screenmanagers in Kivy 2.1.0. I found some solution to my problem but I added some more features like GPIO pinout from Raspberry Pi. Here is a solution without gpio. I ...
yottabyte's user avatar
2 votes
4 answers
377 views

How can I debug why the Pi will only recognize some of the GPIO expanders over i2c?

I am using 8 MCP23008 GPIO expanders to connect 64 total switches to a Raspberry Pi Zero W. Here is my circuit diagram: I also designed and purchased a custom PCB for the sensors/gpio expanders Here ...
James's user avatar
  • 133
1 vote
2 answers
308 views

UART (not the board itself) stopped working after connecting 5V to GND, can it be recovered?

I accidentally connected UART wires one row lower than it should be (see image): then I unplugged them shortly after that and then connected correctly, but serial console doesn't work anymore. USB ...
aryndin's user avatar
  • 201
0 votes
2 answers
450 views

How to simultaneously control over 200 GPIO pins while maintaining timing accuracy

I am currently using a raspberry pi zero, which I connect directly to my computer via usb. I have connected eight MCP23017 GPIO expander chips, which is the maximum amount you can connect to a single ...
Yes's user avatar
  • 169
0 votes
1 answer
48 views

Waveshare OLED 1.3 B wont run on different PINs

I am using a Waveshare OLED Display 1.3 B and trying to run it with a Raspberry Pi Zero 2 W. Because I have several devices hanging on my Pi I cannot use the suggested PINs GPIO 25 for Data and GPIO ...
Daniel's user avatar
  • 123
1 vote
1 answer
1k views

Rpi Pico receiving on multiple UARTs

Expected behavior: in hardware I connect UART of a number 0/1 to the correct Pin numbers tx/rx and get it based on that connection Actual behavior: in hardware I connected UART of a number 0/1 to the ...
mr.xed's user avatar
  • 21
0 votes
1 answer
145 views

Voltage divider for multiple gpio inputs

I have a system that can output 12V depending on measured events. The way the 12V of the system are provided is via a 12V output that gets shorted to GND via a transistor output. I wanted to use these ...
Dahlin's user avatar
  • 1
0 votes
0 answers
116 views

SPI Interrupt Bit-Offset / Too Early

I´m running an SPI Slave on my Pico and executing an interrupt when 16 bits of Data are received. I visualized the interrupt with a gpio spike on the beginning and end of the interrupt to see when it´...
0i9n's user avatar
  • 11
1 vote
1 answer
393 views

Infrared Receiver for remote controll not working

I am using a raspberry pi 4 with raspian. uname -a yields: Linux raspi 5.15.32-v8+ #1538 SMP PREEMPT Thu Mar 31 19:40:39 BST 2022 aarch64 GNU/Linux I am trying to get an IR-receiver working (model OS-...
Thomas Preu's user avatar
0 votes
1 answer
64 views

What can I do to get the Pi4J library to work with Java?

I am trying to get the Pi4J library to work on my Raspberry Pi 4. I just wrote a simple blink program. It is not toggling the pin as it should be. Here is the simple program. I have compiled it, and ...
Andrew's user avatar
  • 9
-1 votes
1 answer
69 views

Pin not falling back to default state after button is pressed

I am having a simple circuit which is only supposed to give back the status of a certain pin on the push of a button that puts a voltage on input pin 16. When I push the button, the state goes to 1 as ...
markus902's user avatar
0 votes
3 answers
400 views

Can a raspberry pi power a 5v and 1 amp Peltier module

I am considering a project that involves the following part. https://www.amazon.com/Dilwe-Thermoelectric-TEC104901-Semiconductor-Heatsink/dp/B08YFBZW64/ref=sr_1_16?crid=DYBHWMJ9VUJN&keywords=5+...
UNKNOWN's user avatar
  • 79
1 vote
2 answers
126 views

GPIO pin confusion

So far, my ignorance was bliss. I was able to control the GPIO pins and for many years, the world made sense to me But then I saw this: And wires got crossed in my brain Why does it say that GPIO7 is ...
Chris V.'s user avatar
0 votes
0 answers
34 views

How to Properly Stop Electronic Speed Controller

I have a brushless electronic speed controller connected to my RaspberryPi. I have tuned it to 700 - 2000. It runs correctly, but whenever I set the speed to 700, it stops (this is supposed to happen) ...
Brendan R.'s user avatar
0 votes
0 answers
124 views

Raspberry 4 Java Pi4J GPIO Input not changing state

I am trying to use my Raspberry Pi 4's GPIOs to turn on various thing in my smart home. I am getting 2.6V on the GPIO Input, thus resulting in a HIGH signal. I have confirmed this with a basic python ...
Dahlin's user avatar
  • 1
0 votes
1 answer
367 views

How to connect four analog microphones to Raspberry Pi GPIO?

I have four microphones that has pins: VCC, GND and Analog Data. I need to connect it to Raspberry Pi (I need it for detection direction to source of sound). As I know, GPIO doesn't have analog inputs,...
Robotex's user avatar
  • 137
-2 votes
1 answer
55 views

I want to power RP3B+ with gpio but not sure about the circuit

I got a 4 battery holder (4-Way 18650 Battery Holder from Dfrobot) And I'm wondering do I need a resistor to power the rasbery pi via gpio 5v pin. Or do I need something else for this power supply The ...
Balvey's user avatar
  • 1
2 votes
2 answers
93 views

Method to switch one GPIO device/HAT/pHAT between two Raspberry Pis

I'm looking for a method to share one GPIO device/HAT/pHAT between two Raspberry Pis. For example, I'd like to connect one HyperPixel 4.0, which attaches via the 40 GPIO pins, to two different ...
emma.makes's user avatar
-1 votes
1 answer
69 views

signaling Raspberry Pi with PLC

I want to give signal via PLC to Raspberry Pi and when the raspberry pi gets that signal, it should run the python script and when the python script execute properly and cycle is completed, it should ...
dsp's user avatar
  • 1
0 votes
1 answer
404 views

Cannot write() i2c-dev after using libgpiod

Question: Is anyone able to advise on how to interleave operation of the RPi I2C hardware with general GPIO using libgpiod? Summary: I'm experiencing some unexpected behaviour with RPi4, gpiod and /...
Colin Hall's user avatar
-2 votes
1 answer
86 views

Is there a way to use the GPIO pins as a button?

Im currently setting up picroft on my Raspberry and once i have it running, i would like to create a command, which basically emulates a button press. Im planning on controlling my lights with it but ...
SimonRMC's user avatar
2 votes
2 answers
111 views

In what way can I connect my two Raspberry-Pi to a INA219 sensor at once using GPIO? This is more of a hardware question/ No Code was used

I am trying to figure out how to connect a INA219 sensor to two Raspberry Pi's. I am currently using 4 wires that connect the main Raspberry Pi and the INA219 sensor. There is no code, I am connecting ...
WhisperingSupreme's user avatar
-1 votes
2 answers
121 views

How to set PWM to actual 0

I am controlling a stepper motor using PWM on a RPi 4 and python. The motor has a controller/driver (BLDC-8015A) that accepts 0-3.3V to set the rotational speed. According to the documentation, this ...
user7408924's user avatar
-1 votes
1 answer
66 views

Bs250 transistor as switch

Hi so I have button connected to pins 5 & 6 on rpi3. This is to "power it on"... The button is also connected to another gpio 18 pin and python script listen for change and when it's ...
joural's user avatar
  • 1
0 votes
0 answers
113 views

Voltage drop at 5V pin when drawing current with DC motor

I encounter a power behavior for my Raspberry Pi 4B that I struggle to explain. I try to power a (geared) DC motor using the 5V pin. DC motor is rated for 3-12V (preferred 6-8V) and is claimed to draw ...
adelille's user avatar
0 votes
0 answers
101 views

Using Interrupts with Sense Hat

Im trying to use the Interrupts on the Sense hat (preferably in combination with the IMU), but i get this error GPIO.add_event_detect(INTERRUPT1, GPIO.FALLING,callback=my_callback1,bouncetime=300) ...
Xenoshell's user avatar
0 votes
2 answers
106 views

How to create a data signal using pwm from a gpio output?

I'm a new member of the raspberry pi community and I have problems with starting my first project. I want to be able to create a data signal using pulse width modulation with the gpio headers. The ...
muuuc123's user avatar
1 vote
0 answers
40 views

RC522 not writing with raspberry pi

So I am new to this, I followed this tutorial https://pimylifeup.com/raspberry-pi-rfid-rc522/ and did exactly what they said in it. It looks like my RC522 isnt detecting any RFID card. Is there any ...
Danilo Congradac's user avatar
-1 votes
1 answer
86 views

Triggering MAPIR camera with PWM via GPIO on RPi

I have similar setup as this post: PWM via GPIO to trigger a MAPIR Camera but a different camera: https://www.mapir.camera/collections/survey3/products/survey3w-camera-red-green-nir-rgn-ndvi. I am ...
Sulphur's user avatar
  • 109
2 votes
1 answer
143 views

GPIO only outputs 1.8V when using Bluedot

I have setup a basic circuit to control a relay using a Raspberry Pi 4B. I have tried controlling it with both a push button and the Bluedot app. When implementing with the push button, the GPIO pins ...
Nathan De Meyer's user avatar
0 votes
1 answer
79 views

I inverted 2 GPIO pins. Is pi4 dead?

friends. I plugged in an LCD screen using single cables and accidently inverted the two top pins, numbers 1 and 2 as per the image reference. So 1 on the screen went into 2 from the Pi and vice versa. ...
Lucas Mauro's user avatar
1 vote
2 answers
294 views

hc-sr501 goes high every minute

So I bought three HC-SR501 PIR and all of them keep trigging (high) every single 60 second on the dot. I don't know what I am doing wrong. The PIR does detect motion when a person is moving but it ...
Rick's user avatar
  • 11
0 votes
0 answers
112 views

Picam preview shows on HDMI monitor, but not GPIO connected display. How to fix?

I'm making a project that requires an automatic and constant preview from the camera shown on a small LCD display. I managed to have the camera preview upon the Pi startup by adding raspivid -t 0 -f ...
RPi Noob 07's user avatar
1 vote
0 answers
126 views

GPIO script that counts each time a reed switch is activated

My goal is to attach a magnet to a hamster wheel and use a reed switch to determine the distance traveled and speed of my hamster over a long period of time (several weeks/months) and output it as an ...
Adriana's user avatar
  • 11
0 votes
0 answers
61 views

Pull up and external interrupt output on GPIO of a raspberry pi 4

Currently I am working on programming some pins of the GPIO interface on a Raspberry pi 4 without using any high-level library (like wiringPi etc...). I just found this link that was helpful (https://...
falcon_977's user avatar
0 votes
1 answer
100 views

I am trying to make a camera turn on and off with the press of a button, but the GPIO ports are not working, and it is not acknowledging the button

I am using python, and I am getting an error where it says "GPIO.output(24, False)" in the else statement. I don't know what it means, or how I fix it. from picamera import PiCamera from ...
Jase Anger's user avatar
0 votes
0 answers
47 views

Connecting LEDs via Joy-IT ProtoShield+ GPIO

I am starting my first Raspberry Pi project and want to start with controlling some LEDs. I bought a Joy-IT ProtoShield+ (https://joy-it.net/en/products/RB-Proto+) for prototyping but I do not ...
derfred's user avatar
  • 101
1 vote
0 answers
40 views

How to set the suitable value on gpio for PWM?

I have this python code: #!/usr/bin/env python # servo_demo.py # 2016-10-07 # Public Domain # servo_demo.py # Send servo pulses to GPIO 4. # servo_demo.py 23 24 25 # Send servo pulses to ...
BiLLaKoS's user avatar
0 votes
1 answer
564 views

how to power motors correctly on raspberry pi pico

I was using my raspberry pi pico and testing motors, and it worked just fine(pins was in GND + 3v3 pins). Then I wanted to use On/Off function in C, And i used the pin GP28_A2 to use it. But it wont ...
Stigl's user avatar
  • 9
0 votes
0 answers
149 views

C programming - Cannot open /dev/ttyS0 in blocking mode

I am trying to open /dev/ttyS0 in order to write over serial GPIO pin 8. I am using the Raspberry Pi Zero W and noted something strange. When I try to open dev/ttyS0 in nonblocking mode, I am able to ...
Zhendos's user avatar
0 votes
3 answers
416 views

Simple float switch sensor frying GPIO pins, while the other doesn't? Hydroponics system

I'm building this mostly finished hydroponics system. It's a surge tank build. Surge tank looks like: (that's nutrient water, it's got electrolytes that plants crave) Inside that bucket are two ...
Slight's user avatar
  • 103
1 vote
0 answers
74 views

Not getting an GPIO output

I am trying to light a led with the raspberry pi 3b, but I am failing to get an output. I connected the LED to physical pin #11: [img]https://i.imgur.com/TYeJc10.jpg[/img] And to physical pin #6(...
lars2203's user avatar
0 votes
1 answer
40 views

Arming an AreoStar ESC with Raspberry Pi to manage brushless motors

I am trying to set up a brushless motor so I can control it via python. I have a AreoStar ESC and the manual says to enter the menu for the motor you must first set the throttle to 100%, then plug in ...
John's user avatar
  • 109
0 votes
2 answers
538 views

GPIO detects rising edge but does not change status to 1 [closed]

I am really confused: I have a lightbarrier connected over an optocoupler (ACPL-827) with my Raspberry Pi. When the lightbarrier gets triggered (detects a rising edge), it calls the scan-function. ...
leolumpy's user avatar
2 votes
1 answer
42 views

NodeJS cannot read some RaspberryPi GPIOs

I want to read 5 buttons from RaspberryPi. I installed the latest 64-bit OS bullseye on brand-new Raspberry 4B. But somehow only GPIO23 can be read, the other GPIOs can not. When I connect GPIO23 to ...
Mubin Icyer's user avatar

1 2 3
4
5
67