pic16F88 problems


Closed Thread
Results 1 to 12 of 12

Hybrid View

  1. #1
    sskeet's Avatar
    sskeet Guest

    Default pic16F88 problems

    Hi, I have had success testing other chips, but this 16F88 is driving me crazy...I have read all over this forum and google and cannot find out why...

    First off, I have 5v power and ground hooked up correctly and have MCLR pullup attached. I am using picbasic pro 2.46 and EPIC programmer.

    I am just trying to verify that I can do simple I/O before heading into my project, but when I test my blink program, no matter what I set the PAUSE to, the LED just flickers like crazy and sometimes very randomly...

    Here is my code:
    ----------------------------
    @ DEVICE INTRC_OSC, LVP_OFF, WDT_OFF, MCLR_OFF

    DEFINE OSC 8

    OSCCON = %01110000 ' INTRC = 8MHz

    Pause 500 ' Wait for startup

    loop:

    LOW PORTB.4
    Pause 5000 ' Wait 5 second

    HIGH PORTB.4
    Pause 5000 ' Wait 5 second
    Goto loop ' Do it forever

    END
    ------------------------------

    The input voltage is stable, and I have 2 16f88 chips, so it is not a bad chip.

    Thanks!

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    sskeet, What are your settings when programming the micro? Do you have the OSC setting set for INTOSC? Check the settings when programming the chip as these will override the source code settings. HTH

    Dave Purola,
    N8NTA

  3. #3
    sskeet's Avatar
    sskeet Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Dave
    sskeet, What are your settings when programming the micro? Do you have the OSC setting set for INTOSC? Check the settings when programming the chip as these will override the source code settings. HTH

    Dave Purola,
    N8NTA
    You mean the Oscillator setting in EPIC? It is set to INTRC.

    I have tried both INTRC and INTRC (Clockout) and both give the same results. It must be something else I am not declaring in the startup of the code???

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


    Did you find this post helpful? Yes | No

    Default

    Your code is fine. Under the Options menu in the EPIC software, make sure you have Update Configuration & Reread File Before Programming checked.

    These options force the EPIC software to load & use config fuse settings embedded in your code, and always open/use the latest version of your .hex file.
    Regards,

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

  5. #5
    sskeet's Avatar
    sskeet Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Bruce
    Your code is fine. Under the Options menu in the EPIC software, make sure you have Update Configuration & Reread File Before Programming checked.

    These options force the EPIC software to load & use config fuse settings embedded in your code, and always open/use the latest version of your .hex file.
    I do not have the stuff in front of me right now, but I do have the software installed here at work, and I just checked the default settings in EPIC and Update Configuration is checked by default, but Reread File Before Programming is not. However, if I were to close EPIC and recompile, then reload EPIC, wouldnt that do the same thing? Because thats what I was doing every time anyway.

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


    Did you find this post helpful? Yes | No

    Default

    If your settings are the same at home, and it is loading & using config word settings in your .hex file, then i would have to suspect something in your circuit since your code posted as-is above works just fine.
    Regards,

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

Similar Threads

  1. Problems with 1-Wire DS2438 and PIC16F88
    By HeadCase in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 4th February 2011, 18:51
  2. RX TX modules - intermitent communication
    By ruijc in forum mel PIC BASIC Pro
    Replies: 13
    Last Post: - 11th June 2009, 00:13
  3. Replies: 8
    Last Post: - 7th December 2006, 15:42
  4. PIC16F88 problem with TOGGLE command?
    By russman613 in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 17th September 2006, 23:31
  5. Problems getting started
    By damiko in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 10th July 2005, 15:53

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