• AVR Freaks

Hot!PIC18F assembler errors recently appeared - error [118], message [303], error [154]

Page: 123 > Showing page 1 of 3
Author
Graham55
New Member
  • Total Posts : 12
  • Reward points : 0
  • Joined: 2017/07/26 12:35:05
  • Location: 0
  • Status: offline
2018/06/25 00:29:00 (permalink)
0

PIC18F assembler errors recently appeared - error [118], message [303], error [154]

At some point since its last correct operation on March 12th 2018, the assembler in my MPLAB IDE has stopped working on PIC18F2420 and PIC18F1220 devices, and comes up with close variations of this type of error message:
 
Executing: "C:\Program Files (x86)\Microchip\MPASM Suite\MPASMWIN.exe" /q /p18F1220 "proc_2420.asm" /l"proc_2420.lst" /e"proc_2420.err"
Message[303] C:\BACKUP\TEST18F\PROC_2420.ASM 2 : Program word too large. Truncated to core size. (00A61870)
Error[154] C:\BACKUP\TEST18F\PROC_2420.ASM 2 : Each object file section must be contiguous (section .config_000000_PROC_2420.O)
Error[118] C:\BACKUP\TEST18F\PROC_2420.ASM 2 : Overwriting previous address contents (0000)
Error[118] C:\BACKUP\TEST18F\PROC_2420.ASM 2 : Overwriting previous address contents (0001)
Halting build on first failure as requested.

 
I reduced the input file to the bare minimum to create this:
 
   INCLUDE p18f1220.inc
   END

 
.. but it makes no difference - code I know to be valid results in a similar string of errors.
 
I've looked back over various threads since 2009, and this seems to be a recurring problem affecting all PIC18 devices at a stroke.  Suggestions are that conflicts with other programs are the problem, but the only things which have changed on my PC since March 12th are a handful of automatic Windows updates (security and .NET patches), which I'm in the process of uninstalling as I write this to see if it resolves the issue.
 
I'd hoped that in the 9 years since it was first reported, Microchip would have solved this problem, but it seems not to be the case.  The only "fix" I've found is to re-install the OS ... which is rather drastic, and something I really want to avoid if I can.
 
Here are the details of my install: Windows 7, 64bit, SP1. MPLAB v8.92 - these haven't changed for a long while.  I'd appreciate any help on resolving this issue as soon as possible.
#1

