View Full Version : DATA command not working properly
khufumen
- 2nd December 2004, 02:19
I have a 16F876 with onboard EEPROM. If I write the following commands
MyByte VAR Byte
DATA @0, 12
READ 0, MyByte
I get 255 for the value of MyByte. However, if I write the following code:
MyByte VAR Byte
WRITE 0, 12
READ 0, MyByte
I get 12 for the value of MyByte. It seems that the DATA command is not loading the EEPROM when the program is downloaded.
Does anyone have any thoughts on this? I could sure use the help.
Thanks,
Eric
mister_e
- 2nd December 2004, 02:25
No problem here, can be programmer setting problem. Wich programmer do you use?
khufumen
- 2nd December 2004, 02:38
I am using melabs serial programmer.
Is there anything in the configuration file I need to change?
mister_e
- 2nd December 2004, 02:44
mmm, not familiar with those Melabs... Bruce is certainely the guy for that but, is there any setting in your Melabs Programmer to permit/void to fill eeprom data with the current program data??? Can you access directly to EEPROM within Melabs Program?
Bruce
- 2nd December 2004, 03:02
With the MeLabs serial programmer, make sure you have it set to program data EEPROM before programming.
Under Options >> More Options >> Program -- make sure you have a check mark by Data.
DATA will only place values in EEPROM at program time. WRITE does it at run time.
khufumen
- 2nd December 2004, 11:54
Bruce,
You hit the nail on the head!!! Your comments fixed my problem. I was at my wits end and had tried just about every option except the one you suggested. I must say, the help menu for the melabs programmer was not a big help in solving this problem.
Thanks for your help.
Kind Regards,
Eric
Powered by vBulletin® Version 4.1.7 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.