1. 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.
    Dismiss Notice

Funny thing's happening with the mplab MCC

Discussion in 'Microcontrollers' started by be80be, Jul 16, 2017.

  1. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,830
    Likes:
    138
    Location:
    morristown,tn
    ONLINE
    I been playing with MCC and the 16lf18325 I load the hex and reset chip nothing happens I power off the chip and the code runs.
    Has anyone had this happen using the IPE and a pickit3.
    I'd post code but code works. Something is holding the chip in reset somehow .
     
  2. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,251
    Likes:
    911
    Location:
    Rochdale UK
    Is your code in debug mode... I think the pic is waiting to single step..
     
  3. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,830
    Likes:
    138
    Location:
    morristown,tn
    ONLINE
    Now If I could figure this out I be happy lol
    Code (text):

    CLEAN SUCCESSFUL (total time: 221ms)
    make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
    make[1]: Entering directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    make  -f nbproject/Makefile-default.mk dist/default/production/UART_Test.X.production.hex
    make[2]: Entering directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/mcc_generated_files/mcc.p1  mcc_generated_files/mcc.c
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/mcc_generated_files/interrupt_manager.p1  mcc_generated_files/interrupt_manager.c
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/mcc_generated_files/pin_manager.p1  mcc_generated_files/pin_manager.c
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/mcc_generated_files/eusart.p1  mcc_generated_files/eusart.c
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/main.p1  main.c
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe" --pass1  --chip=16LF18325 -Q -G  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib   --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"    -obuild/default/production/UART_Demo.p1  UART_Demo.c
    main.c:55: warning: (361) function declared implicit int
    main.c:75: warning: (361) function declared implicit int
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe"  --chip=16LF18325 -G -mdist/default/production/UART_Test.X.production.map  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"      --memorysummary dist/default/production/memoryfile.xml -odist/default/production/UART_Test.X.production.elf  build/default/production/mcc_generated_files/eusart.p1 build/default/production/mcc_generated_files/pin_manager.p1 build/default/production/mcc_generated_files/mcc.p1 build/default/production/mcc_generated_files/interrupt_manager.p1 build/default/production/main.p1 build/default/production/UART_Demo.p1  
    Microchip MPLAB XC8 C Compiler (Free Mode) V1.42
    Build date: Apr 12 2017
    Part Support Version: 1.42
    Copyright (C) 2017 Microchip Technology Inc.
    License type: Node Configuration

    :: warning: (1273) Omniscient Code Generation not available in Free mode
    UART_Demo.c:9: error: (1098) conflicting declarations for variable "_UART_Demo_Initialize" (main.c:55)
    (908) exit status = 1
    nbproject/Makefile-default.mk:211: recipe for target 'dist/default/production/UART_Test.X.production.hex' failed
    make[2]: Leaving directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    nbproject/Makefile-default.mk:90: recipe for target '.build-conf' failed
    make[1]: Leaving directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
    make[2]: *** [dist/default/production/UART_Test.X.production.hex] Error 1
    make[1]: *** [.build-conf] Error 2
    make: *** [.build-impl] Error 2

    BUILD FAILED (exit value 2, total time: 3s)
     
    I added the whole project.
    So whats happening is my Uart_Demo.c is not being found
     

    Attached Files:

    Last edited: Jul 16, 2017
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,251
    Likes:
    911
    Location:
    Rochdale UK

    I can see this function:- UART_Demo_Initialize(); And this in the UART_demo.c :- void UART_Demo_Initialize(void);

    But there isn't a definition in the mcc.h... Copy void UART_Demo_Initialize(void); into mcc.h and it should see it!
     
  6. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,830
    Likes:
    138
    Location:
    morristown,tn
    ONLINE
    I tried that i'm down to one error I think
    Code (text):

    main.c:75: warning: (361) function declared implicit int
    "C:\Program Files\Microchip\xc8\v1.42\bin\xc8.exe"  --chip=16LF18325 -G -mdist/default/production/UART_Test.X.production.map  --double=24 --float=24 --opt=+asm,+asmfile,-speed,+space,-debug,-local --addrqual=ignore --mode=free -P -N255 --warn=-3 --asmlist -DXPRJ_default=default  --summary=default,-psect,-class,+mem,-hex,-file --output=default,-inhx032 --runtime=default,+clear,+init,-keep,-no_startup,-osccal,-resetbits,-download,-stackcall,+clib --output=-mcof,+elf:multilocs --stack=compiled:auto:auto "--errformat=%f:%l: error: (%n) %s" "--warnformat=%f:%l: warning: (%n) %s" "--msgformat=%f:%l: advisory: (%n) %s"      --memorysummary dist/default/production/memoryfile.xml -odist/default/production/UART_Test.X.production.elf  build/default/production/mcc_generated_files/eusart.p1 build/default/production/mcc_generated_files/pin_manager.p1 build/default/production/mcc_generated_files/mcc.p1 build/default/production/mcc_generated_files/interrupt_manager.p1 build/default/production/main.p1 build/default/production/UART_Demo.p1    
    Microchip MPLAB XC8 C Compiler (Free Mode) V1.42
    Build date: Apr 12 2017
    Part Support Version: 1.42
    Copyright (C) 2017 Microchip Technology Inc.
    License type: Node Configuration

    :: warning: (1273) Omniscient Code Generation not available in Free mode
    UART_Demo.c:14: error: (1098) conflicting declarations for variable "_UART_Demo_Command_INT" (main.c:75)
    (908) exit status = 1
    nbproject/Makefile-default.mk:211: recipe for target 'dist/default/production/UART_Test.X.production.hex' failed
    make[2]: Leaving directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    make[2]: *** [dist/default/production/UART_Test.X.production.hex] Error 1
    make[1]: *** [.build-conf] Error 2
    make: *** [.build-impl] Error 2
    nbproject/Makefile-default.mk:90: recipe for target '.build-conf' failed
    make[1]: Leaving directory 'C:/Users/USER/Desktop/proj12/UART_Test.X'
    nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed

    BUILD FAILED (exit value 2, total time: 6s)
     
     

    Attached Files:

  7. Ian Rogers

    Ian Rogers Super Moderator Most Helpful Member

    Joined:
    Mar 28, 2011
    Messages:
    9,251
    Likes:
    911
    Location:
    Rochdale UK
    Same error again, but with "_UART_Demo_Command_INT"

    Both these are in the same file...
     
  8. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,830
    Likes:
    138
    Location:
    morristown,tn
    ONLINE
    I read that this is a problem with xc8 1.42 because I added it like you said and it still doing the same thing.
     

Share This Page