Go to advanced search

by pidood1234
Thu Jan 23, 2020 9:44 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

OK, that should be fine, I think I've seen the issue on a Raspi 3B before. Full disclousure, I don't have a raspi to compile it on now but it should work, since it has minimal additional code other than the pigpio library functions (other than printf and usleep). Thanks!
by pidood1234
Thu Jan 23, 2020 9:12 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

With the new code, it should just run with the minimum PWM required to spin the motor, i.e. (950). But running raspivid simultaneously will then jitter the PWM.
by pidood1234
Thu Jan 23, 2020 9:11 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

Hey Joan, this code should compile. There was std::cout earlier on. Also added a while (1) { ... ; usleep(1000);} #include <pigpio.h> #include <stdio.h> #include <unistd.h> // for usleep int main(){ unsigned sampleRateUs = 1; // default = 5! unsigned configPeripheral = PI_CLOCK_PCM; // changing this...
by pidood1234
Mon Jan 20, 2020 10:26 am
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

Cool thanks Joan! FYI the brushless is driven by a brushless ESC and batteries at 12V. That ESC, brushless motor and battery setup may be replaced with some kind of PWM reader. Otherwise the ESC signal can be driven by the GPIo and also grounded. Thanks!
by pidood1234
Sun Jan 19, 2020 9:16 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

hardware: raspi zero W camera V2 brushless motor OS: Rasbian Jessie Lite OR Raspbian Buster Lite Minimal image based on Debian Buster Version: September 2019 Release date: 2019-09-26 Kernel version: 4.19 Size: 435 MB unsigned sampleRateUs = 1; // default = 5! unsigned configPeripheral = PI_CLOCK_PC...
by pidood1234
Sat Jan 18, 2020 5:00 am
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

joan

If i run a second program in another terminal, I get this error:

Code: Select all

initInitialise: Can't lock /var/run/pigpio.pid
This is while the first program is stuck.
by pidood1234
Sat Jan 18, 2020 4:55 am
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

Thanks for your replies joan and 6by9. joan: You can delete the pid file so you don't need to reboot. sudo rm /var/run/pigpio.pid running this command does indeed delete that pigpio.pid, BUT the first program which had already run gpioInitialize(); gpioPWM(....); gpioTerminate(); never exits, i.e. t...
by pidood1234
Thu Jan 16, 2020 5:11 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

I tried updating the clock source between PWM and PCM, but the issue still persists. Also tried changing up the different channels for DMA primary and secondary channels, also have the same issue. One condition that worked sometimes is that raspivid does not trigger the software PWMs, but what ends ...
by pidood1234
Mon Jan 06, 2020 5:42 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

Re: pigpio software PWM jitters when run together with raspivid

Specifically, raspivid is run in a separate ssh session (headless) , and my pigpio software is run on another ssh session also. The hardware used is raspi zero w. OS used is the latest raspbian.
by pidood1234
Mon Jan 06, 2020 5:40 pm
Forum: Troubleshooting
Topic: pigpio software PWM jitters when run together with raspivid
Replies: 17
Views: 560

pigpio software PWM jitters when run together with raspivid

I’m trying to run software PWM using the pigpio library to generate software PWM. Individually without running raspivid , the spftware works and I can spin a brushless motor. However when I turn on raspivid, the software PWM jitters — specifically, the software PWM is actually output at about 10% wh...
by pidood1234
Fri Jan 03, 2020 4:47 am
Forum: Advanced users
Topic: raspivid and pigpio used together causes kernel panic
Replies: 2
Views: 239

Re: raspivid and pigpio used together causes kernel panic

Thanks Do you use v1 or v2 cameras? V2 camera You don't set mode for GPIO21, and it's default mode in IN. What do you want to achieve in writing to INPUT GPIO? Can you comment out the GPIO12 PWM line as one test, and the GPIO21 lines as a second test. Do you see kernel panic for the reduced tests as...
by pidood1234
Thu Jan 02, 2020 6:15 am
Forum: Advanced users
Topic: raspivid and pigpio used together causes kernel panic
Replies: 2
Views: 239

raspivid and pigpio used together causes kernel panic

Hey, I'm running in to a kernel panic when using raspivid and pigpio together. hardware and OS : raspi zero W and newest OS Raspbian Buster / 2019-09-26 The commands I'm running (separate terminals via ssh) raspivid -t 60000 -0 a.h264 -w 1920 -h 1080 program.c runs pigpio C/IF: gpioinitialize() gpio...

Go to advanced search