Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Including header file (plib.h) in MPLAB stops building it

Status
Not open for further replies.

shreyans

New Member
Hi am using MPLAB XIDE v2.26. I have created new project for PIC32mx3048ech144 which builds for main.c with only while(1). When I include plib.h header file it generates list of errors. The log is shown below:
code:

C:
#include<p32xxxx.h>
#include<plib.h>

//    Function Prototypes
int main(void);

int main(void) {
    while (1);
}

output:

Code:
CLEAN SUCCESSFUL (total time: 108ms)
make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'D:/Mcare'
make  -f nbproject/Makefile-default.mk dist/default/production/Mcare.production.hex
make[2]: Entering directory 'D:/Mcare'
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:45:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:49:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:45:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:61:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:63:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:65:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:68:5: error: #error "Device not supported by the interrupt peripheral library"
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:76:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:45,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/legacy/int_legacy.h:47:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:45:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:99:58: error: '_INTCON_SS0_MASK' undeclared here (not in a function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h: In function 'INTGetInterruptVectorNumber':
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:527:38: error: '__INTSTATbits_t' has no member named 'VEC'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h: At top level:
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:45:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:634:30: error: expected ')' before 'source'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:664:28: error: expected ')' before 'source'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:697:36: error: expected ')' before 'source'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:727:27: error: expected ')' before 'source'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:760:38: error: expected ')' before 'source'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:790:38: error: expected ')' before 'vector'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:821:46: error: expected ')' before 'vector'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:851:41: error: expected ')' before 'vector'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/int.h:882:53: error: expected ')' before 'vector'
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:49:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:54:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:297:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:313:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/adc10.h:371:7: error: token ""EC"" is not valid in preprocessor expressions
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:50:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/bmx.h:51:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:51:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/cmp.h:52:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:52:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/cvref.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:53:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/dma.h:46:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/dma.h:50:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/dma.h:53:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/dma.h:55:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/dma.h:58:5: error: #error "Device not supported by the DMA peripheral library"
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:54:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/i2c.h:59:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/i2c.h:64:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:54,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/legacy/i2c_legacy.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:55:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/incap.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:57:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/nvm.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:58:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/outcompare.h:54:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:59:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pcache.h:50:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:60:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pmp.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:46:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:61,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/SPI_Port_Mappings.h:11:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:47:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:61,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/Ethernet_Port_Mappings.h:11:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:61:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:56:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:299:11: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:307:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:338:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:380:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:518:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:523:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:539:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:567:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:640:11: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:682:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:847:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:855:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:893:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:901:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:939:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:944:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:978:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:1017:9: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:1154:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/ports.h:1196:9: error: token ""EC"" is not valid in preprocessor expressions
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:62:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pps.h:13:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pps.h:31:11: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pps.h:103:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pps.h:239:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/pps.h:320:8: error: token ""EC"" is not valid in preprocessor expressions
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:63:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/power.h:52:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/reset.h:45:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:64,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/lock.h:47:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:64:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/reset.h:54:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:65:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/rtcc.h:51:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:66:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/spi.h:50:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/spi.h:54:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/spi.h:56:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/spi.h:58:10: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/spi.h:61:5: error: #error "Device not supported by the SPI peripheral library"
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:58:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:67,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:53:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:58:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:67,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:134:8: error: token ""EC"" is not valid in preprocessor expressions
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h: In function 'OSCSetPBDIV':
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:188:9: error: '__OSCCONbits_t' has no member named 'w'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:189:9: error: '__OSCCONbits_t' has no member named 'PBDIV'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:190:9: error: '__OSCCONbits_t' has no member named 'w'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:191:16: error: '__OSCCONbits_t' has no member named 'w'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/osc.h:192:9: error: '__OSCCONbits_t' has no member named 'w'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h: At top level:
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:67:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:74:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h: In function 'SYSTEMConfigPB':
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:130:16: error: '_OSCCON_PBDIV_POSITION' undeclared (first use in this function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:130:16: note: each undeclared identifier is reported only once for each function it appears in
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h: In function 'SYSTEMConfigPerformance':
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:295:5: error: 'BMXCONCLR' undeclared (first use in this function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:295:5: error: '_BMXCON_BMXWSDRM_MASK' undeclared (first use in this function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h: In function 'SYSTEMConfig':
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:356:5: error: 'BMXCONCLR' undeclared (first use in this function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:356:5: error: '_BMXCON_BMXWSDRM_MASK' undeclared (first use in this function)
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/system.h:380:26: error: '__OSCCONbits_t' has no member named 'PBDIV'
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/timer.h: At top level:
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:68:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/timer.h:52:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/uart.h:59:0,
                 from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:69,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/legacy/uart_legacy.h:49:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:69:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/uart.h:74:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:71:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/eth.h:59:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
In file included from c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/plib.h:72:0,
                 from main.c:37:
c:\program files (x86)\microchip\xc32\v1.32\bin\bin\../../lib/gcc/pic32mx/4.5.2/../../../../pic32mx/include/peripheral/CAN.h:60:2: warning: #warning The PLIB functions and macros in this file will be removed from the MPLAB XC32 C/C++ Compiler in future releases
make[2]: *** [build/default/production/main.o] Error 1
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2
"C:\Program Files (x86)\Microchip\xc32\v1.32\bin\xc32-gcc.exe" -g -x c -c -mprocessor=32MZ2048ECH144 -MMD -MF build/default/production/main.o.d -o build/default/production/main.o main.c
nbproject/Makefile-default.mk:105: recipe for target 'build/default/production/main.o' failed
make[2]: Leaving directory 'D:/Mcare'
nbproject/Makefile-default.mk:78: recipe for target '.build-conf' failed
make[1]: Leaving directory 'D:/Mcare'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed

BUILD FAILED (exit value 2, total time: 1s)
 
Last edited by a moderator:
Don't include it then!

Mike.
If only it were that simple..

Welcome to Harmony!!!!! The old peripheral library was from mplab c32... XC32 and XC32++ would prefer you to use harmony... Same thing but automated.. Harmony incudes access to ALL libraries for pic32... Trouble here is.... I am pretty conversant in C/C++ and it scares the hell out of me...

My advise!! While you get a grip on this micro... Use MPLAB C32 compiler... Once you are very familiar only then cross over to XC32 and harmony!!!
 
So guys if i want to use this f... pic32 instead of using harmony which version of c32 or xc32 compiler do you suggest???
 
So guys if i want to use this f... pic32 instead of using harmony which version of c32 or xc32 compiler do you suggest???
Again... The archive pages at Microchip only have "updates" for the old technology... Unless you get a hold of a "free" version you won't be able to use it..
It isn't worth it to Microchip to keep it going...

Personally! I would search the internet for source code and build your own (better) library.. What libraries do you need.... If you have the PeripheralLIB you can convert the code you need... I'm assuming you have the code??
 
I came from pic16f programming and just want to start using this new toy, I'm not so good to build my own lib I just saw that there is a lot more of examples and tutorials using this plib and I would like to know what you think is the best tools to do it in classic programming way. THX A LOT FOR REPLY
 
Thx i will check! Meanwhile I find out my the problem on installing plib (problem was the installing directory default on v1.40 xc32 compiler folder, i had to change it on my version 2...) after that build end successfully with just some* "warning" message about plib... uploaded on device (I'm using uc32 from chipkit) and blink program work!! Anyway I still have error message on the code for SYSTEMCONFIG, TRIS register set or LATbit write even if the code is working plus when I debug on simulator and check pins it change in out configuration but still 0 until I stop the debug, than become 1 and don't change again, it seems to work very slowly and not well
 
Hello, I do not use harmony and I have the same compiling problem. Can you tell how can I fix this error? (I use 32mx546F064)
 

Attachments

  • asdf.png
    asdf.png
    142.2 KB · Views: 359
Actually the problem is related to <peripheral/adc10.h> missing and I cannot find it, besides I downloaded the legacy peripheral library put there but I still have the same problem
 
Last edited:
You can use the PLIB the problem I had was when I installed the Plib it installed to the wrong place So xc32 couldn't use it cause it couldn't be found I copy it to the same place 1.40 had over to 1.43 and it worked

We are now at 2.40 I have not tried using it with that but I about bet it's the same thing move my copy from 1.40 to 2.40
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top