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.

56 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
0answers
135 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 ...
4
votes
0answers
368 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 ...
3
votes
0answers
743 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
25 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
41 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
219 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
108 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
72 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
264 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
63 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
23 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
222 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
109 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
67 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
100 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
102 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
155 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
361 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
1answer
342 views

“initMboxBlock: init mbox zaps failed” when using pigpio library in a daemon using node.js

I am writing a daemon using node.js, running under systemd and it will monitor the status of the power supply voltage on a raspberry pi 2 B. I am using the node.js wrapper to the pigpio library The ...
1
vote
0answers
420 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
1k 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
167 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
97 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
226 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
1answer
21 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
20 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
47 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
43 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
1answer
33 views

pigpio bsc_xfer_t char problem

I am implementing an I2C slave in c with PIGPIO and I have run into a snag. I want to send numbers. The struct is typedef struct { uint32_t control; /* Write */ int rxCnt; ...
0
votes
0answers
88 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
25 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
62 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
32 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
50 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
47 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
62 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
14 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
50 views

How to track steps of multiple stepper motors with different frequencies

I’m working on a small stepper motor driven vehicle powered by a Raspberry Pi 3B. For the motor control, I am using the hardPWM function of the pigpio library from Joan, which is working great. I can ...
0
votes
0answers
230 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
72 views

Stepper motor control using wavechain

I am having a bit of trouble using the PIGPIO wavechain function. I am using wavechain to accelerate and decelerate the stepper motor(NEMA 17 ,A4988 driver).Is it possible to avoid executing the ...
0
votes
0answers
18 views

Frequencies available for wavechaining using PIGPIO library

I am working with the PIGPIO library to run stepper motors. I am using wavechains to the STEP pin of the driver. I need help regarding the possible pulse frequencies available for wavechaining. I ...
0
votes
0answers
76 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
50 views

Generating multiple square waves simultaneously

I'm trying to generate 2 simultaneous square waves (50% duty cycle PWM signals) to step two stepper motors (STEP signal to separate motor drivers) on the Raspberry Pi Zero W. I use GPIO12 and GPIO19, ...
0
votes
0answers
226 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
89 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
164 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();...
0
votes
0answers
31 views

Attempting to read from GPIO23 but it only reads 0

I am trying to follow this guide on making an ir receiver/blaster. Currently I am trying to work on the receiver end of things but the pin reads 0 at the beginning instead of 1 like the guide says. ...
0
votes
0answers
139 views

How can I make the JustBoom DAC HAT not interfere with pin #22?

I've got the following tricky problem: I'm using pin #22 (GPIO25) of my Raspi 3B as a GPIO input and read its state by using the pigpio function gpioSetAlertFunc (25, relay::IgnitionISR), where relay::...
0
votes
1answer
500 views

GPIO Newbie, can i connect this Crazepony FPV Camera to the Raspberry Pi?

I am a complete noob when it comes to RPi and GPIO I want to connect 2xthis Crazepony FPV Camera 1.2G 1000TVL 1/4 CMOS 2.8mm Lens FOV170 Degree NTSC Mini FPV Camera to the RPi over GPIO pins, but don'...