again:
the DATA statement doesn't work the way you are using it, see PBP Manual section 5.11
the EEPROM statement doesn't work that way either, see PBP Manual section 5.18
DATA WORD 1500
would do the trick.
OR: split your word into two bytes and use:
DATA @0,$DC,$05
(Attention, LowByte is first in this example!)
If you want the HighByte first you have got to swap the Byte order in your READ and WRITE statemenst as well.
B.T.W.
you could make your life a lot easier by moving to a more up to date PIC like the 16F628 or 16F88 (which is Loader compatible!) or one of the many others...
...you could get rid of the external Resonator (or Crystal with it's Caps)
Another thing I have seen in your code example is:
your Buttons appear to be active HIGH, means you have got to have PullDown resistors at the corresponding PIC Pins.
If you would reverse this logic you could even get rid of these resistors and use the PICs internal weak pullups.
regards
Ralph
_______________________________________________
There are only 10 types of people:
Those who understand binary, and those who don't ...
_______________________________________________
Bookmarks