+ Reply to Thread
Results 1 to 2 of 2

Thread: Visual Initializer

  1. #1
    YAN-1 Bad
    Join Date
    May 2005
    Location
    Jordan
    Posts
    203

    Default Visual Initializer

    Hello everyone. I am using the C30 compiler for the first time and I'm trying to program the dsPIC30F2010 for a project I have and to configure it using the Visual Initializer. I read the help documentation for the Visual Initializer available with MPLAB and things seem to be clear. However, I can't get it to include the visual initialization code generated into my project. After I initialized the ports like I want, I chose 'Generate code' and then saved the code to my project and so MPLAB added the generated code and its relevant header files automatically. I also included the p30f2010.h header file and the p30f2010.gld linker file in the project. My very simple c code so far is test.c and it is:



    #include <p30f2010.h>



    int main(void){



    VisualInitialization();



    }





    However, when I try to build the project, I get the following errors:



    init_dsPIC30F2010.s: Assembler messages:
    init_dsPIC30F2010.s:4: Error: Can't open p30F2010.inc for reading.
    init_dsPIC30F2010.s:4: p30F2010.inc: No such file or directory
    init_dsPIC30F2010.s:21: Error: Invalid mnemonic: 'config'
    init_dsPIC30F2010.s:24: Error: Invalid mnemonic: 'config'
    init_dsPIC30F2010.s:29: Error: Invalid mnemonic: 'config'



    The last 3 errors point inside the generated code file (init_dsPIC30F2010.s)



    Please advice me as to how to properly include my visual initialization in my project. Your help is much appreciated.



    Nichola V. Abdo
    World.......behold........YAN is coming


  2. #2
    kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent kchriste Excellent
    Join Date
    Jul 2006
    Location
    Victoria BC, Canada
    Posts
    3,681

    Default

    Find p30F2010.inc on you computer. The easiest thing to do is copy it to your project directory.
    The proper thing to do is tell the compiler where to find the include files. In MPLAB it should be under Project/Set Language Tool Locations Then you have to find the C30 compiler and set the default directories to search.

+ Reply to Thread

Tags for this Thread