Status: Assigned
Owner: robhamerling
Labels: Type-Defect Priority-Medium

New issue 67 by robhamerling: pwm_off()
http://code.google.com/p/jallib/issues/detail?id=67


The PWM libs have a potential problem with pwm_off().
When it is invoked when pwm is off it acts as pwm_on().

For example: current operation in pwm2_off() is:
  ccp2con_shadow = ccp2con_shadow ^ 0b_0000_1100

With every invocation bits 2 and 3 are flipped (0->1 and 1->0). This means
that when pwm_off() is invoked while pwm is already off, bits 2 and 3 are
set, meaning pwm goes on.

Suggested solution:
  ccp2con_shadow = ccp2con_shadow & !0b_0000_1100

This is an example, applies to all pwm_ccp.. libraries



--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/jallib?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to