Lib for PIC16

  • SudFab

    SudFab - 2004-11-28


    I just install Windows SDCC on W2K OS :

    SDCC : mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08 2.4.7 #891 (Nov 27 2004) (MI

    I followed the test reommandation in SDCCMAN Rev 1.108.

    The target I plan to work on is PIC18F242.

    Compiler works fine and generate all the expected files :
    sdcc -mpic16 -p18f242 -c main.c

    But the linker seems to not be able to find the lib files, and with reason because there are no pic18fxxxx.lib files by default :
    sdcc -mpic16 -p18f242 main.c
    Processor: 18f242
    crt0i.o: No such file or directory

    I guess I need to build the lib for the pic revision I want to work with.

    Can you provide basic informations to start in that direction ?

    Thanks and best regards,

    • Weston T. Schmidt


      I'm not sure how this works on windows, but I had a similar problem using Linux.

      1) Make sure you have gputils installed.
      2) I had to go into the sdcc/device/lib/pic16 directory & compile this directory & then copy the contents of the sdc/device/lib/pic16/bin directory into the appropriate library location (depends on your install).
      3) I had to copy the sdcc/device/include/pic16 direcory into the appropriate include location (depends on your install).

      After this I had no problems using the command line:
      sdcc -mpic -p18f452 main.c

      Hope this helps.

      • SudFab

        SudFab - 2004-12-20

        Hi Wes,

        Damned, Windows package does not include the device folder !
        So, I will install cygwin and use the linux distrib, it will be easier for the next.

        Linux tool are usefull for compilers tools :)
        Thanks for your help.



Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks