testing pic16f877a


Closed Thread
Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2006
    Posts
    747

    Default testing pic16f877a

    hello

    I am making a short program to test a pic16f877a. but I am getting 0v at the output.
    anyone knows why?
    it should show all pins at 5v

    thanks
    ken



    ' test pic
    INCLUDE "modedefs.bas"
    @ DEVICE PIC16F877a , HS_OSC , WDT_OFF , PWRT_ON , BOD_ON , LVP_OFF , PROTECT_OFF
    'HS 20mhz, watchdog off, powerup timer on, mclr external, brown out detect on, low volt program off , code protect off

    DEFINE OSC 20 'use external 20mhz crystal

    TRISA = %00000000 ' Set PORTA to all output
    TRISB = %00000000
    TRISC = %00000000
    TRISD = %00000000
    TRISE = %000

    Pause 1000 ' Wait 1 second

    Mainloop:

    PORTA=1
    PORTB=1
    PORTC=1
    PORTD=1
    PORTE=1

    Pause 5000 'pause
    goto Mainloop

    End

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    First off this will help
    http://www.picbasic.co.uk/forum/showthread.php?t=561

    Do any of the pins show 5 volt?
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default

    hey,

    none of the pins shows 5v
    oo except for Vdd ..hehe

    ken

  4. #4
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default

    I found the problem,
    I shifted the vdd nd vss pins, I could not see the hole next to the oscillator because of the big crystal. working now.

    Ken

  5. #5
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by lerameur View Post
    I shifted the vdd nd vss pins, I could not see the hole next to the oscillator because of the big crystal. working now.
    I'd keep an eye on that particular PIC, maybe mark it somehow as 'possibly damaged' in case it quits working in the future.
    I've put a few PICs in backwards here and there, over-volted them, 9v across a pin here and there. They always seem to work for awhile afterwards, a few have dead outputs on a few pins, nothing definitive, but you never know... Could come back to bite you in the rear end in the future...

Similar Threads

  1. Replies: 2
    Last Post: - 24th August 2008, 20:03
  2. Replies: 9
    Last Post: - 4th February 2008, 19:12
  3. communicating pic18f452 with pic16f877a
    By tamersoss in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 13th July 2007, 19:54
  4. Condition testing
    By jtburnham in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 30th August 2006, 10:02
  5. PIC16f877-20 to a PIC16f877A I/P Disaster
    By andyf in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 21st November 2005, 17:11

Members who have read this thread : 1

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