Questions tagged [rpi.gpio]

rpi.gpio refers to the package name of a Python module for accessing the Raspberry Pi's GPIO pins. The module allows GPIO pins to be initialised, turned on, and turned off. It uses a functional programming style.

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

Is it possible program GPIO PINs using Microsoft MakeCode?

It is possible to run Microsoft Make Code on a Raspberry Pi. But it looks like I can select a bunch of boards but not a Pi. Is it possible to program the GPIO pins on the Pi by running Make Code on ...
0
votes
1answer
34 views

Turn On/Off 3D printer projector with Python/GPIO

There are similar questions but I don't want to turn on the LED but the 3D printer projector(NQM Plus Light engine) for the image projection. The pins that I wanted to use are shown in the picture. ...
3
votes
1answer
51 views

Sending a binary data stream to a GPIO at a certain frequency

I would like to send a random binary data sequence to a rpi GPIO at a particular frequency and then read the data stream off a scope. Is there a way of implementing this through python?
1
vote
0answers
144 views

How to connect ST7789 LCD to Raspberry Pi

I'm trying to connect to this LCD ( sry 4 japanese page:( use translate plz ) This monitor driver is ST7789, 7pins.[GND VCC SCL SDA RES DC BLK] And now I'm connecting to pi like this https://imgur....
0
votes
0answers
22 views

How to make more efficient reading of GPIO

My (python) program (on Raspberry Pi zero W) turns on/off a GPIO pin (connected to a relay module) depending on the RSSI signal of my phone (connected via bluetooth) and the status of one more GPIO ...
0
votes
0answers
25 views

Timed trigger for GPIO input

I'm running a raspberry pi system that records fish as they swim passed an IR break beam sensor at a fish ladder. So far the system works well but I'm trying to cut down some of the false triggers. ...
2
votes
0answers
23 views

PWM on pump not working as expected

I am attempting to run a PWM on a pump using rpi.GPIO using the following code: def run_PWM_on_pump(): gpio.setmode(gpio.BOARD) gpio.setup(8, gpio.OUT) p = gpio.PWM(8, 0.5) #also works at ...
1
vote
3answers
124 views

How Can Rpi3B+ Detect MQ9 Gas Sensor's Carbon Monoxide Leakage, Without Using ADC?

I already have bmp180 sensor connected to raspberry pi 3b+, now I want to add MQ9 sensor like this https://e-radionica.com/en/mq9-gas-sensor.html Is connection straight forward like the bmp180? ...
0
votes
0answers
22 views

Module not found Error

I am working on rasberry3 pi b+ model for my project and I did installed NOOBS zip file and stored in Micro SD card and put in SD slot on Rasberry Pi b+. When i'm compiling my python code for my ...
3
votes
2answers
232 views

How to connect ST7789 LCD to SPI Bus 1 as 2nd screen?

I've been trying to get this ST7789 library working with the 240x240 1.3" display on the rpi0w Python lib https://github.com/solinnovay/Python_ST7789 So far I've set all the screen pins to the bcm ...
3
votes
2answers
2k views

Where are the uarts on the raspberry pi 4?

The raspberry pi 4 has at least two uarts (as shown here), I know where I can connect to one of them. Pins 8, 10 and 12 have a uart as an option. Source: This site describes accessing uart1, where ...
2
votes
1answer
88 views

How to connect EEPROM to Raspberry Pi 3?

I was wondering on how to connect an EEPROM chip to the Raspberry Pi 3? And any suggestions on which EEPROM chip model is best to use with RPi3?
0
votes
0answers
39 views

pad4pi (rpi_gpio) Library “registerKeyPressHandler” not working as expected

I'm currently writing a python program, that initializes the fingerprint sensor at first then showing the number of used templates on the fingerprint sensor after pressing "1" on the matrix membrane ...
2
votes
1answer
56 views

How to install a library on the Raspberry pi 3 without internet?

I've to install the RPI.GPIO library on my raspberry pi 3, on the other hand, I don´t have acess to the internet in this. I'd already download the library in another computer and put this in my USB ...
0
votes
1answer
44 views

Why the same GPIO pin is not working anymore?

I was working with a very simple code: import RPi.GPIO as GPIO GPIO.setmode(GPIO.BCM) GPIO.setup(24,GPIO.OUT) GPIO.output(24,GPIO.HIGH) But after running one time when I am running the code nect time ...
2
votes
2answers
167 views

