16f876a


Closed Thread
Results 1 to 5 of 5

Thread: 16f876a

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Location
    Mentor, Ohio
    Posts
    352


    Did you find this post helpful? Yes | No

    Smile

    Hi Dan,

    If you've read this forum enough you should see that guessing at how a program works or doesn't work doesn't do you or us any good and you are just wasting time. How about giving us something to work with like a listing of the code you are trying to run for starters. Also perhaps a schematic of how you have hooked up your test circuits to the PIC. Maybe then we can help you.

    BobK

  2. #2
    DanS.'s Avatar
    DanS. Guest


    Did you find this post helpful? Yes | No

    Default

    Bob,
    Thanks for the responce. I was starting out with a curiosity about possible known issues with the 876A and PBP / U2 programmer? Sorry for the vague question.

    The source shown here is a stripped out version to test basic function of the circuit and compiler.

    10meg osc is doing it's job. Power is clean @ 5V. Been over the hardware and PCB layout and is error free.

    I can flash the LED if I remove the if tpin test. With the IF Then, the thing seems dead!

    '''''''''''''hardware setup''''''''''''''''''''''
    @ device pic16f876a, debug_off, hs_osc, wdt_off, pwrt_on, bod_off, protect_off
    CMCON = 7 'disable adcs, porta = digital
    define osc 10 'external clock 20 mhz '''

    '''''''''''''''''''''''port setup''''''''''''''''''''''
    TRISA.0 = 1
    TRISA.1 = 1
    TRISA.2 = 1
    TRISB.0 = 0
    TRISB.1 = 0
    TRISB.2 = 0
    TRISB.3 = 0
    TRISB.4 = 0
    TRISB.5 = 0
    TRISB.6 = 1
    TRISB.7 = 1
    TRISC.0 = 1
    TRISC.1 = 1
    TRISC.2 = 1
    TRISC.3 = 1
    TRISC.4 = 1

    '''''''''''''''''define''''''''''''''''''''''''
    z1_relay VAR PORTB.0
    z2_relay VAR PORTB.1
    z3_relay VAR PORTB.2
    z4_relay VAR PORTB.3
    z5_relay VAR PORTB.4
    z6_relay VAR PORTB.5
    z1_read VAR PORTB.6
    z2_read VAR PORTB.7
    z3_read VAR PORTC.3
    z4_read VAR PORTC.2
    z5_read VAR PORTC.1
    z6_read VAR PORTC.0
    stat_led VAR PORTC.4
    'conn40 var PORTA.0
    conn41 var PORTA.1
    conn42 var PORTA.2
    lcd_tx var PORTC.6
    serial_rx var PORTC.7
    tpin var PORTA.0
    '''''''''''''''reg defines''''''''''''''''''''''''
    i var byte
    therm_status var byte
    'therm_calc1 var byte
    'therm_calc2 var byte
    'water_temp var byte
    'cyc_count var word
    'ondelay_1 var BYTE
    'ondelay_2 var word
    'therm_result var byte
    'suspend var Byte
    '''''''''''''''''''''''''''''''''''''''''''''''''' '

    main:
    if tpin = 0 then main
    low stat_led
    pause 500
    high stat_led
    pause 500
    goto main
    end

Similar Threads

  1. Problem with 16F877A but not with 16F876A
    By savnik in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 16th May 2008, 15:18
  2. 16f876a Pwm
    By Hainkm in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 30th December 2007, 18:33
  3. 16F876A Configuration
    By RFEFX in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 29th November 2006, 19:30
  4. Pwm 16f876a
    By DynamoBen in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 19th September 2006, 07:35
  5. EPIC Programmer - Works for all chips but the 16F876A
    By 4Lewis in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 13th April 2006, 00:59

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