diff options
author | Remy Oukaour <remy.oukaour@gmail.com> | 2017-12-25 13:40:10 -0500 |
---|---|---|
committer | Remy Oukaour <remy.oukaour@gmail.com> | 2017-12-25 14:23:16 -0500 |
commit | e34e68095df1f91dc5357669c187623d7cba39c6 (patch) | |
tree | 5a452f39d9c44012df90a12f1524042c6dbcd062 /engine/printer_serial.asm | |
parent | da2b01a36c6855230ec36c42bd49e7cf2ca2d348 (diff) |
Resolve #428: Use `HIGH(X)` and `LOW(X)` instead of `X / $100` and `X % $100` or `X >> 8` and `X & $ff`
Diffstat (limited to 'engine/printer_serial.asm')
-rwxr-xr-x | engine/printer_serial.asm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/engine/printer_serial.asm b/engine/printer_serial.asm index 6909a38b2..06891db5b 100755 --- a/engine/printer_serial.asm +++ b/engine/printer_serial.asm @@ -109,9 +109,9 @@ Printer_StartTransmittingTilemap: ; 84099 (21:4099) call Printer_CopyPacket ; prepare to send 40 tiles call Printer_Convert2RowsTo2bpp - ld a, (40 tiles) % $100 + ld a, LOW(40 tiles) ld [wPrinterSendByteCounter], a - ld a, (40 tiles) / $100 + ld a, HIGH(40 tiles) ld [wPrinterSendByteCounter + 1], a ; compute the checksum call Printer_ComputeChecksum @@ -142,9 +142,9 @@ Printer_SignalSendHeader: ; 840de (21:40de) call Printer_CopyPacket ; prepare to send 1 tile call Printer_StageHeaderForSend - ld a, 4 % $100 + ld a, LOW(4) ld [wPrinterSendByteCounter], a - ld a, 4 / $100 + ld a, HIGH(4) ld [wPrinterSendByteCounter + 1], a ; compute the checksum call Printer_ComputeChecksum |