初次用PIC16Fxxx汇编,感觉总是要选择BANK很麻烦

2020-02-10 08:35发布

每操作一个寄存器,都要考虑它在什么BANK中.是不是有点麻烦
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
9条回答
smallworm
2020-02-11 01:29
fcall        macro subroutine_name
        local here
        lcall subroutine_name
        pagesel here
here:
        endm

interrupt_handler CODE 0x0005
        ...
        RETFIE

another_code_section CODE

main_loop:
        fcall test1
        fcall test2
        call test4
        fcall test3
        goto main_loop

test4:
        return

yet_another_code_section CODE

test1:
        call test2
        call test3
        fcall test4
        return

test2:
        return

test3
        return

END

一周热门 更多>