ASM question


Closed Thread
Results 1 to 3 of 3

Thread: ASM question

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default Re: ASM question

    It would probably be easier to use an FSR.
    And the array doesn't need to be in BANKA so you're not limited in size.

    This shows how it could work in PBP.
    Hopefully you can see how it works with ASM too.

    Code:
    MyArray  VAR BYTE[32]
    Abyte    VAR BYTE
    X        VAR BYTE
    
    Init:
        ARRAYWRITE MyArray,["Hello World!",13,10]
    
    ;------------------------------------------
    Main:
    @   LFSR  0, _MyArray
        FOR X = 0 TO 13
    @       MOVE?BB  POSTINC0, _Abyte
            HSEROUT [Abyte]
        NEXT X
        PAUSE 1000
    GOTO Main
    DT

  2. #2
    Join Date
    Sep 2005
    Location
    Campbell, CA
    Posts
    1,107


    Did you find this post helpful? Yes | No

    Default Re: ASM question

    Thanks Darrel,

    That is exactly what I was looking for.

    Now I'll have a fully functional I2C slave running in an ASM interrupt. Much less overhead than writing it in PBP.
    Charles Linquist

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