Instant Interrupts - Revisited


Closed Thread
Results 1 to 40 of 773

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    1) Are you really using a 20 Mhz crystal?
    Not very many people use crystals on an 8-pin PIC.

    2) 40 Hz is really slow for LED's
    Increase the SPWM_FREQ.
    DT

  2. #2
    Join Date
    Jan 2014
    Posts
    84


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    I use in config : @_INTRC_OSC_NOCLKOUT . its necessary to use external crystal ?
    I increased the SPWM_FREQ at 219 and leds are relativelly well
    Last edited by midali; - 8th January 2014 at 19:35.

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


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    No, it is not necessary to use a crystal.
    But your DEFINE OSC must match your actual oscillator frequency.

    If you have specified the internal oscillator in your configs, then the default is 4Mhz, not 20Mhz.
    And your program is running at 1/5th the speed it is supposed to.
    DT

  4. #4
    Join Date
    Jan 2014
    Posts
    84


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    Thank you for your help and patience !

  5. #5
    Join Date
    Jan 2014
    Posts
    84


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    Can somebody help me with this code for 12F683: ?

    I want to blink very quikly a led in background ,independent of my code, random, pause between 1-20 ms. I think that this interval is ok, the best if its possible to set pause limits.
    I want learn about intrerupts but i think that I'm too old ...

    thx in advance !!

  6. #6
    Join Date
    Jan 2014
    Posts
    84


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    ...or , how I can make SPWM without intrerupts...?

  7. #7


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    Quote Originally Posted by midali View Post
    ...or , how I can make SPWM without intrerupts...?
    Darrel came up with a terrific piece of code for my project - have a look at this thread:

    http://www.picbasic.co.uk/forum/showthread.php?t=17299

  8. #8
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    2,645


    Did you find this post helpful? Yes | No

    Default Re: Instant Interrupts - Revisited

    Quote Originally Posted by midali View Post
    I want to blink very quikly a led in background ,independent of my code...I want learn about intrerupts but i think that I'm too old...
    Try this as an intro to Darrel Interrupts and blinking LED:
    http://darreltaylor.com/DT_INTS-14/blinky.html

    It's worth the time to practice. His routines make things so much easier and flexible later on as you add more complexity to your code.

    Robert

Similar Threads

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

Members who have read this thread : 8

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