cscg22-gearboy

CSCG 2022 Challenge 'Gearboy'
git clone https://git.sinitax.com/sinitax/cscg22-gearboy
Log | Files | Refs | sfeed.txt

tim.s (509B)


      1        .include        "global.s"
      2
      3        .globl  .int, .int_0x50
      4        .globl  .add_TIM
      5
      6        .area   _HEADER_TIM (ABS)
      7
      8        .org    0x50            ; TIM
      9.int_TIM:
     10        PUSH    AF
     11        PUSH    HL
     12        LD      HL,#.int_0x50
     13        JP      .int
     14
     15        .area   _HOME
     16
     17_add_TIM::
     18        PUSH    BC
     19        LDA     HL,4(SP)        ; Skip return address and registers
     20        LD      C,(HL)
     21        INC     HL
     22        LD      B,(HL)
     23        CALL    .add_TIM
     24        POP     BC
     25        RET