Hi William,
I have not tested this library, only did some desk checking.
On 04/10/10 10:04 pm, [email protected] wrote:
+ if target_cpu == PIC_16 then
+ tmr0h = byte(timer0_load >> 8)
+ tmr0l = byte(timer0_load)
+ else
+ tmr0 = byte(timer0_load)
+ end if
Why not let the compiler do the low level work?
if target_cpu == PIC_16 then
TMR0 = timer0_load -- 16-bits timer0
else
TMR0 = byte(timer0_load) -- 8-bits timer0
end if
BTW
1. Registers are declared in uppercase in the device files, so for
consistency a library should use uppercase as well.
2. Some comments just above a procedure or function describing its
functionality will generate (better) documentation (I'm afraid many
libraries are suffering of such comments!).
Regards, Rob.
--
Rob Hamerling, Vianen, NL (http://www.robh.nl/)
--
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.