Instant Interrupts - Revisited


Closed Thread
Results 1 to 40 of 773

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    And all this with a minimum of efforts
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  2. #2
    Join Date
    Apr 2006
    Location
    New Hampshire USA
    Posts
    298


    Did you find this post helpful? Yes | No

    Post Instant interrupts PIC12F675 (12f675)

    For the record (partial pasted from other thread):
    Quote Originally Posted by wlundonly View Post
    Hi all, I've been trying to get Darrel Taylor's Instant interrupts to work with a 12f675 with no luck. Will they work with a 12f675?

    I just get the following error message when I try to compile it:

    ERROR: Variable wsave3 position request 416 beyond RAM_END 95.
    ERROR: Variable wsave2 position request 288 beyond RAM_END 95.
    ERROR: Variable wsave1 position request 160 beyond RAM_END 95.
    ERROR: Unable to fit variable RS2_Save
    <..snip...>
    Thanks for any help.

    Bill
    See Darrel’s solution:
    “To get Instant interrupts with Basic Language working on a 12F675 ...”
    Open the DT_INTS-14.bas file and comment out the wsave lines. The 675 doesn't have any usable RAM in banks 1,2 or 3
    Code:
    ' --- IF any of these three lines cause an error ?? ---------------------------- 
    '       Comment them out to fix the problem ----
    ' -- It depends on which Chip you are using, as to which variables are needed --
    ;wsave1      var byte    $A0     SYSTEM      ' location for W if in bank1
    ;wsave2      var byte    $120    SYSTEM      ' location for W if in bank2
    ;wsave3      var byte    $1A0    SYSTEM      ' location for W if in bank3
    ' ------------------------------------------------------------------------------
    Then in the ReEnterPBP.bas file comment the T?_save variables.
    Code:
    ;    T1_Save     VAR WORD
    ;    T2_Save     VAR WORD
    ;    T3_Save     VAR WORD
    ;    T4_Save     VAR WORD
    Just remember that if you use Instant Interrupts on a different chip later, you will need to un-comment those lines.
    HTH,
    __________________
    DT
    http://www.picbasic.co.uk/forum/show...9510#post49510
    Ohm it's not just a good idea... it's the LAW !

  3. #3
    Join Date
    Dec 2005
    Posts
    23


    Did you find this post helpful? Yes | No

    Post

    Hello all

    Today I play with " Instant Interrupts" thank's Darrel

    For to begin I use blinky program
    I want to augment the speed of blink light by loading a value
    in TMR1H and TMR1L but the speed does not change

    Rq:
    I want not to change the value of the prescaler


    code:

    '********************
    TMR1H = %11111111
    TMR1L = %11111110
    '********************

    1CON = %110001 ; Prescaler = 8, TMR1ON

    what is wrong please?

  4. #4
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by debutpic View Post
    I want to augment the speed of blink light by loading a value
    in TMR1H and TMR1L but the speed does not change

    code:

    '********************
    TMR1H = %11111111
    TMR1L = %11111110
    '********************
    Loading that value %1111111111111110 = $FFFE = 65534
    Means the timer will overflow after only 2 ticks.
    A smaller number would help.

    Also, it has to be loaded after every interrupt, not just at the beginning of the program.
    <br>
    DT

  5. #5
    Join Date
    Dec 2005
    Posts
    23


    Did you find this post helpful? Yes | No

    Default

    thank's Darrel

    Remark:

    In my next code if I load TMR1H with a high value code work fine

    Main:

    TMR1H = %11111111
    pause 1

    ----------------------------

    but if I reduce the value in TMR1H code don't work
    display is OFF

    Main:

    TMR1H = %10111111
    pause 1

    -------------------------------
    if I want use this value "TMR1H = %10111111"
    I must write "pause 20" and not "pause 1"

    an idea ???????

  6. #6
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    No, I have no idea what you are doing.
    If you're using a timer, why do you need pauses?

    What frequency are you trying to run the timer at?
    What frequency is your primary oscillator?
    What PIC are you using?
    <br>
    DT

  7. #7
    Join Date
    Dec 2005
    Posts
    23


    Did you find this post helpful? Yes | No

    Default

    I use one 16F877 MCU to 20 Mhz

    TMR1 produce an interrupt every 0,4 µSec
    for to drive four 7 segment displays (prescaler:1)

    My board developpement is EasyPic4

    If I write not a Pause after TMR1H %11111111
    then the displays don't work

Similar Threads

  1. Clock using Instant Interrupts
    By PICpocket in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 16th February 2009, 22:43
  2. DT instant interrupts with mister_e keypad
    By Tomexx in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 26th November 2008, 21:02
  3. DT's Instant Interrupts trouble
    By Tomexx in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 24th November 2008, 21:48
  4. Keypad and DT's Instant Interrupts
    By Homerclese in forum General
    Replies: 11
    Last Post: - 27th April 2007, 07:32
  5. Replies: 1
    Last Post: - 1st November 2006, 04:11

Members who have read this thread : 6

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

Tags for this Thread

Posting Permissions

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