
Originally Posted by
Darrel Taylor
If you un-comment B or C, then you end up with invalid statements.
But in general, it looks like your program is larger than the chips memory.
No way to know with only a snippet of your code.
And, it would be easier to load the SetPoint this way ...
Code:
@ MOVE?CP 21746FD9h, _SetPoint
SetPoint(4) = 7
Thanks Darrel,
chips memory should be 32k (18F4550) and within the IF statement only two times by = by and not any SetPoint "statements" then the compiled size is 28692 bytes. That is the strange thing here, how can one explain that?
I tested this:
@ MOVE?CP 21746FD9h, _SetPoint
SetPoint(4) = 7
no problems, once,
BUT
when there more than one then the problems are "familiar"
from those earlier mentioned. It seems that .... only guessing, that the compiler is allergic to SetPoint
of course not so, but again there is something here that I do not grasp...
OR
do I miss something from the hole picture here
Here is the code with more @ MOVE?CPs:
Code:
@ MOVE?CP 21746FD9h, _SetPoint
SetPoint(4) = 7
@ MATH_DIV _SetPoint, _Position, _Error
@ MOVE?CP 21756FD9h, _SetPoint
SetPoint(4) = 6
@ MATH_DIV _SetPoint, _Position, _Error
@ MOVE?CP 21766FD9h, _SetPoint
SetPoint(4) = 5
@ MATH_DIV _SetPoint, _Position, _Error
@ MOVE?CP 21776FD9h, _SetPoint
SetPoint(4) = 4
@ MATH_DIV _SetPoint, _Position, _Error
Bookmarks