git.y1.nz

gbdk-2020

GameBoy Development Kit
download: https://git.y1.nz/archives/gbdk.tar.gz
README | Files | Log | Refs | LICENSE

gbdk-lib/libc/targets/sm83/emu_debug_printf.s

      1         .include "global.s"
      2 
      3         .title  "EMU_debug"
      4         .module EMU_debug
      5 
      6         .area   _HOME
      7 
      8 ;;void EMU_printf(const unsigned char * fmt, ...)
      9 _EMU_printf::
     10         ldhl sp, #2
     11         ld d, h
     12         ld e, l
     13         inc de
     14         inc de
     15         ld a, (hl+)
     16         ld h, (hl)
     17         ld l, a
     18 
     19         ld  d, d
     20         jr 1$
     21         .dw 0x6464
     22         .dw 0x0200
     23 1$:
     24         ret
     25 
     26 ;;void EMU_fmtbuf(const unsigned char * fmt, void * data)
     27 _EMU_fmtbuf::
     28         ld h, d
     29         ld l, e
     30         ld d, b
     31         ld e, c
     32 
     33         ld  d, d
     34         jr 1$
     35         .dw 0x6464
     36         .dw 0x0200
     37 1$:
     38         ret

This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.