Hi,
When writing 1 using analogWrite to a PWM pin, the associated pin that is connected on the same EHRPWM module also outputs 1.
Trying to write 0 to this associated pin doesn't change the output and it can only be set to 0 if we use analogWrite to set it to 1 first.
The example below will result in P9_14 and P9_16 both outputting 1.
const b = require('bonescript');
b.pinMode('P9_14', b.ANALOG_OUTPUT);
b.analogWrite('P9_14', 1, 2000);
I've only tested the following pins so far and they all appear to have the same issue.
- P8_13 and P8_19
- P9_14 and P9_16
- P9_21 and P9_22
I found a similar issue already posted here #15 but we are unable to use the suggested workaround of using pins that aren't connected on same EHRPWM module.
Thanks,
Aidan
Hi,
When writing 1 using analogWrite to a PWM pin, the associated pin that is connected on the same EHRPWM module also outputs 1.
Trying to write 0 to this associated pin doesn't change the output and it can only be set to 0 if we use analogWrite to set it to 1 first.
The example below will result in P9_14 and P9_16 both outputting 1.
I've only tested the following pins so far and they all appear to have the same issue.
I found a similar issue already posted here #15 but we are unable to use the suggested workaround of using pins that aren't connected on same EHRPWM module.
Thanks,
Aidan