From c3b0fa04a663fe233765b83d3be41a42aa08c25d Mon Sep 17 00:00:00 2001 From: "Juan J. Martinez" Date: Mon, 3 May 2021 08:21:10 +0100 Subject: Initial import for public release --- lib/cpcrslib/cpc_DisableEnableFirmware.s | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 lib/cpcrslib/cpc_DisableEnableFirmware.s (limited to 'lib/cpcrslib/cpc_DisableEnableFirmware.s') diff --git a/lib/cpcrslib/cpc_DisableEnableFirmware.s b/lib/cpcrslib/cpc_DisableEnableFirmware.s new file mode 100644 index 0000000..00a8710 --- /dev/null +++ b/lib/cpcrslib/cpc_DisableEnableFirmware.s @@ -0,0 +1,28 @@ +.globl _cpc_DisableFirmware + +_cpc_DisableFirmware:: + DI + LD HL,(#0X0038) + LD (backup_fw),HL + LD HL,#0X0038 + LD (HL),#0XFB ;EI + INC HL + LD (HL),#0XC9 ;RET + EI + RET + +backup_fw: + .DW #0 + +.globl _cpc_EnableFirmware + +_cpc_EnableFirmware:: + DI + LD DE,(backup_fw) + LD HL,#0X0038 + LD (HL),E ;EI + INC HL + LD (HL),D ;RET + EI + RET + -- cgit v1.2.3