It is better not to use the PS_1/2 - PS_1/256 constant because the compiler makes the / simbols to divide process. I use 0-7 number instead of constant. The code seems simplier.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
It is better not to use the PS_1/2 - PS_1/256 constant because the compiler makes the / simbols to divide process. I use 0-7 number instead of constant. The code seems simplier.
GCBASIC is pretty lenient about constant names - only these things are banned:
- ;
- '
- :
- "
- spaces
Any other symbol is treated as part of the constant name. Here is an example of how GCBASIC compiles an InitTimer1 command on an 18F4620:
;InitTimer1 Osc, PS1_1/8
movlw 1
movwf TMR1SOURCE,BANKED
movlw 48
movwf TMR1PRES,BANKED
call INITTIMER1