what's wrong with this interrupt


Results 1 to 7 of 7

Threaded View

  1. #5
    micro's Avatar
    micro Guest


    Did you find this post helpful? Yes | No

    Default

    i solved the problem with another method as below


    trisa=%00000
    trisb=%11111111

    option_reg=%10000000
    intcon = %10001000
    I var byte

    on interrupt goto int

    main:
    back: if portb<>0 then intcon=%10001000 ; test bit 3
    serout porta.0,2,[254,1]
    pause 10
    serout porta.0,2,["Hello"]
    pause 100
    goto main

    disable interrupt

    int:

    for i=0 to 5

    serout porta.0,2,[254,1]
    pause 10
    serout porta.0,2,[#i]
    pause 1000

    next i

    INTCON=%10000000 ; cleared bit 3 bit
    goto back ; back to test
    resume
    enable interrupt
    end


    i will read document, thank u for that, and waiting a reply from Mister_e
    Last edited by micro; - 2nd February 2006 at 21:53.

Similar Threads

  1. Won't go back to SLEEP after 1st Interrupt
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 32
    Last Post: - 29th June 2009, 09:00
  2. Can't ID interrupt source with this IntHandler??
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 3rd June 2009, 02:35
  3. Help with Analog Interrupt
    By brid0030 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 13th February 2008, 18:14
  4. NEWBIE: Some basic questions using interrupts
    By JackPollack in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 8th March 2006, 02:59
  5. USART interrupt not interrupting right
    By Morpheus in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 6th March 2005, 01:07

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