PIC12f683 example code

Discussion in 'Embedded Systems and Microcontrollers' started by Man_in_UK, Jun 12, 2008.

  1. Man_in_UK

    Man_in_UK Thread Starter Active Member

    Joined:
    May 13, 2008
    Messages:
    116
    Can anyone point me in the direct of, or supply me with some very simple code for one of these ?

    Any samples or projects will do.



    I have not programmed in a long time and it would help a lot to see how others have set up ports etc. Rather than ask someone to write my program I want to try and work it out myself.

    Cheers
  2. RiJoRI

    RiJoRI Well-Known Member

    Joined:
    Aug 15, 2007
    Messages:
    536
    Location:
    Long Island,NY (GMT-5)
    Do you have uChip's free MPLAB IDE? check www.microchip.com. It comes with a tutorial, or so they claim.

    PICs are somewhat different from the "normal" chips like the 8051, 68HCxxx, Z80, etc.

    --Rich
  3. SgtWookie

    SgtWookie Expert

    Joined:
    Jul 17, 2007
    Messages:
    22,093
    Location:
    In the vast midwest of the USA; CST
    The PICkit 1 comes with a PIC12F675 already programmed with sample code (that needed some work to make all 12 LED's flash, but I digress..)

    There are a number of sample programs provided on the CDs that comes with the PICkit 1; a mixture of C and assembler.

    Basically, evaluation of what programs will work with which uC's are up to you to decide; you need to be aware of the capabilities of your particular uC. I have not looked at the datasheet for yours.
  4. nanovate

    nanovate Well-Known Member

    Joined:
    May 7, 2007
    Messages:
    665
    Location:
    USA
    Here is a link that might be useful:
    http://www.microchipc.com/sourcecode/

    Different compilers have different ways to configure the chips so if you use a diff compiler then look at it's documentation carefully.
  5. Man_in_UK

    Man_in_UK Thread Starter Active Member

    Joined:
    May 13, 2008
    Messages:
    116
    Thanks for your suggestions.

    I think I will move to the 675 as I can get the starter board and start proding about straight away.

    Even in the sourcecode section of the mchip website there is nothing written to drop straight into a 12f series. I guess the space saving over an 8 pin package compared to a 16 is such a non-event everyone goes for the big version(I call it big, we know its not).

    If you got anything on paper for a 12f675 please send it this way.
Similar Threads
Forum Title Date
Embedded Systems and Microcontrollers PIC12F683 PWM Problem Jun 19, 2014
Embedded Systems and Microcontrollers PIC12f683 stops at the first statement of if condition Feb 10, 2014
Embedded Systems and Microcontrollers PIC12F683 question Nov 18, 2012
Embedded Systems and Microcontrollers Help with setting up ADC and pic12f683 code Jun 17, 2011
Embedded Systems and Microcontrollers Help programming a pic12f683 in assembly Jun 2, 2011

Share This Page