Where should I discuss SD/MMC FAT issues?


Closed Thread
Results 1 to 40 of 93

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default

    Shouldn't be more than the amount of NOP. When you call a macro it just paste the macro code, but use another name.

    While it's not the best code efficient, You could also use some self expanding macro by adding an argument, so if you need 2,3 or 10 NOP, it will do it for you automatically. Not sure if you need it here.

    something like
    Code:
    <font color="#000080">ASM
    NOP?C   macro Cin
        local a
    a=0
        while a&lt;Cin
            nop
    a++=1
            endw
        endm
    ENDASM
    </font>
    If you use @ NOP?C 1 it will paste 1 NOP and so on.
    Last edited by mister_e; - 1st April 2008 at 18:12.
    Steve

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

  2. #2
    Join Date
    Mar 2008
    Location
    Texas, USA
    Posts
    114


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e View Post
    Shouldn't be more than the amount of NOP. When you call a macro it just paste the macro code, but use another name.

    While it's not the best code efficient, You could also use some self expanding macro by adding an argument, so if you need 2,3 or 10 NOP, it will do it for you automatically. Not sure if you need it here.

    something like
    Code:
    <font color="#000080">ASM
    NOP?C   macro Cin
        local a
    a=0
        while a&lt;Cin
            nop
    a++=1
            endw
        endm
    ENDASM
    </font>
    If you use @ NOP?C 1 it will paste 1 NOP and so on.
    Thanks! I've written ASM programs, but never explored the macro functions. When I said 9Tcy I was looking at the added overhead of jumping in and out of the ASM sub. I was thinking that just to jump-to and return-from takes 4Tcy.
    No, I'm not Superman, but I did stay at a Holiday Inn Express last night!

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


    Did you find this post helpful? Yes | No

    Default

    Sometime knowing a bit of ASM and MPASM directive is handy. I learned it through Darrel's codeS and postS... it's all it's fault
    Steve

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

  4. #4
    Join Date
    Mar 2008
    Location
    Texas, USA
    Posts
    114


    Did you find this post helpful? Yes | No

    Talking

    Quote Originally Posted by mister_e View Post
    Sometime knowing a bit of ASM and MPASM directive is handy. I learned it through Darrel's codeS and postS... it's all it's fault
    If you have to be corrupted by someone, Darrel seems to be a good choice!
    No, I'm not Superman, but I did stay at a Holiday Inn Express last night!

  5. #5
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by JD123 View Post
    If you have to be corrupted by someone, Darrel seems to be a good choice!
    Ya, no kidding, and of course, you're absolutely right about the 9 Tcyc.
    A guy should never post 'from the hip', but I do it anyways...

    If you use @ NOP?C 1 it will paste 1 NOP and so on.
    And this little tidbit right here could be the solution to one of my ongoing 'issues' on another project...

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


    Did you find this post helpful? Yes | No

    Default

    Great! But you where wrong about the 9Tcy... Read previous post again... or build an ASM project then watch the Program Memory window.
    Steve

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

  7. #7
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e View Post
    Great! But you where wrong about the 9Tcy... Read previous post again... or build an ASM project then watch the Program Memory window.
    And yet again, that's what I get for posting off the hip... Since when is a macro...a subroutine? Must forgive my blatent stupidity...the house payment is due today
    So, does that little @ NOP?C trick work any other little way that I'm not knowing of yet with anything else?

    BTW...Self-Expanding Macro is my new buzzword...

Similar Threads

  1. Reading and Writing from SD/MMC cards as FAT filesystem?
    By charliez in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 22nd June 2006, 23:26

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