Serial and interrupt


Closed Thread
Results 1 to 21 of 21

Hybrid View

  1. #1
    Join Date
    Feb 2009
    Posts
    12


    Did you find this post helpful? Yes | No

    Default

    Before posting posting to this forum I tried "DT_INTS-14" but I got some compailing errors, any idea how to fix them?

    Code:
    wsave3 position request 416 beyond RAM_END 95
    wsave2 position request 288 beyond RAM_END 95
    wsave1 position request 160 beyond RAM_END 95
    Unable to fit variable RS2_Save

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


    Did you find this post helpful? Yes | No

    Default

    open DT_INTS-14.bas file, there you'll find
    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
    So, just modify it as requested
    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
    Steve

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

  3. #3
    Join Date
    Feb 2009
    Posts
    12


    Did you find this post helpful? Yes | No

    Default

    So I did and now there's only one error left...
    Code:
    Unable to fit variable RS2_Save

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


    Did you find this post helpful? Yes | No

    Default

    well, seems we hit one of the limitation of the low-end PIC. In this case, asm INT and home made serial routine would work. 12F683 would provide better range.


    Let's see what Darrel would suggest...
    Last edited by mister_e; - 4th February 2009 at 22:52.
    Steve

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

  5. #5
    Join Date
    Feb 2009
    Posts
    12


    Did you find this post helpful? Yes | No

    Default

    I suppose that the only way to write the serial routine is to code it in asm.

    Damn me for choosing this somewhat limited pic

  6. #6
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    12f683 is 8 pin device and has twice the flash memory available.
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  7. #7
    Join Date
    Feb 2009
    Posts
    12


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Joe S. View Post
    12f683 is 8 pin device and has twice the flash memory available.
    Thanks for the tip, but I have already bought the other one - as I said to late to change my mind. Anyway i've been doing some diggin and I'm going forward with the ASM serial routine part. There's only one little problem - the code I'm using gives me a "Symbol previously not defined" error. How do I setup variables so I can write to them inside the asm code and reuse them in picbasic?

Similar Threads

  1. Instant Interrupts - Revisited
    By Darrel Taylor in forum Code Examples
    Replies: 772
    Last Post: - 17th February 2016, 22:14
  2. 18F2480 asm interrupt
    By Richard Storie in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 5th March 2009, 19:40
  3. Serial and Port B interrupt
    By Pic2008 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 6th November 2008, 16:22
  4. timer and serial interrupt
    By yourmomOS in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 14th July 2006, 18:02
  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