49 Replies Related Threads

    DarioG
    Allmächtig.
    • Total Posts : 54081
    • Reward points : 0
    • Joined: 2006/02/25 08:58:22
    • Location: Oesterreich
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 01:44:47 (permalink)
    0
    I would believe that the project has switched from absolute to relative (relocatable) mode, but am not sure-sure: still it was happening, if there were no explicit setting before an upgrade of the tools.

    GENOVA :D :D ! GODO
    #2
    Graham55
    New Member
    • Total Posts : 12
    • Reward points : 0
    • Joined: 2017/07/26 12:35:05
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 04:31:50 (permalink)
    +1 (1)
    Thanks for your idea DarioG, but I haven't changed any settings ... and in any case, I wouldn't know how to do that! But you can't have the assembler overwriting existing code with there's no code to assemble, as in the example I gave above. Not only that, but code specified for PIC12 devices still assembles properly. It's all far too much like the fault reported by other people over the past few years to be a co-incidence!
     
    Sadly, my idea of removing the recent Windows upgrades didn't solve the problem either ... sad
    #3
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 04:52:21 (permalink)
    +1 (1)
    • Try starting a new project with the same .asm file.
    • Try reinstalling your MPLAB v8.92.
     
    #4
    Graham55
    New Member
    • Total Posts : 12
    • Reward points : 0
    • Joined: 2017/07/26 12:35:05
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 07:57:26 (permalink)
    0
    No luck, 1and0. I didn't really expect it to ... previous threads have said it wouldn't solve the problem.
     
    The more I investigated this, the more it struck me as odd that Microchip wouldn't fix a years-long persistent fault rendering their software useless for pretty-much their entire range of top-end products! Now I realise that they've given up developing it (and fixing it's faults) in favour of MPLAB X IDE, which, being open-source, is likely to be far more responsive to any problems which crop up. Cop-out, or wise move? I'd be interested to know the history. I'm currently waiting for the X version to finish downloading, then I'll install it and see if it works ...
    #5
    DarioG
    Allmächtig.
    • Total Posts : 54081
    • Reward points : 0
    • Joined: 2006/02/25 08:58:22
    • Location: Oesterreich
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 08:06:50 (permalink)
    0
    most open source is based on java, making it crap-source :D from the beginning, so...

    GENOVA :D :D ! GODO
    #6
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 09:00:20 (permalink)
    +2 (2)
    Graham55
    No luck, 1and0. I didn't really expect it to ... previous threads have said it wouldn't solve the problem.

    Where are those threads?  Sorry that I cannot help any more; I've tried to reproduce your error messages but failed.
     
     
    The more I investigated this, the more it struck me as odd that Microchip wouldn't fix a years-long persistent fault rendering their software useless for pretty-much their entire range of top-end products! 

    Haha, this forum still has bugs that go back four or more years. :(
     

    Now I realise that they've given up developing it (and fixing it's faults) in favour of MPLAB X IDE, which, being open-source, is likely to be far more responsive to any problems which crop up. Cop-out, or wise move? I'd be interested to know the history. I'm currently waiting for the X version to finish downloading, then I'll install it and see if it works ...

    MPLAB X is still full of bugs many years later.  I prefer using MPLAB 8 whenever I can.
     
    #7
    Graham55
    New Member
    • Total Posts : 12
    • Reward points : 0
    • Joined: 2017/07/26 12:35:05
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 09:02:12 (permalink)
    0 (2)
    You're right - it's a complete pile of crap.  The screen is far too busy, it's way too slow doing pretty-much everything ... and worst of all, it doesn't f***ing work!  It gives the same non-sensical error messages as the original MPLAB IDE 8.92.
     
    So the question now is where to go from here.  I have two assemblers, and neither will work on PIC18s.  What a total screw-up.  Any suggestions???  I have a near-virgin XP machine which is isolated from the internet, and which I use for a handful of specific pieces of software which require USB peripherals that won't work in Windows 7. Will v8.92 work on XP?
    #8
    DarioG
    Allmächtig.
    • Total Posts : 54081
    • Reward points : 0
    • Joined: 2006/02/25 08:58:22
    • Location: Oesterreich
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 09:06:11 (permalink)
    +2 (2)
    yep, been using 8.92 on XP for years. also X 4.20 works on it :)

    GENOVA :D :D ! GODO
    #9
    Graham55
    New Member
    • Total Posts : 12
    • Reward points : 0
    • Joined: 2017/07/26 12:35:05
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 09:09:31 (permalink)
    0
    Oops - sorry 1and0, our posts crossed.  There are several instances of this issue being flagged in the past - enter "Each object file section must be contiguous" as a search phrase.
    #10
    Graham55
    New Member
    • Total Posts : 12
    • Reward points : 0
    • Joined: 2017/07/26 12:35:05
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 09:10:33 (permalink)
    +1 (1)
    Thanks DarioG - I might have to give it a try.
     
    #11
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 10:09:08 (permalink)
    +1 (1)
    Graham55
    There are several instances of this issue being flagged in the past - enter "Each object file section must be contiguous" as a search phrase.

    I did a search and read a few threads.  It looks like the issue is with the newer MPASMWIN.exe and Windows 7.  So, you can either try another Windows like XP or use an older MPASMWIN which is larger in size than the newer ones; e.g. MPASMWIN v5.37 is 11 MB, while the newer ones are less than 1 MB.
     
    <edit> MPASMWIN v5.51 that comes with MPLAB v8.92 is 949 KB, and v5.77 that comes with MPLAB X v4.15 is 962 KB.
    post edited by 1and0 - 2018/06/25 10:11:28
    #12
    Gort2015
    Klaatu Barada Nikto
    • Total Posts : 3510
    • Reward points : 0
    • Joined: 2015/04/30 10:49:57
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 11:00:18 (permalink)
    +1 (1)
    The errors are from the assembler not mplab or mplab x.
    It's more likely buggy code.
     
    List some code.

    MPLab X playing up, bug in your code? Nevermind, Star Trek:Discovery will be with us soon.
    https://www.youtube.com/watch?v=Iu1qa8N2ID0
    + ST:Continues, "What Ships are Made for", Q's back.
    #13
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 11:14:56 (permalink)
    0
    Gort2015
    The errors are from the assembler not mplab or mplab x.
    It's more likely buggy code.
     
    List some code.

    OP posted a two-liner in Post #1. ;)
     
    #14
    jack@kksound
    code tags!
    • Total Posts : 3222
    • Reward points : 0
    • Joined: 2014/05/14 10:03:19
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 12:19:19 (permalink)
    +1 (1)
    Appears to be a Windows 7 issue, not seeing this on XP or Win 10 here (don't have Win 7 to try).
    #15
    Gort2015
    Klaatu Barada Nikto
    • Total Posts : 3510
    • Reward points : 0
    • Joined: 2015/04/30 10:49:57
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 14:29:00 (permalink)
    +1 (1)
    This is a section of some old 8bit code.  With psect you can specify absolute or relative.
    Have a look at the assembler doc for 8bit.
    #include <xc.inc>
    ;----------------------------------------------------
    index macro i
    lfsr 0,_Song   ;index sfh->
    movlb i>>8
    movf i,w
    addwf FSR0L,c
    movlw 0
    addwfc FSR0H,c
    endm
    ;----------------------------------------------------
    GO_IDLE_STATE         equ 0
    SFH_Sample_BufferDone equ 1
    _Buffer               equ BufferL
    _R2                   equ _R1
    _cluster3             equ ClusterLWL
    ;----------------------------------------------------
    GLOBAL      _SFH,_SFH_Byte,_SFH_TMR,_SFH_BytesRemaining,_SFH_Flag,_buffer,_Buffer
    GLOBAL      _Song,_dbuf,_read_buffer,_R1,_R2
    GLOBAL _getCluster3,_cluster3,_fattype
    SIGNAT _getCluster3,4732
    SIGNAT _read_buffer,4217
    ;----------------------------------------------------
    PSECT bss0, local, class="RAM", space=1
    _DATA_LWORD:    ds 4
    Send_WREG_TMP:  ds 1
    _COM:           ds 1
    TMP:            ds 1
    Send_BSR_TMP:   ds 1
    BufferL:        ds 1
    BufferH:        ds 1
    WREG_TMP:       ds 1
    BSR_TMP:        ds 1
    FSR0L_TMP:      ds 1
    FSR0H_TMP:      ds 1
    INT_FSR0L_TMP:  ds 1
    INT_FSR0H_TMP:  ds 1
    cntL:           ds 1
    cntH:           ds 1
    ClusterLWL:     ds 1
    ClusterLWH:     ds 1
    ClusterHWL:     ds 1
    ClusterHWH:     ds 1
    _dbuf:          ds 1
    STATUS_TMP:     ds 1
    _R1:            ds 1
    R2H:            ds 1
    INT_cnt:        ds 1
    Sample:         ds 1
    _fattype:       ds 1
    posL:           ds 1
    posH:           ds 1
    ;----------------------------------------------------
    PSECT irqsection, local, class="CODE", abs, ovrld, delta=1, reloc=1
    org 0x0008  ;high priority interrupt
    goto _read_buffer
    ;----------------------------------------------------
    PSECT isrsection, local, class="CODE", delta=1
    _read_buffer:
    ;----------------------------------------------------
    movff FSR0L,INT_FSR0L_TMP  ;backup context registers
    movff FSR0H,INT_FSR0H_TMP
     
    etc...
     
    retfie f

    post edited by Gort2015 - 2018/06/25 14:35:36

    MPLab X playing up, bug in your code? Nevermind, Star Trek:Discovery will be with us soon.
    https://www.youtube.com/watch?v=Iu1qa8N2ID0
    + ST:Continues, "What Ships are Made for", Q's back.
    #16
    Gort2015
    Klaatu Barada Nikto
    • Total Posts : 3510
    • Reward points : 0
    • Joined: 2015/04/30 10:49:57
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 14:39:33 (permalink)
    0
    Windows 7, I've had that from day 1 when it first came out.
    Not sure but think I was using mplab.
     
    I just cannot see how that would make a difference.

    MPLab X playing up, bug in your code? Nevermind, Star Trek:Discovery will be with us soon.
    https://www.youtube.com/watch?v=Iu1qa8N2ID0
    + ST:Continues, "What Ships are Made for", Q's back.
    #17
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 14:40:44 (permalink)
    +1 (1)
    Gort2015
    This is a section of some old 8bit code.  With psect you can specify absolute or relative.
    Have a look at the assembler doc for 8bit.
    #include <xc.inc>


    OP is using MPASM, not ASPIC of XC8.
    #18
    1and0
    Access is Denied
    • Total Posts : 10225
    • Reward points : 0
    • Joined: 2007/05/06 12:03:20
    • Location: Harry's Gray Matter
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 14:43:24 (permalink)
    0
    Gort2015
    Windows 7, I've had that from day 1 when it first came out.
    Not sure but think I was using mplab.
     
    I just cannot see how that would make a difference.

    I used Win7 before too, but I never had such problem.  The threads I read seem to have Win7 as a common denominator, and the error messages pointed to the END directive. ???
    #19
    jack@kksound
    code tags!
    • Total Posts : 3222
    • Reward points : 0
    • Joined: 2014/05/14 10:03:19
    • Location: 0
    • Status: offline
    Re: PIC18F assembler errors recently appeared - error [118], message [303], error [154] 2018/06/25 14:57:50 (permalink)
    0
    Just because it worked before does not insure it will work again (worked on WIN 7 last time....). Things (files) get corrupted, get updated, sometimes without our knowing it happened and suddenly poof! nothing works right anymore. I suggest trying the whole mess on a different computer running a new install of MPASM/MPLAB, maybe even on a windows version that is NOT 7, just in case.
    #20
    Page: 123 > Showing page 1 of 3
    Jump to:
    © 2020 APG vNext Commercial Version 4.5