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.
3,338
questions
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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´...
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-...
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 ...
-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 ...
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+...
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 ...
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) ...
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 ...
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,...
-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 ...
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 ...
-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 ...
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 /...
-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 ...
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 ...
-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 ...
-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 ...
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 ...
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)
...
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 ...
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 ...
-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 ...
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 ...
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. ...
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 ...
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 ...
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 ...
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://...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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(...
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 ...
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. ...
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 ...