Darrels interrupts and multiple SOUND statements, will it work?


Closed Thread
Results 1 to 32 of 32

Hybrid View

  1. #1
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    Thanks Richard!
    Didn't think about the lack of auto context save on the 16F parts, thanks for picking that up!

    Yes, the 12F1822 can run at up to 32MHz from its internal oscillator and it has the auto context save - it would be a good choice for this, as said before.

    CuriousOne,
    Please try Richards edited version on your 12F1822 and see if it works.

    /Henrik.

  2. #2
    Join Date
    May 2013
    Location
    australia
    Posts
    2,653


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    you might save a few cycles if you clear the tris bit for the outputs and


    replace the If Accumulator_x < old_x THEN Toggle Channel_x lines

    with If Accumulator_x < old_x THEN Channel_x=! Channel_x

  3. #3
    Join Date
    May 2013
    Location
    australia
    Posts
    2,653


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    the label problem is resolved with

    @Generate
    instead of
    @ Generate

  4. #4
    Join Date
    May 2013
    Location
    australia
    Posts
    2,653


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    wsave psave etc can't just go anywhere

    try this

    wsave VAR BYTE $70 SYSTEM ;wsave in access RAM
    ssave VAR BYTE BANK0 SYSTEM
    psave VAR BYTE BANK0 SYSTEM

    not sure when to use wsave VAR BYTE $20 SYSTEM
    Last edited by richard; - 15th January 2015 at 10:54. Reason: typo

  5. #5
    Join Date
    Feb 2013
    Posts
    1,132


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    OK, will try later, my programmer engulfed in smokes right now

  6. #6
    Join Date
    Feb 2013
    Posts
    1,132


    Did you find this post helpful? Yes | No

    Default Re: Darrels interrupts and multiple SOUND statements, will it work?

    I'm running it separately, without any interrupts or code involved.

Similar Threads

  1. Multiple IF THEN Statements: PIC16F84A
    By bob425 in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 10th August 2012, 06:01
  2. Problem with multiple interrupts
    By aratti in forum General
    Replies: 7
    Last Post: - 2nd June 2009, 08:18
  3. Multiple IF-THEN statements
    By DavidK in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 20th June 2007, 18:28
  4. Handeling multiple Interrupts
    By BobSpencerr in forum General
    Replies: 15
    Last Post: - 1st March 2007, 01:12
  5. Multiple HW Interrupts
    By Radiance in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 13th August 2003, 22:35

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