build all problem

Discuss about beta versions of mikroPascal compiler.
Post Reply
Author
Message
jpc
Posts: 1986
Joined: 22 Apr 2005 17:40
Location: France 87

build all problem

#1 Post by jpc » 20 Feb 2007 22:35

testing some little code on dsPIC 30F3012 i found that library's seem to be included in the definition that are beyond possibility's of this processor. LCD8 is the first it encounters this way, probably some others suffer from the same. Definitions need checking therefore.

jpc
Posts: 1986
Joined: 22 Apr 2005 17:40
Location: France 87

#2 Post by jpc » 20 Feb 2007 23:29

once the above problem occurred the compiler cannot return to 'normal' build , it keeps looking for all units as declared in the definition file. >Even quitting IDE and starting again does not solve the problem , the only way out is to build another program and reload the first after succesfull compilation. Somehow the compiler seems to remember more then we know about.

User avatar
srdjan
mikroElektronika team
Posts: 1552
Joined: 28 Dec 2005 12:47
Location: Serbia

Re: build all problem

#3 Post by srdjan » 21 Feb 2007 08:42

jpc wrote:testing some little code on dsPIC 30F3012 i found that library's seem to be included in the definition that are beyond possibility's of this processor. LCD8 is the first it encounters this way, probably some others suffer from the same. Definitions need checking therefore.
Hi,
You are probably using some of the board based initialization routines for lcd8 like Lcd8_Init_EasyDsPIC3. Sources for this routines are provided with the compiler in order to be adjusted for specific hardware and mcu. If you take a look at the header of this function it specifically says :
Requires : Mcu must have PORTB, PORTD and PORTF with corresponding pins.
It is your responsibility to make sure of that. If you are going to use some mcu other than the one used in the provided example you'll have to modify/adjsut the setup as well.

jpc
Posts: 1986
Joined: 22 Apr 2005 17:40
Location: France 87

#4 Post by jpc » 21 Feb 2007 08:53

no , nothing alike , i only did a build-all instead of normal build . I i compile it for 4013 there is no problem , if io compile it again for 3012 all is ok BUT if next i do a BUILD ALL for 3012 the phenomena returns.

User avatar
srdjan
mikroElektronika team
Posts: 1552
Joined: 28 Dec 2005 12:47
Location: Serbia

#5 Post by srdjan » 21 Feb 2007 12:31

jpc wrote:no , nothing alike , i only did a build-all instead of normal build . I i compile it for 4013 there is no problem , if io compile it again for 3012 all is ok BUT if next i do a BUILD ALL for 3012 the phenomena returns.
Can you please tell me exactly which example have you tried to rebuild for dsPIC3012?!

jpc
Posts: 1986
Joined: 22 Apr 2005 17:40
Location: France 87

#6 Post by jpc » 21 Feb 2007 12:51

ok here a good test : i reduced the led-blinking example and reduced it to PORTB :

Code: Select all

{*
 * Project name:
     Led_Blinking (The simplest simple example)
 * Target Platform:
     dsPIC
 * Copyright:
     (c) mikroElektronika, 2006.
 * Revision History:
     20050410:
       - Initial release;
 * Description:
     Simple "Hello world" example for the world of dsPIC MCUs;
 * Test configuration:
     MCU:             dsPIC30F4013
     Dev.Board:       EasydsPIC2
     Oscillator:      ECIO-PLL4, 10.000MHz
     Ext. Modules:    None.
     SW:              mikroPascal for dsPIC30/33 and PIC24 v5.0.0.0
 * NOTES:
     None.
 *}

program LED_BLINKING;

begin
  TRISB := $0000;
 { TRISC := $0000;
  TRISD := $0000;
  TRISF := $0000;}
  while TRUE do
    begin
      LATB := $0000;
     { LATC := $0000;
      LATD := $0000;
      LATF := $0000;}

      Delay_ms(500);

      LATB := $FFFF;
    {  LATC := $FFFF;
      LATD := $FFFF;
      LATF := $FFFF;}

      Delay_ms(500);
    end;
end.
now i change the processor to 30F3012 , build and compiles ok.
If however i do build all i have the problem. In this example build all is useless but i encoutered this in some code that uses unit , however nothing like using those library's in my unit.

jpc
Posts: 1986
Joined: 22 Apr 2005 17:40
Location: France 87

#7 Post by jpc » 21 Feb 2007 12:53

in addition , once i get this problem , i change back to 30F4013 , recompile is ok. next change back to 30F3012 and even at normal build the same errors

User avatar
srdjan
mikroElektronika team
Posts: 1552
Joined: 28 Dec 2005 12:47
Location: Serbia

#8 Post by srdjan » 21 Feb 2007 13:13

Your problem is explained in my first post.
When you click build all button, compiler tries to rebuild all libraries listed into mcu def file for which it finds sources. Among them there is lcd8 setup file. This file, however has to be changed for dspic3012 since it hasn't got portf, or it needs to be excluded from the list when build all is done.
If we would have different setup files for each mcu it would be very frustration and hard for maintainance.
But, we'll see for the next release to change build all option to rebuild all project related files except libraries.

Post Reply

Return to “mikroPascal Beta testing”