PDA

View Full Version : Problem with Data Statement



grahamg
- 25th May 2009, 09:22
I am trying to initalise the eeprom data to a fixed value eg. Data @0,0(200) When I try to compile Pic Basic pro 2.5 crashes. If I change the statement to Data @0,0(127) everything is ok. Looks like it crashes if eprom address exceeds 127. Pic used is a 16f886. It has 256 bytes of eeprom. Can anyone help?

Graham

Darrel Taylor
- 25th May 2009, 11:31
Ooooo, nasty crash indeed!
That's good for a report to [email protected]

It seems to have a problem if the number of bytes used is all in the same DATA statement.

Even with it like this ... it still crashes

DATA @0,0(100),0(100)

But breaking them into 2 lines works fine
DATA @0,0(100)
DATA 0(100)

Darrel Taylor
- 25th May 2009, 22:16
Also, a single line without the address modifier will fill the entire EEPROM area without error.

DATA 0(256)
It must be the address causing the crash.
<br>