ld [$1+1], c
#endmacro
+
+ ; reads a 16 bit register
+ ; to an m16 regsiter
+ ; inputs:
+ ; $1: m16_a/b
+ ; returns:
+ ; r16: 16 bit integer
+#macro m16_read_bc
+ ld a, [$1]
+ ld c, a
+ ld a, [$1+1]
+ ld b, a
+#endmacro
+#macro m16_read_de
+ ld a, [$1]
+ ld e, a
+ ld a, [$1+1]
+ ld d, a
+#endmacro
+#macro m16_read_hl
+ ld a, [$1]
+ ld l, a
+ ld a, [$1+1]
+ ld h, a
+#endmacro
+
; 16 bit add
; inputs:
; m16_a/m16_b