![]() |
MPLAB error segment
Hi...I'm currently using MPLAB to program pic. I've managed to correct the errors except when this error comes up instead..:ahh:
Error [1347] ; 0. can't find 0x90 words (0x90 withtotal) for psect "text76" in segment "CODE" (largest unused contiguous range 0x31) I do not even know where to start? Anyone knows? Thanks! |
Re: MPLAB error segment
sounds like you have too many variables, or are using too much space in the EEPROM.
look to see where you are defining that variable, (or including the file that does) and see if you can remove it temporarily. You may also consider reducing the size of any arrays or strings you are using that are taking more than absolutely needed. Reminds me of my FIRST days, programming in PBASIC. We only had 26 BYTES of general purpose RAM for variables. I will admit to storing bit flags in extra direction registers and unused pins... |
Re: MPLAB error segment
i was thinking of the variables sizes are over the limit too...but i have no idea how to reduce it. haa..
hmmm...is there a pro version at internet without evaluation period? hee.. |
Re: MPLAB error segment
If you have a "variable" that doesn't change (e.g. a text string), it can be placed in ROM instead of the CODE segment by using the rom keyword at the beginning of the variable declaration.
|
Re: MPLAB error segment
what if its array instead of a text string? for example:
Code:
int delay_addr[]= {9000,4500,560,560,560,1690,560,1690,560,560,560,560,560,560,560,560,560,1690,560,1690,2250,560,560,560,1690,560,560,560,1690,560,1690,560,560}; //0x61d6 |
Re: MPLAB error segment
Quote:
Code:
rom const int delay_addr[]= {9000,4500,560,560,560,1690,560,1690,560,560,560,560,560,560,560,560,560,1690,560,1690,2250,560,560,560,1690,560,560,560,1690,560,1690,560,560}; //0x61d6 |
Re: MPLAB error segment
But i get these errors when i change the code as above.
Warning [374] C:\Documents and Settings\admin\Desktop\ZD\main.c; 33.5 missing basic type; int assumed Error [314] C:\Documents and Settings\admin\Desktop\ZD\main.c; 33.5 ";" expected Btw, i put the above code outside void main (void). Because when i put it inside, there are more errors. |
| All times are GMT -5. The time now is 01:08. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi