You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been using PWM (GPIO 18) without issues. However, I want to also use PIGPIO . It uses PWM, so I tried using PCM (GPIO21) for rpi_ws281x. It almost works.
But, everything is shifted by one. Pixel zero is not addressable. When I write to the 0th pixel, the first pixel gets written instead. When writing to pixel #1, pixel #2 gets written. Etcetera.
GPIO 18 and GPIO 21 are connected on the hardware, so I can easily switch back between PCM and PWM modes.
I'm using invert, since I have an inverter that does level shifting.
When using PWM, the signal quiesces high, which means the output of the invert is low when not writing to the LEDs. But, when using PCM, the signal quiesces low, which means the output of the inverter is high.
Perhaps, a long period of signal low resets the LEDs. But, when the signal is high (like what happens on the output of the inverter when PCM mode is used), spurious transitions don't get cleared. So, the first intentional write hits pixel 1 instead of pixel 0.
This is just a theory. But, I think the signal should have the same signal level in the inactive state, regardless of whether PCM or PWM is used.
This seems like a bug?
The text was updated successfully, but these errors were encountered:
I have been using PWM (GPIO 18) without issues. However, I want to also use PIGPIO . It uses PWM, so I tried using PCM (GPIO21) for rpi_ws281x. It almost works.
But, everything is shifted by one. Pixel zero is not addressable. When I write to the 0th pixel, the first pixel gets written instead. When writing to pixel #1, pixel #2 gets written. Etcetera.
GPIO 18 and GPIO 21 are connected on the hardware, so I can easily switch back between PCM and PWM modes.
I'm using invert, since I have an inverter that does level shifting.
When using PWM, the signal quiesces high, which means the output of the invert is low when not writing to the LEDs. But, when using PCM, the signal quiesces low, which means the output of the inverter is high.
Perhaps, a long period of signal low resets the LEDs. But, when the signal is high (like what happens on the output of the inverter when PCM mode is used), spurious transitions don't get cleared. So, the first intentional write hits pixel 1 instead of pixel 0.
This is just a theory. But, I think the signal should have the same signal level in the inactive state, regardless of whether PCM or PWM is used.
This seems like a bug?
The text was updated successfully, but these errors were encountered: