Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

who could tell me what's wrong? about PICC

Status
Not open for further replies.

kerden

Junior Member level 3
Joined
Dec 11, 2004
Messages
25
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
284
fixup overflow in expression picc

"D:\i2c eeprom\hex\my_i2c\hex\run_mode.obj" -M"3.map" -O"3.cof" -O"3.hex" -Q -MPLAB -16F877A
Error[000] run_mode.rlf 60 : Fixup overflow in expression (loc 0x71 (0x71+0), size 1, value 0x101)
Error[000] run_mode.rlf 80 : Fixup overflow in expression (loc 0x71 (0x71+0), size 1, value 0x100)
BUILD FAILED: Sat Jan 15 00:52:58 2005

thank you for you help!!
 

not made in the presence of a prototype

kerden said:
Executing: "C:\HT-PIC\BIN\PICC.EXE" -C -E"main.cce" "main.c" -O"main.obj" -Zg9 -O -ASMLIST -Q -MPLAB -16F877A
Error[000] D:\i2c eeprom\1_12\hex\main.c 51 : Can't generate code for this expressionHalting build on first failure as requested.
BUILD FAILED: Tue Jan 11 11:36:33 2005

thank you for you help!!

This is not very clear, however it seems that you are using 2 drives here ( C:\ & D:\ ) and you have not specified the paths correctly, in other words half the data is on drive c: and the other half on drive d: and with the path not specified it cannot execute.Try moving the data on drive d: to your c: drive, or specify the path in your autoexec.bat.

Hope this helps.
 

define kerden

thank you ,

today i have seen the datasheet of the 16f877 .it says function shouldn't exceed 2k. so it doesn't like 8051 .is realy? how could i avoid that?

thank you for you help!

yours

kerden
 

pclint picc

kerden said:
Executing: "C:\HT-PIC\BIN\PICC.EXE" -C -E"main.cce" "main.c" -O"main.obj" -Zg9 -O -ASMLIST -Q -MPLAB -16F877A
Error[000] D:\i2c eeprom\1_12\hex\main.c 51 : Can't generate code for this expressionHalting build on first failure as requested.
BUILD FAILED: Tue Jan 11 11:36:33 2005

thank you for you help!!

Can you please post line 51 of your main.c?

kerden said:
thank you ,
today i have seen the datasheet of the 16f877 .it says function shouldn't exceed 2k. so it doesn't like 8051 .is realy? how could i avoid that?
thank you for you help!
yours
kerden

The 16 series (and others) uses banked codesegment if a function needs more than 2K you must split it into at least 2 smaller functions because it is not possible to generate more than 2K continuos code.

But you must take care that the stack size is limited to 8 on the PIC 16F877 (and others).

best regards
 

how to scan a variable in picc

Hello Kerden,
I'm not an expert.

But seems like you need to post some code. May someone could spot it for you.
 

picc nop

think you for all help!

i don't understand how to stick the code on it .

it seems not allow me to stick such large code in the forum,and who can tell

me how to stick.

i am very sorry.i come from china and know little english.so i can't faultlessly

express my meaning.but i hope i can get help from you .

thank you !
 

ht pic 7.87 pl2

kerden said:
think you for all help!

i don't understand how to stick the code on it .

it seems not allow me to stick such large code in the forum,and who can tell

me how to stick.

i am very sorry.i come from china and know little english.so i can't faultlessly

express my meaning.but i hope i can get help from you .

thank you !

You can either post a few lines only your error is indicated at line 51 of main.c so you could post lets say lines 45 to 60 or you can make a zip or rar archieve of your sourcecode and add it as an attachment.

hope this helps and best regards
 

fixup overflow in expression mplab

thank you !

originally i want to make the project into RAR or ZIP.

but now i could stick them into three part.

there are three file about C 1:my_eeprom.c 2:my_i2c.c 3:main.c

include two file about define 1:my_eeprom.h 2:my_i2c.h

beacause i finish them just now ,there isn't any explaintion for sentence.
 

int.eeprom.hex

Hi

I made a quick scan of your main.c with PCLINT here is the result:

I would start to correct these problems and then try to compile the code :)

best regards

PC-lint for C/C++ (NT) Ver. 8.00k, Copyright Gimpel Software 1985-2003
--- Module: E:\WINDOWS\Desktop\kerden\main.c

--- Module: E:\WINDOWS\Desktop\kerden\main.c
_
#define uchar unsigned char
my_eeprom.h 2 Info 760: Redundant macro 'uchar' defined identically at line
2, file my_i2c.h
my_i2c.h 2 Info 830: Location cited in prior message
_
#define uint unsigned int
my_eeprom.h 3 Info 760: Redundant macro 'uint' defined identically at line 3,
file my_i2c.h
my_i2c.h 3 Info 830: Location cited in prior message
_
continue;
E:\WINDOWS\Desktop\kerden\main.c 39 Info 725: Expected positive indentation
from line 38
E:\WINDOWS\Desktop\kerden\main.c 38 Info 830: Location cited in prior message
_
if( Delay_minute < 1) return 0;
E:\WINDOWS\Desktop\kerden\main.c 64 Warning 503: Boolean argument to

relational
_
Output_water();
E:\WINDOWS\Desktop\kerden\main.c 92 Info 718: Symbol 'Output_water'
undeclared, assumed to return int
E:\WINDOWS\Desktop\kerden\main.c 92 Info 746: call to function
'Output_water()' not made in the presence of a prototype
_
Input_water();
E:\WINDOWS\Desktop\kerden\main.c 97 Info 718: Symbol 'Input_water'
undeclared, assumed to return int
E:\WINDOWS\Desktop\kerden\main.c 97 Info 746: call to function
'Input_water()' not made in the presence of a prototype
_
if(Unauto_mode()) return 1;
E:\WINDOWS\Desktop\kerden\main.c 115 Info 718: Symbol 'Unauto_mode'
undeclared, assumed to return int
E:\WINDOWS\Desktop\kerden\main.c 115 Info 746: call to function
'Unauto_mode()' not made in the presence of a prototype
_
Hand_mode();
E:\WINDOWS\Desktop\kerden\main.c 120 Info 718: Symbol 'Hand_mode' undeclared,
assumed to return int
E:\WINDOWS\Desktop\ker/// Start of Pass 2 ///
--- Module: E:\WINDOWS\Desktop\kerden\main.c
den\main.c 120 Info 746: call to function 'Hand_mode()'
not made in the presence of a prototype
_
#... ; NOP(); NOP(); NOP(); NOP(); NOP(); NOP();
Some_nop();
E:\WINDOWS\Desktop\kerden\main.c 142 Info 718: Symbol 'NOP' undeclared,
assumed to return int
_
#... ; NOP(); NOP(); NOP(); NOP(); NOP(); NOP();
Some_nop();
E:\WINDOWS\Desktop\kerden\main.c 142 Info 746: call to function 'NOP()' not
made in the presence of a prototype
_
Read_time(time_buff);
E:\WINDOWS\Desktop\kerden\main.c 174 Error 40: Undeclared identifier
'time_buff'
_
while(!Wait_Time_Pass(time,Run_Mode))
E:\WINDOWS\Desktop\kerden\main.c 187 Warning 530: Symbol 'time' (line 170)
not initialized
E:\WINDOWS\Desktop\kerden\main.c 170 Info 830: Location cited in prior
message
_
else if(TMR0IF)
E:\WINDOWS\Desktop\kerden\main.c 425 Error 40: Undeclared identifier 'TMR0IF'
 

picc c illegal conversion of integer to pointer

there is some variable undeclare. i have modified and compiler
the result as follows:

Executing: "C:\HT-PIC\BIN\PICC.EXE" -C -E"main.cce" "main.c" -O"main.obj" -Zg9 -O -ASMLIST -Q -MPLAB -16F877A
Warning[000] D:\i2c eeprom\1_12\hex\main.c 101 : function declared implicit int
Warning[000] D:\i2c eeprom\1_12\hex\main.c 106 : function declared implicit int
Warning[000] D:\i2c eeprom\1_12\hex\main.c 124 : function declared implicit int
Warning[000] D:\i2c eeprom\1_12\hex\main.c 129 : function declared implicit int
Warning[000] D:\i2c eeprom\1_12\hex\main.c 183 : illegal conversion of integer to pointer
Error[000] D:\i2c eeprom\1_12\hex\main.c 73 : Can't generate code for this expressionHalting build on first failure as requested.
BUILD FAILED: Fri Jan 14 23:04:45 2005

generally speaking when your mouse double click the error and the mouse will jump to the error .but there is an error "Errow[000]" appears, this kind of solution will be invalid
 

mplab error undeclared funtion

I am sorry but you must post your code again (as an archieve please) as you have edited your source and the line numbers do not make sense with the version I have...

best regards
 

illegal conversion of integer to pointer

hi

i have made them into RAR,you could loaddown the project it will show what i

said.

thank you !
 

function not made in the presence of a prototype

i think there isn't any solecism because the error at the [000] address. so it

must be a address overflow. and i have to cut any function to prove where the

error making .as follows:

"D:\i2c eeprom\hex\my_i2c\hex\run_mode.obj" -M"3.map" -O"3.cof" -O"3.hex" -Q -MPLAB -16F877A
Error[000] run_mode.rlf 60 : Fixup overflow in expression (loc 0x71 (0x71+0), size 1, value 0x101)
Error[000] run_mode.rlf 80 : Fixup overflow in expression (loc 0x71 (0x71+0), size 1, value 0x100)
BUILD FAILED: Sat Jan 15 00:52:58 2005

so i have to cut down any big function "bit Auto_Run(void);bit Unauto_Run

(void);bit Hand_Mode(void);bit Wait_Time_Pass(const uchar time_temp,const

uchar water_mode_temp)".and then it could compile successful;

but when i add the function"bit Wait_Time_Pass(const uchar time_temp,const

uchar water_mode_temp)" it shows the error information liking above ;

and then i disable line "//Read_time(time_buff);" and the error still appearance

in my opinion the function"bit Wait_Time_Pass(const uchar time_temp,const

uchar water_mode_temp)" isn't any big .so it wouldn't Fixup overflow ;

but where is the error comes from?
 

mplab error undeclared identifier

Hi kerden,

I took a closer look at your code and have edited it so it compiles successfully with PICC 7.87 PL2 that I am using.

Your main problem was that you are missing Unauto_Mode I have put in a dummy function.

Also check the calls to Wait_Time_Pass where I had to change the first argument.

I also had to rename my_eeprom.c and my_eeprom.h to myeep.c and my_eep.h because of the dos filesystem that my compiler is using :)

best regards
 

fixup overflow picc

hi,i am kerden.

thank you for answered my question.
i could share the Internet until the day before yesterday.
so i haven't seen you reply about my quesetion.i am so sorry for that.
today i have ckecked in you project.and still have a question:
when i include the "run_mode.h" in the main project.the compiled show many error
but when i copy the code to the main project and compile pass?
why?

thank you !
 

undeclared error mplab include .h

merged with the original thread

Always reply in the original thread!!
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top