inglewoodpete
Senior Member
I am working on a project where I'm driving a 3W RGB LED with 3 PWM channels. The duty of each channel will differ from the other two to give a wide range of colours.
I want to detect the PWM with another PICAXE using a band pass filter/detector front-end set at the PWM frequency. The filter is necessary to desensitise the detector to other lighting g. The filter/detector that I have developed works well when using simple Red, Green or Blue. However, the method comes unstuck with some combinations of colour and duty because the cycle start times are out of phase, leaving one or another of the LEDs 'on' throughout any PWM period.
So, to my question: is there a way of synchronising the leading edge of multiple PWM channels on a PICAXE? I have looked at hPWM but this seems to be limited to each channel having the same duty, which restricts the colour range that I can produce.
Below is a DSO screen snap of the RGB signals from a 28X2. Being only dual trace, I have triggered the oscilloscope on the red channel and the display traces the green and blue PWM signals. All three channels are currently set at 50% duty.
Note: The development work that I am doing, if successful, may be used for personal financial gain.
I want to detect the PWM with another PICAXE using a band pass filter/detector front-end set at the PWM frequency. The filter is necessary to desensitise the detector to other lighting g. The filter/detector that I have developed works well when using simple Red, Green or Blue. However, the method comes unstuck with some combinations of colour and duty because the cycle start times are out of phase, leaving one or another of the LEDs 'on' throughout any PWM period.
So, to my question: is there a way of synchronising the leading edge of multiple PWM channels on a PICAXE? I have looked at hPWM but this seems to be limited to each channel having the same duty, which restricts the colour range that I can produce.
Below is a DSO screen snap of the RGB signals from a 28X2. Being only dual trace, I have triggered the oscilloscope on the red channel and the display traces the green and blue PWM signals. All three channels are currently set at 50% duty.
Note: The development work that I am doing, if successful, may be used for personal financial gain.