Is there any built in LED connected with GPIO pin?

In Arduino a built in LED is attached with number 13 Digital pin. Is there any LED like Arduino in Raspberry Pi,which I can use to test my code?
0
votes
2answers
55 views

Communicate with GPIO HIGH/LOW between 2 PIs

I have 2 raspberry PIs 1x PI3 and 1x PIZero with camera attached. I want to set up a system to have a output GPIO pin on the PI3 and a input pin on the pizero connect so that when I set the PI3 pin ...
0
votes
1answer
58 views

RPi.GPIO “flush” interrupts

Intro It seems to me that when one adds and event detection, then removes it and the adds it again, something strange happen: 1) an event is removed to the "detection list"; 2) the event happens; 3) ...
1
vote
1answer
937 views

Is the gpio readall command compatible with RPi 4?

It's already a while since I got my Pi 4, but never used the gpio readall command until yesterday. I have run into an interesting error. pi@raspberrypi:~ $ gpio readall Oops - unable to determine ...
1
vote
1answer
110 views

GPIO pin (BCM 12) acts differently on PI3 and PI4

The following code is running on PI3 and is working perfectly fine. I try to provide a short description of what the code does. In this code I first set the BCM 12 as the pin of interest for my sensor ...
0
votes
1answer
131 views

Barcode Scanner using RX & TX (GPIO) PIN

Im having some issues reading from a barcode scanner module.. The scanner works just fine if it is used with a USB adapter, my goal is to use the RX & TX GPIO of my RPi to control it. What I am ...
0
votes
0answers
26 views

RPi 3B power supply and external USB Hub issue

I am building a project with a custom USB hub attached to one of the RPi USB ports. On the custom hub I attach 7 USB devices powered by their own batteries. The custom USB Hub is equipped with an ...
0
votes
1answer
27 views

Commercial PIR intergration with Raspberry pi zero

Here is the problem I face. I have a commercial PIR and wondering if it can be seamlessly connected with my pi zero w and how. PIR specs: https://www.thecrowgroup.com/cr/uploads/2019/03/Datasheet-...
0
votes
0answers
59 views

RPI GSM Add-on SIM800 AT commands are not working

I am trying to send sms using RPI Add on v22 module and Raspberry-pi 3+. I have mounted this module on top of Raspberry-pi. When I use minicome using minicom -D /dev/ttyS0 -b 115200 -o I get the ...
1
vote
1answer
67 views

GPIO PWM. ESCs still run different after calibration

I’m putting a quadcopter together. I’m using a python script to calibrate the ESCs... they beep like a blinking led when I give them power. Then I run the calibrate script and they give me the proper ...
0
votes
1answer
38 views

2 Motors functioning unevenly - right motor gets more power than the left

I'm trying to execute this piece of code to run 2 motors on my robot. The code is really simple it's just repetitive. For some reason that I can't figure out, the motors run unevenly. Here is the ...
3
votes
1answer
145 views

pi4 no module named gpio

I am trying to import rpi.gpio in my geany on pi4, but it comes with error no module named gpio. The odd is that i updated pip and python and installed successfully with sudo apt-get install python3-...
-2
votes
2answers
92 views

Runtime warning: This channel is already in use, continuing anyway [duplicate]

I'm trying to fix this code for a robot with multiple sensors. The values of TRIG and ECHO are input through another part of the code. Set this at the beginning of the code def init(): GPIO....
1
vote
1answer
45 views

Value of GPIO.input() automatically change

I have a simple code that read the input from pin 17 (BCM). import RPi.GPIO as GPIO from time import sleep GPIO.setmode(GPIO.BCM) GPIO.setup(17, GPIO.IN) try: while True: print(GPIO.input(17))...
0
votes
1answer
64 views

/etc/init.d/lirc doesn't exist

I am working on creating an IR remote for an older TV using my GPIO, primarily using this tutorial http://www.raspberry-pi-geek.com/Archive/2015/10/Raspberry-Pi-IR-remote#article_l1. However, when I ...
2
votes
1answer
78 views

I2C Communication between Arduino and RPi failing when Arduino is sending data

I'm trying to read some data from the Arduino slave and when I receive the data it shows some numbers but not the correct ones. I'm using node and i2c-bus module, also tried with wiringPi but got the ...
0
votes
1answer
44 views

Water Sensor Pull_Down

I've got the classic Iduion Water Sensor (Link) and I want it to simply detect the presence of water but I get unreliable readings when using it like this: import RPi.GPIO as GPIO import time GPIO....
4
votes
1answer
110 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
0answers
348 views

How fast can GPIO pins toggle on the Pi 4?

Benchmarking of the Pi 4 using the Python GPIO Zero library shows a significant increase in the frequency of toggling a GPIO pin on and off compared to previous models. This result is attributed to ...
1
vote
1answer
59 views

Pausing code execution till a button is pressed

I'm trying to pause code execution till a button is pressed and this is what I came up with. I have not tested this but can anyone tell me if this is the right way to go about it? Button 'pressed' is ...
0
votes
1answer
58 views

Is there a piece of hardware which enables hotplugging sensors to the breadboard?

The idea is the following: I have a Raspberry PI connected to a breadboard. To this breadboard, I would like to connect (digital and analog) sensors and actuators while the PI is running. Or remove ...
1
vote
1answer
31 views

RC522 modules stop working when more than 2 are connected

So, here's a synopsis of what I am trying to do. I want to put 3 RC522 readers side by side inside of a book, facing the cover, that will be constantly on, using a Rpi zero W. When an RFID chip gets ...
1
vote
0answers
116 views

raspberry pi3 + fingerprint

I'm looking for a way to connect fingerprint scanner with raspberry pi3 using python. I'd like to use only gpio or hat (not usb) interface. I'm searching for a while without figured out, so I've ...
1
vote
1answer
79 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 ...
1
vote
1answer
170 views

Raspberry Pi 3 B+ was connected to NRF24L01 in the following manner as in diagram but Raspberry pie not working after that why? [duplicate]

I connected VCC to 3.3V and GND to 5V of raspberry pie mistakenly. Now raspberry is only showing red light on and no green light blinking. What might be the probable reason. Is there any solution so ...
-1
votes
1answer
105 views

Segmentation fault error. Trying to loop a python program [closed]

I'm using AT commands to send data over http, but the problem is that sometimes the program has an error and wont run again until I reboot and the GSM. Im using a crontab and also running the file as ...
0
votes
1answer
25 views

Corrupted image file when using win32 [closed]

What things make the file is corrupted and not readable as an image file?! if the sd card is read-only, this prevent that I able to take a copy from it??!
2
votes
0answers
42 views

How to run 3 Input scripts from 1 script

I've got an alarm system with 3 inputs and 3 outputs. But so far each input is controlling the outputs from it's own script. I did this because I wanted to get one thing at a time working on its own. ...
1
vote
1answer
37 views

How Can I Determine Why My Python Script Is Terminating?

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 and made two copies of the ...
1
vote
1answer
832 views

Why is PIR motion Sensor always on?

I'm trying to make an alarm system but the motion sensor is always on as soon as the script is run. I've posted a question about a different problem i was having with this project so it'll confusing ...
1
vote
3answers
250 views

How to stop LEDs blinking when button is pressed

I've got 4 LEDs, a buzzer and a button. There's an add_event_detect to switch the LEDs and buzzer on and off. The callback methods works find when the outputs are just on continuously until another ...
0
votes
2answers
401 views

Reading only 0 from ADC using RPi SPI

Everytime I try to read analog channel 0 from ADC, it only prints 0. I am confused why. I shorted MISO and MOSI on my RPi to check SPI send/receive and it was working. But if I test it after properly ...
2
votes
1answer
84 views

While reading RC522 RFID reader keypad won't work

I am using pimylifeup library to read RFId card. But after id, text = reader.read(), I don't get reading from 4×4 keypad. I tried with both BOARD and BCM numbering to read keypad. I have to exit the ...
1
vote
2answers
70 views

Connecting RPi to a motion sensor

I'm new to working with RPi GPIOs, and I never studied electronics so bear with me on this newbie question. I have an RPi 2 Model B, and I'm tasked with detecting a motion detector alarm going off. ...
-1
votes
1answer
94 views

Sg 5010 servo 360 degree modification not working [closed]

As per the video tutorials out there, I opened the motor, took out the potentiometer and measured its resistance at max. Its a b5k pot so it measured 5kohm I put 2.5k ohm from each pin (s and -) and ...