I keep getting "* USB Pulse Width Error".
Be aware that the "stock" USB PWM code is just something I threw together as a demo of how you can add PWM input to the script. It has not exactly had a lot of user testing in the real world.
In the demo, the error message is displayed when the script checks the CHDK USB PWM control code for the width of the most recent pulse received and is told it's 20 mSec or more. This is an oversight on my part - when the demo code was added, the CHDK high speed timer option was not available so the pulse width values in the demo code are off by a factor of 10. The original intent was for that error to trigger if a pulse of more than 200 mSec was received.
I am utilizing an Arduino Nano to convert from an RC PWM output to the required USB power pulse. I have tested the output on my oscilloscope and it's outputting the correct pulse widths.
To confirm what I have written above, it will help a lot if you tell me what pulse widths your Arduino is producing !
I have been looking through KAP 3.4 and noticed it's using get_usb_power(2), i tried changing this to get_usb_power(0), and now i get one correct pulse width before the error.
Not really sure what is happening here.
Using get_usb_power(0) gets the most recent pulse width but it's unbuffered. You could lose pulses.
More info about all that here :
USB Remote Scripting InterfaceI am very much a newbie when it comes to CHDK programming, so just wondering if anyone has solved this or could hep to solve it?
I think we can probably drag up someone who is somewhat familiar with that script

Once I know what pulse widths you are actually using, modifying the PWM detection code in the script should be trivial. Sorry for not catching that sooner.