Questions tagged [pigpio]

pigpio is a library for accessing GPIO pins as well as other functions including I2C. pigpio has a client-server architecture , which enables you to remotely control GPIO pins.

58 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
0answers
583 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 ...
5
votes
0answers
147 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 ...
3
votes
0answers
807 views

How to use pigpio to control 3 stepper motors with drivers

I need to control 3 independent stepper motors with stepper motor drivers using RPi. Driver of each motor requires STEP pulse to make one step (let's not bother about DIR and ENABLE signals for now). ...
2
votes
0answers
30 views

Problem with PI GPIO using BB SPI

I've developed a PI Python application to replace an old control card which sent bit banging out to daisy chained LED drivers. It all works fine except when I need some fast updating of the LED's. ...
2
votes
0answers
47 views

Waveform not cancelling out hardware PWM

I've run into problems using pigpio's wave generator in combination with hardware PWM. Currently I'm working on a motion control with acceleration/sustain/deceleration phases. The phases are saved ...
2
votes
1answer
378 views

Pigpio not calling Callback for first rising or falling edge

I have some sample code (taken out of my larger program) that regularly (but not always) missing the first rising edge: #!/usr/bin/python import pigpio, time def callback(g, l, t): print("Callback ...
2
votes
2answers
167 views

pigpio I2C reply value

I'm sending a command e.g. "wifion" with I2C arduino(master) to RPI(slave) That works perfect but I need to return a confirmation value. How can I send back/reply from the RPI to the Ardunio a value? ...
2
votes
0answers
74 views

Trying to use pigpio wavechains to drive very specific acceleration and deceleration

I'm working on a kinetic sculpture that involves a large pendulum swinging perpetually left to right. I'm using a raspberry pi 3 B+ / arduino uno with a DM860AC to control a nema 34 stepper. I was ...
2
votes
0answers
277 views

Any GPIO library that supports I2C multi-master mode?

I am thinking of joan's PIGPIO library but I am aware there are others for the RPi, and I was wondering whether there are any that support multi-master I2C mode? As far as I can tell {see here} this ...
2
votes
0answers
2k views

Using SPI with pigpio to transfer data to Pi from an ADC

I've purchased an AD/DA Board in order to use analog inputs in my Pi, here it is: http://www.waveshare.com/high-precision-ad-da-board.htm As you can see it has a trimmer in it and I have wired it to ...
1
vote
0answers
12 views

pigpio servo, stop command not reliable

import pigpio import math import RPi.GPIO as GPIO from gpiozero import Button import time GPIO_SERVO_PIN = 27 limit = 17 switch = Button(limit) GPIO.setmode(GPIO.BCM) GPIO.setup(17, GPIO.IN, ...
1
vote
0answers
55 views

JavaScript library for the HC-SR04 Ultrasonic sensor

I wired the sensor to my Raspberry Pi. My aim is to use JavaScript to get a live reading in the console of the distance, but the module I found has been archived by the author. Code that I found on ...
1
vote
0answers
29 views

PiGpio – pass through binary data

I have two ports connected to GPIO on a Raspberry, where I read and send data NMEA sentences to external equipment using the PiGpio library in python, and this is working fine. Now I need to transfer ...
1
vote
0answers
99 views

Raspberry 3 model B v2 I2c slave, ESP8266 I2c master

I try to learn I2C with goal : read my ESP8266 events (I2C master) from my Raspberry 3 model B v2 (I2C slave). I use the Arduino Wire library on the ESP and python pigpio lib on the Raspberry. ...
1
vote
0answers
26 views

pigpio library dependencies missing when compiling Radiohead nRF24 library

I am using Eclipse 2019-06 CDT to compile the Radiohead nRF24L01 library (v1.97) using the pigpio interface (v71) with C++. I get the following errors: rpi/rfs_pizw2/usr/lib/libpigpio.so: undefined ...
1
vote
0answers
96 views

Interrupt issue - Wiringpi and pigpio show different values for pin

I am having an issue with raspberryio/wiringpi interrupts. A lot of extra interrupts are generated. My configuration is as follows: Physical pin 16: Set as input Pulldown resistor Interrupt ...
1
vote
0answers
25 views

Writing to a sensor register using i2c bitbanging library not working - PiGPIO library on Raspberry Pi

I am trying to configure a sensor connected to Rpi over an i2c bus. I am using PiGPIO library with Python to do this. To configure the sensor, I need to write a certain value to some registers and ...
1
vote
1answer
350 views

use GPIO and/or UART to slow initiate K-line (ISO9141-2) communication with Audi ECU

Related to this question I'm learning to use the Pi GPIO and Python serial to communicate through an IC (L9637D) to interrogate PIDs for alarms etc. I can't get past the slow initiation sequence! ...
1
vote
1answer
195 views

PC/Xbox Controller servo control

I am making a project where I want to use a PC/Xbox controller to control my servos with analog sticks. I've been following this tutorial and I've used the code down below to control my servo motor ...
1
vote
1answer
84 views

PIGPIO bit banging UART - SLR to plaintext

I've managed to read UART input by SLRO and SLR commands from pgpiod, however, SLR returns UART bit-banged data in the following format: [number of read bytes] [bytes] http://abyz.me.uk/rpi/pigpio/...
1
vote
0answers
110 views

pigpio monitor GPIO not detecting change correctly

I am having trouble detecting a level change on pin 16 (or any other pin). My script is as follows: import RPi.GPIO as GPIO from time import sleep GPIO.setmode(GPIO.BOARD) GPIO.setup(16, GPIO.IN, ...
1
vote
0answers
110 views

Generate multiple waves with specific number steps in a cycle wave

I want to generate a square wave has frequency 40khz on multiple GPIO pins of Raspberry Pi3 with time in order to start to generate wave (phase delay) is different. I have used a function of PIGPIO ...
1
vote
0answers
176 views

How to configure pigpiod to prevent being affected by aplay

I'm using the pigpiod daemon and Python to output IR signals. I'm using raspbian jessie and rpi 3 model b gpio22 to output to leds. After starting the daemon by sudo pigpiod, it works fine and ...
1
vote
1answer
444 views

Problem handling failed call to pigpio

I've written some python code using pigpio over a network. I have two questions I can't seem to solve myself: Can I change the timeout when calling the pigpidaemon with pigpio.pi(<ip number>). ...
1
vote
0answers
456 views

pigpio: Bad I2C Bus

I'm trying to start an I2c communication with my Raspberry Pi using the pigpio library. It works fine for me with SPI, but I really do struggle with I2C. When I use if (gpioInitialize() < 0) ...
1
vote
0answers
2k views

Cannot get pigpio PWM to work with an AC dimmer module

I am using an AC dimmer module to dim a 240V light. I would like to use node.js so I am using the pigpio module. The script is not working as expected as the light bulb goes straight to 100% when I ...
1
vote
0answers
182 views

how to expand GPIO pin for raspberry but still can use pigpio library

If I want to expand GPIO pin that can use as input/output on raspberry via I2C is whether I can use these pin with pigpio library?
1
vote
0answers
110 views

Why was my last AT command routine is not viewed in the output?

As I was using pigpio ,so that I can use the GPIO pins as UART or bit banging the serial. I am using a SIM900 gsm module. Here is the code: import pigpio import time import sys TX=23 RX=18 baudrate=...
1
vote
0answers
228 views

Pi2 + pigpio + overclock + spi_read

I have an app reading temp + humidity from an AM2301. Using pigpio. Python 3.4.3. Newest firmware (as of 8/14/15) using rpi-update. Code is below. Breaks when overclocking the Pi to anything other ...
0
votes
0answers
46 views

Problem with pigpio library and infrared emitter

I have installed an infrared emitter with the following tutorial: https://www.instructables.com/id/Zero-to-Air-Conditioner-Controller-With-Raspberry-/ But I had trouble running the LIRC commands, so ...
0
votes
0answers
53 views

Pigpio Hardware PWM callback is slow

I am trying to drive a servo motor with Raspberry pi. I have selected pigpio library to access GPIO. I need to send a specific number of pulses with a given frequency. But when I callback a function ...
0
votes
1answer
103 views

Raspberry Pi 4 to Mitutoyo Digimatic interface

I've been trying to interface a Mitutoyo digital caliper. I used the code from here and I think I made the right corrections according to the posters comments but as I checked he was last online in ...
0
votes
0answers
25 views

Raspberry Pi controlled RGB LED strip very dim

I have followed this tutorial https://dordnung.de/raspberrypi-ledstrip/ to hook up my raspberry pi zero w to a 12V rgb led strip. The lights come on and are able to be controlled using pigpiod, ...
0
votes
1answer
33 views

pigpio long wave results in PI_TOO_MANY_CBS

I'm driving a stepper motor with a PI4B and pigpio / Unosquare.PiGpio library for .NET. I'm using the wave module to modulate the pulse to drive the stepper motor. This works pretty good, until I ...
0
votes
1answer
56 views

Using pigpios waves and audio output

I am using a Raspberry Pi 3 B+. I want to play audio through the 3.5mm jack and use PWM at the same time or successively to simulate a IR-Remote. I know that you can't use the hardware PWM while ...
0
votes
2answers
73 views

433mhz Status sockets project

I've been working on getting a Home automation project going for a while, using a Rasp pi 1b (26 pin header). This is a well trodden path by others, as it is a project to control status remote sockets:...
0
votes
0answers
82 views

A stop job is running for Daemon required to control GPIO pins via pigpio

Since I installed Buster I have experienced slow shutdown. A message is displayed:- A stop job is running for Daemon required to control GPIO pins via pigpio and persists for 90 seconds. I have ...
0
votes
0answers
142 views

Raspberry Pi Zero as master communicating with multiple Raspberries Pi Zero over I2C

The project I'm working on involves in total 8 raspberries, one master and all others acting as slaves. The goal is to write to all Pi's and read back their answer. Communication using the master ...
0
votes
0answers
26 views

PiGPIO inconsistent when using servo

so I will do the following command once and it will work and then the same sequence of commands never works again. Any help is appreciated, thanks! The commands are to first arm some ESCs then ...
0
votes
1answer
101 views

Pigpio on callback get value

I currently have some code that I found that constantly outputs a value from a digital caliper. However, I want to modify this so that it is inside a function that can return that is returned from ...
0
votes
0answers
46 views

Busybox init, is it possible to delay execution of init.d script conditionally?

I would like to boot into a python app. My python app has the excellent pigpiod daemon as a prerequisite. I am using Busybox init process. I have a pigpiod launch script /etc/init.d/SXpigpiod and my ...
0
votes
1answer
63 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
0answers
53 views

Connect 3 Raspberry pi using i2c

I'm trying to use i2c to exchange messages between 3 raspberry pi, all of them must receive a message do something and then send a response. Raspberry as an I2C SLAVE From here I came up with a ...
0
votes
1answer
76 views

PWM with pigpio does not trigger alert function regularly

I combine C examples of pigpio for gpioSetAlertFunc and gpioWaveTxSend working with the same pin. My PWM has several pulses, so I expect alert function to print out a message for me several times. ...
0
votes
0answers
15 views

How can I share a C++ class variable between a thread started with the pigpiod start_thread () method and the main thread?

I've got a C++ class containing some class variable like char some_class::current_command. One of the static methods of this class, say void Play () now calls the pigpiod start_thread () method to ...
0
votes
0answers
343 views

How to control the raspberry pi over internet using android app?

I had bought a Raspberry pi 3b+ recently to make many of the projects I had dreamed of. Most of these (or maybe all) involves controlling the GPIO pins over the internet using an app. One of the ...
0
votes
0answers
94 views

using I2C in threads

I have several devices on one I2C Bus and am wondering now what happens, if I have some threads using this one I2C Bus. Do I need to implement a scheduler or is the I2C Bus automatically blocked ...
0
votes
0answers
324 views

pigpio python serial wave output not correct

I am trying to use joan's pigpio to write a serial command on my Rpi 3 gpio 14(UART0TX).My goal is to write a command from the pi to another device. When i send the command i do not see the ...
0
votes
0answers
91 views

How to generate a hardware PWM wave for driving an LED through RPIO?

I've looked through the documentation of RPIO, and used GPIO18 to get my PWM up and running. This is my code: from RPIO import PWM servo = PWM.Servo() servo.set_servo(18, 4000) As explained in the ...
0
votes
1answer
179 views

pigpio, update xfer.txBuf

Question refactored: Im currently struggling to understand how to update the transmit FIFO of the bsc_xfer. For reference: Slave side: int main(int argc, char** argv) { int GPIO = gpioInitialise();...