PIC16F685 RA4/RA5 pins


Closed Thread
Results 1 to 17 of 17

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    I think you may be confusing MicroCode Studio editor with your programmers software.

    I'm sure you selected something like meProg software Options, More Options, then
    Set Options to Defaults...
    , which reset programmer options. It most likely was not
    loading & using config settings embedded in your .HEX file.

    If you comment out all config options in your code, compile, then program, you'll see that
    all config options are at the default unprogrammed settings. This leaves /MCLR ON, sets
    the oscillator to external RC with clock out on OSC2, and produces exactly the same
    scenario you were seeing.

    I duplicated it exactly by doing the same thing here. Somewhere along the line you had
    changed your programmer settings to not use config settings in your .HEX file - or not
    program them.

    Check the attached graphic. I commented out the config statement in the example above,
    compiled, and launched the programmer. Check the config settings.

    The PIC is still going to run because there is no external RC clock, it assumes the external
    osc has failed, and switches over to the default internal 4MHz osc, and keeps going.

    But now you have Fosc/4 out on OSC2, and a ping signal on OSC1, which is the internal
    driver ping to tickle the external RC osc, which you don't have...;o}

    Check the diagram in the datasheet under RC OSCILLATOR MODE for a drawing of what's
    going on with these two pins when this osc mode is selected.
    Attached Images Attached Images  
    Last edited by Bruce; - 9th November 2008 at 14:21.
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  2. #2
    Join Date
    May 2007
    Location
    Suffolk, UK
    Posts
    59


    Did you find this post helpful? Yes | No

    Default

    Yes thanks Bruce. Slip of the tongue between Editor & Programmer. It was the Programmer I set back to default options. I guess I must have jiggered one of the default settings which as you say stopped it loading and using the embedded settings.

    Thanks for explanation of clock settings on the 16F684. I have looked up the datasheet and see exactly what you mean.

    It's a long and slippery road but a great learning curve..........

    Regards

    Adrian

Similar Threads

  1. Change On Interrupt, PIC16F884
    By elec_mech in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 14th November 2008, 17:25
  2. PIC - 8 Pins - 6 Output Pins ?
    By DanPBP in forum Off Topic
    Replies: 0
    Last Post: - 22nd October 2007, 00:23
  3. Why does this program switch pins?
    By Archangel in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 24th August 2006, 04:24
  4. I2C Effects on other PortA pins
    By kenmac in forum General
    Replies: 2
    Last Post: - 11th July 2005, 05:36
  5. PIC PORT 'special' pins
    By barkerben in forum General
    Replies: 1
    Last Post: - 18th January 2005, 21:40

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts