From 9d92eacdcd7dcde9d73c65a1f203a2c310c4f179 Mon Sep 17 00:00:00 2001 From: Philip Smart Date: Tue, 24 Mar 2020 01:16:39 +0000 Subject: [PATCH] Removed temp files --- .gitignore | 1 + software/src/PetitFS/pff_obj/new.asm | 5962 -------------------- software/src/PetitFS/pff_obj/new.err | 592 -- software/src/PetitFS/pff_obj/pff.asm | 3863 ------------- software/src/PetitFS/pff_obj/pff_dir.asm | 1267 ----- software/src/PetitFS/pff_obj/pff_dir.o | Bin 12326 -> 0 bytes software/src/PetitFS/pff_obj/pff_func.asm | 1227 ---- software/src/PetitFS/pff_obj/pff_func.o | Bin 9314 -> 0 bytes software/src/PetitFS/pff_obj/pff_mount.asm | 625 -- software/src/PetitFS/pff_obj/pff_mount.o | Bin 4579 -> 0 bytes software/src/PetitFS/pff_obj/pff_open.asm | 340 -- software/src/PetitFS/pff_obj/pff_open.o | Bin 1138 -> 0 bytes software/src/PetitFS/pff_obj/pff_read.asm | 615 -- software/src/PetitFS/pff_obj/pff_read.o | Bin 4414 -> 0 bytes software/src/PetitFS/pff_obj/pff_write.asm | 742 --- software/src/PetitFS/pff_obj/pff_write.o | Bin 5216 -> 0 bytes software/src/PetitFS/pff_obj/sdmmc.asm | 1111 ---- software/src/PetitFS/pff_obj/sdmmc.o | Bin 8204 -> 0 bytes software/src/PetitFS/pff_obj/sdtest.asm | 857 --- software/src/PetitFS/pff_obj/sdtest.o | Bin 9520 -> 0 bytes 20 files changed, 1 insertion(+), 17201 deletions(-) delete mode 100644 software/src/PetitFS/pff_obj/new.asm delete mode 100644 software/src/PetitFS/pff_obj/new.err delete mode 100644 software/src/PetitFS/pff_obj/pff.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_dir.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_dir.o delete mode 100644 software/src/PetitFS/pff_obj/pff_func.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_func.o delete mode 100644 software/src/PetitFS/pff_obj/pff_mount.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_mount.o delete mode 100644 software/src/PetitFS/pff_obj/pff_open.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_open.o delete mode 100644 software/src/PetitFS/pff_obj/pff_read.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_read.o delete mode 100644 software/src/PetitFS/pff_obj/pff_write.asm delete mode 100644 software/src/PetitFS/pff_obj/pff_write.o delete mode 100644 software/src/PetitFS/pff_obj/sdmmc.asm delete mode 100644 software/src/PetitFS/pff_obj/sdmmc.o delete mode 100644 software/src/PetitFS/pff_obj/sdtest.asm delete mode 100644 software/src/PetitFS/pff_obj/sdtest.o diff --git a/.gitignore b/.gitignore index 90a5406..a5d12ce 100644 --- a/.gitignore +++ b/.gitignore @@ -27,6 +27,7 @@ *.pof *.qdf *.srf +*.o Manuals/ software/asm/CPM22-BIOS.asm software/asm/MZ80AFI.asm.bak diff --git a/software/src/PetitFS/pff_obj/new.asm b/software/src/PetitFS/pff_obj/new.asm deleted file mode 100644 index 59667d5..0000000 --- a/software/src/PetitFS/pff_obj/new.asm +++ /dev/null @@ -1,5962 +0,0 @@ -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 16:37:44 2020 - - - - MODULE sdtest_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION code_compiler - -; Function die flags 0x00000200 __smallc -; void die(const int rc) -; parameter 'const int rc' at 2 size(2) -._die - ld hl,i_1+0 - push hl - ld hl,4 ;const - call l_gintsp ; - push hl - ld a,2 - call printf - pop bc - pop bc - ld hl,i_1+20 - push hl - ld a,1 - call printf - pop bc - ld hl,10 ;const - call sleep - ret - - - -; Function main flags 0x00000000 __stdc -; int main() -._main - ld hl,65381 ;const - add hl,sp - ld sp,hl - ld hl,i_1+41 - push hl - ld a,1 - call printf - pop bc - ld hl,i_1+86 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - call _disk_initialize - call l_lneg - jp nc,i_2 - ld hl,i_1+115 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - push hl - ld hl,115 ;const - add hl,sp - push hl - call _pf_mount - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_3 - ld hl,i_1+137 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_3 - ld hl,i_1+192 - push hl - ld a,1 - call printf - pop bc -.i_2 - ld hl,i_1+209 - push hl - ld hl,115 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,118 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,121 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,124 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,129 ;const - add hl,sp - call l_glong2sp - ld hl,137 ;const - call l_glongsp ; - ld a,9 - call printf - ld hl,18 ;const - add hl,sp - ld sp,hl - ld hl,i_1+275 - push hl - ld hl,129 ;const - add hl,sp - call l_glong2sp - ld hl,137 ;const - add hl,sp - call l_glong2sp - ld hl,145 ;const - add hl,sp - call l_glong2sp - ld hl,153 ;const - add hl,sp - call l_glong2sp - ld hl,161 ;const - add hl,sp - call l_glong2sp - ld hl,169 ;const - add hl,sp - call l_glong2sp - ld hl,177 ;const - call l_glongsp ; - ld a,15 - call printf - ld hl,30 ;const - add hl,sp - ld sp,hl - ld hl,10 ;const - call sleep - ld hl,i_1+365 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - push hl - ld hl,99 ;const - add hl,sp - push hl - ld hl,i_1+19 - push hl - call _pf_opendir - pop bc - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_4 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_4 - ld hl,i_1+388 - push hl - ld a,1 - call printf - pop bc -.i_5 -.i_7 - ld hl,3 ;const - add hl,sp - push hl - ld hl,99 ;const - add hl,sp - push hl - ld hl,79 ;const - add hl,sp - push hl - call _pf_readdir - pop bc - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_9 - ld hl,75 ;const - call l_gcharsp ; - call l_lneg - jr nc,i_8 -.i_9 - jp i_6 -.i_8 - ld hl,83 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_11 - ld hl,i_1+411 - push hl - ld hl,86 ;const - add hl,sp - push hl - ld a,2 - call printf - pop bc - pop bc - jp i_12 -.i_11 - ld hl,i_1+425 - push hl - ld hl,77 ;const - add hl,sp - call l_glong2sp - ld hl,90 ;const - add hl,sp - push hl - ld a,4 - call printf - pop bc - pop bc - pop bc - pop bc -.i_12 - jp i_5 -.i_6 - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_13 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_13 - ld hl,i_1+435 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - push hl - ld hl,i_1+469 - push hl - call _pf_open - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_14 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_14 - ld hl,i_1+481 - push hl - ld a,1 - call printf - pop bc -.i_15 - ld hl,3 ;const - add hl,sp - push hl - ld hl,7 ;const - add hl,sp - push hl - ld hl,64 ;const - push hl - ld hl,77 ;const - add hl,sp - push hl - call _pf_read - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_18 - ld hl,71 ;const - call l_gintsp ; - call l_lneg - jr nc,i_17 -.i_18 - jp i_16 -.i_17 - ld hl,69 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint - jp i_22 -.i_20 - ld hl,69 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) -.i_22 - ld hl,69 ;const - call l_gintspsp ; - ld hl,73 ;const - call l_gintsp ; - pop de - ex de,hl - and a - sbc hl,de - jp nc,i_21 - ld hl,5 ;const - add hl,sp - ex de,hl - ld hl,69 ;const - call l_gintsp ; - add hl,de - ld l,(hl) - ld h,0 - push hl - ld hl,__sgoioblk+10 - push hl - call fputc_callee - jp i_20 -.i_21 - jp i_15 -.i_16 - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_23 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_23 - ld hl,20 ;const - call sleep - ld hl,i_1+506 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - push hl - ld hl,i_1+543 - push hl - call _pf_open - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_24 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_24 - ld hl,i_1+554 - push hl - ld a,1 - call printf - pop bc -.i_25 -.i_27 - ld hl,3 ;const - add hl,sp - push hl - ld hl,i_1+590 - push hl - ld hl,14 ;const - push hl - ld hl,79 ;const - add hl,sp - push hl - call _pf_write - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_29 - ld hl,73 ;const - call l_gintsp ; - call l_lneg - jr nc,i_28 -.i_29 - jp i_26 -.i_28 - jp i_25 -.i_26 - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_31 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_31 - ld hl,i_1+605 - push hl - ld a,1 - call printf - pop bc - ld hl,3 ;const - add hl,sp - push hl - ld hl,0 ;const - push hl - push hl - ld hl,79 ;const - add hl,sp - push hl - call _pf_write - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,3 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_32 - ld hl,3 ;const - call l_gintsp ; - push hl - call _die - pop bc -.i_32 - ld hl,i_1+641 - push hl - ld a,1 - call printf - pop bc -.i_33 -.i_35 - jp i_33 -.i_34 - ld hl,155 ;const - add hl,sp - ld sp,hl - ret - - - SECTION rodata_compiler -.i_1 - defm "Failed with rc=%u." - defb 10 - - defm "" - defb 0 - - defm "Please press reset." - defb 10 - - defm "" - defb 0 - - defm "Hello Philip, this C program i" - defm "s working...." - defb 10 - - defm "" - defb 0 - - defm "Firstly, initialise SD card" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Now Mount a volume." - defb 10 - - defm "" - defb 0 - - defm "Failed to initialise sd card 0" - defm ", please init manually." - defb 10 - - defm "" - defb 0 - - defm "Volume mounted." - defb 10 - - defm "" - defb 0 - - defm "FSTYPE:%d, FLAG:%d, CSIZE:%d, " - defm "PADL:%d, N_FATENT:%ld, FATBASE" - defm ":%;d" - defb 10 - - defm "" - defb 0 - - defm "DIRBASE:%ld, DATABASE:%ld, FPT" - defm "R:%ld, FSIZE:%ld, ORG_CLUST:%l" - defm "d, CURR_CLUST:%ld, DSECT:%ld" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Open root directory." - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Directory listing..." - defb 10 - - defm "" - defb 0 - - defm " %s" - defb 10 - - defm "" - defb 0 - - defm "%8lu %s" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Open a test file (message.txt)" - defm "." - defb 10 - - defm "" - defb 0 - - defm "MESSAGE.TXT" - defb 0 - - defm "" - defb 10 - - defm "Type the file content." - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Open a file to write (readme.t" - defm "xt)." - defb 10 - - defm "" - defb 0 - - defm "README.TXT" - defb 0 - - defm "" - defb 10 - - defm "Write a text data. (Hello worl" - defm "d!)" - defb 10 - - defm "" - defb 0 - - defm "Hello world!" - defb 13 - - defm "" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Terminate the file write proce" - defm "ss." - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Test completed." - defb 10 - - defm "" - defb 0 - - -; --- Start of Static Variables --- - - SECTION bss_compiler - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _die - GLOBAL _main - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 16:37:44 2020 - - - - MODULE sdmmc_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION data_compiler -._Stat - defb 1 - SECTION code_compiler - -; Function spi_init flags 0x00000200 __smallc -; int spi_init() -._spi_init - LD A, 0x04 | 0x00 | 0x00 ; Clock and MOSI High. - OUT ( 0xFF ),A - LD B,80 - LD A, 0x04 | 0x00 | 0x00 ; Output a 1 -SPIINIT1: OUT ( 0xFF ),A - NOP - NOP - LD A, 0x04 | 0x02 | 0x00 ; Output a 1 - OUT ( 0xFF ),A - NOP - NOP - DJNZ SPIINIT1 - LD A, 0x04 | 0x00 | 0x00 ; Output a 1 - OUT ( 0xFF ),A - LD HL,0 ; hl is the return parameter - ret - - - -; Function spi_cs flags 0x00000200 __smallc -; int spi_cs(unsigned char b) -; parameter 'unsigned char b' at 2 size(1) -._spi_cs - ret - - - -; Function spi_out flags 0x00000200 __smallc -; int spi_out(unsigned char b) -; parameter 'unsigned char b' at 2 size(1) -._spi_out - LD HL,2 - ADD HL,SP ; skip over return address on stack - LD A,(HL) ; a = b, "char b" occupies 16 bits on stack - ; but only the LSB is relevant - LD E,A ; E = Character to send. - LD B,08H ; B = Bit count -SPIOUT0: RL E - LD A, 0x00 | 0x00 | 0x00 ; Output a 0 - JR NC,SPIOUT1 - LD A, 0x04 | 0x00 | 0x00 ; Output a 1 -SPIOUT1: OUT ( 0xFF ),A - LD D,A - OR 0x02 - OUT ( 0xFF ),A - LD A,D - OUT ( 0xFF ),A - DJNZ SPIOUT0 ; Perform actions for the full 8 bits. - ;LD A, 0x04 | 0x00 | 0x00 ; Return clock and MOSI to high. - ;OUT ( 0xFF ),A - LD HL,0 ; hl is the return parameter - ret - - - -; Function spi_in flags 0x00000200 __smallc -; unsigned char uint8_tspi_in() -._spi_in - LD BC,0800H ; B = Bit count, C = Character being read. -SPIIN0: LD A, 0x04 | 0x00 | 0x00 ; Output a 0 -SPIIN1: OUT ( 0xFF ),A - LD D,A - OR 0x02 - OUT ( 0xFF ),A - NOP - IN A,( 0xFE ) ; Input the received bit - SRL A - RL C - LD A,D - OUT ( 0xFF ),A - DJNZ SPIIN0 ; Perform actions for the full 8 bits. - LD L,C ; hl is the return parameter - LD H,0 - ret - - - -; Function spi_skip flags 0x00000200 __smallc -; void spi_skip(unsigned int n) -; parameter 'unsigned int n' at 2 size(2) -._spi_skip - dec sp -.i_5 - ld hl,0 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_3 - ld hl,3 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - ld a,h - or l - jp nz,i_5 -.i_4 - inc sp - ret - - - -; Function send_cmd flags 0x00000200 __smallc -; unsigned char BYTEsend_cmd(unsigned char cmd, unsigned long arg) -; parameter 'unsigned long arg' at 2 size(4) -; parameter 'unsigned char cmd' at 6 size(1) -._send_cmd - push bc - ld hl,8 ;const - add hl,sp - ld a,+(128 % 256) - and (hl) - jp z,i_6 - ld hl,8 ;const - add hl,sp - push hl - ld a,(hl) - and +(127 % 256) - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - add hl,sp - push hl - ld hl,55 ;const - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - pop de - ld a,l - ld (de),a - pop hl - push hl - ld h,0 - ld a,1 - sub l - jp nc,i_7 - pop hl - push hl - ld h,0 - pop bc - ret - - -.i_7 -.i_6 - ld hl,255 ;const - push hl - call _spi_cs - pop bc - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - call _spi_out - pop bc - ld hl,7 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - push hl - call _spi_out - pop bc - ld hl,6 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - push hl - call _spi_out - pop bc - ld hl,5 ;const - add hl,sp - ld e,(hl) - inc hl - inc hl - ld l,(hl) - ld h,0 - ex de,hl - ld h,0 - push hl - call _spi_out - pop bc - ld hl,4 ;const - add hl,sp - call l_glong - ld h,0 - push hl - call _spi_out - pop bc - ld hl,1 ;const - add hl,sp - ld (hl),+(1 % 256 % 256) - ld hl,8 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_8 - ld hl,1 ;const - add hl,sp - ld (hl),+(149 % 256 % 256) -.i_8 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 8 - jp nz,i_9 - ld hl,1 ;const - add hl,sp - ld (hl),+(135 % 256 % 256) -.i_9 - pop hl - push hl - ld l,h - ld h,0 - push hl - call _spi_out - pop bc - ld hl,1 ;const - add hl,sp - ld (hl),+(10 % 256 % 256) -.i_12 - ld hl,0 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_10 - pop hl - push hl - ld h,0 - ld a,l - and +(128 % 256) - jp z,i_13 - ld hl,1 ;const - add hl,sp - dec (hl) - ld a,(hl) - and a - jr nz,i_14_i_13 -.i_13 - jp i_11 -.i_14_i_13 - jp i_12 -.i_11 - pop hl - push hl - ld h,0 - pop bc - ret - - - -; Function disk_initialize flags 0x00000200 __smallc -; unsigned char DSTATUSdisk_initialize() -._disk_initialize - push bc - push bc - push bc - push bc - dec sp - call _spi_init - ld hl,6 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld hl,0 ;const - push hl - ld d,h - ld e,l - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - cp 1 - jp nz,i_15 - ld hl,8 ;const - push hl - ld hl,426 ;const - ld de,0 - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - cp 1 - jp nz,i_16 - ld hl,i_1+0 - push hl - ld a,1 - call printf - pop bc - ld hl,8 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_19 -.i_17 - ld hl,8 ;const - add hl,sp - inc (hl) -.i_19 - ld hl,8 ;const - add hl,sp - ld a,(hl) - sub 4 - jp nc,i_18 - ld hl,2 ;const - add hl,sp - ex de,hl - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - push hl - call _spi_in - pop de - ld a,l - ld (de),a - jp i_17 -.i_18 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 1 - jp nz,i_21 - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 170 - jr z,i_22_i_21 -.i_21 - jp i_20 -.i_22_i_21 - ld hl,1000 ;const - pop bc - push hl - jp i_25 -.i_23 - pop hl - dec hl - push hl - inc hl -.i_25 - pop hl - push hl - ld a,h - or l - jp z,i_24 - ld hl,169 ;const - push hl - ld hl,0 ;const - ld de,16384 - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp z,i_24 -.i_26 - ld hl,2000 ;const - call t_delay - jp i_23 -.i_24 - pop hl - push hl - ld a,h - or l - jp z,i_28 - ld hl,58 ;const - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jr z,i_29_i_28 -.i_28 - jp i_27 -.i_29_i_28 - ld hl,8 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_32 -.i_30 - ld hl,8 ;const - add hl,sp - inc (hl) -.i_32 - ld hl,8 ;const - add hl,sp - ld a,(hl) - sub 4 - jp nc,i_31 - ld hl,2 ;const - add hl,sp - ex de,hl - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - push hl - call _spi_in - pop de - ld a,l - ld (de),a - jp i_30 -.i_31 - ld hl,6 ;const - add hl,sp - push hl - ld hl,4 ;const - add hl,sp - ld a,+(64 % 256) - and (hl) - jp z,i_33 - ld hl,12 ;const - jp i_34 -.i_33 - ld hl,4 ;const -.i_34 - pop de - ld a,l - ld (de),a -.i_27 -.i_20 - jp i_35 -.i_16 - ld hl,i_1+20 - push hl - ld a,1 - call printf - pop bc - ld hl,169 ;const - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,1 - sub l - ccf - jp nc,i_36 - ld hl,6 ;const - add hl,sp - ld (hl),+(2 % 256 % 256) - ld hl,7 ;const - add hl,sp - ld (hl),+(169 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_37 -.i_36 - ld hl,6 ;const - add hl,sp - ld (hl),+(1 % 256 % 256) - ld hl,7 ;const - add hl,sp - ld (hl),+(1 % 256 % 256) -.i_37 - ld hl,1000 ;const - pop bc - push hl - jp i_40 -.i_38 - pop hl - dec hl - push hl - inc hl -.i_40 - pop hl - push hl - ld a,h - or l - jp z,i_39 - ld hl,7 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp z,i_39 -.i_41 - ld hl,2000 ;const - call t_delay - jp i_38 -.i_39 - pop hl - push hl - call l_lneg - jp c,i_43 - ld hl,16 ;const - push hl - ld hl,512 ;const - ld de,0 - push de - push hl - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp z,i_42 -.i_43 - ld hl,6 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 -.i_42 -.i_35 -.i_15 - ld hl,6 ;const - add hl,sp - ld a,(hl) - ld (_CardType),a - ld hl,255 ;const - push hl - call _spi_cs - pop bc - ld hl,6 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_45 - ld hl,0 ;const - jp i_46 -.i_45 - ld hl,1 ;const -.i_46 - ld h,0 - inc sp - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function disk_readp flags 0x00000200 __smallc -; const int DRESULTdisk_readp(unsigned char BYTE*buff, unsigned long sector, unsigned int offset, unsigned int count) -; parameter 'unsigned int count' at 2 size(2) -; parameter 'unsigned int offset' at 4 size(2) -; parameter 'unsigned long sector' at 6 size(4) -; parameter 'unsigned char BYTE*buff' at 10 size(2) -._disk_readp - push bc - push bc - push bc - dec sp - ld hl,0 ;const - push hl - call _spi_cs - pop bc - ld hl,(_CardType) - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jp nc,i_47 - ld hl,13 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_mult - pop bc - call l_plong -.i_47 - ld hl,5 ;const - add hl,sp - ld (hl),+(1 % 256) - inc hl - ld (hl),+(1 / 256) - ld hl,17 ;const - push hl - ld hl,15 ;const - call l_glongsp ; - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp nz,i_48 - ld hl,1000 ;const - pop bc - push hl -.i_51 - ld hl,200 ;const - call t_delay - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_49 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 255 - jp nz,i_52 - pop hl - dec hl - push hl - ld a,h - or l - jr nz,i_53_i_52 -.i_52 - jp i_50 -.i_53_i_52 - jp i_51 -.i_50 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 254 - jp nz,i_54 - ld hl,11 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,514 - and a - sbc hl,de - ex de,hl - ld hl,9 ;const - call l_gintsp ; - ex de,hl - and a - sbc hl,de - pop de - pop bc - push hl - push de - ld hl,11 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_55 - ld hl,11 ;const - call l_gintsp ; - push hl - call _spi_skip - pop bc -.i_55 - ld hl,17 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_56 -.i_59 - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a - ld hl,17 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - push hl - ld hl,6 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a -.i_57 - ld hl,9 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - ld a,h - or l - jp nz,i_59 -.i_58 - jp i_60 -.i_56 -.i_63 - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_61 - ld hl,9 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - ld a,h - or l - jp nz,i_63 -.i_62 -.i_60 - pop bc - pop hl - push hl - push bc - push hl - call _spi_skip - pop bc - ld hl,5 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_54 -.i_48 - ld hl,255 ;const - push hl - call _spi_cs - pop bc - ld hl,5 ;const - call l_gintsp ; - inc sp - pop bc - pop bc - pop bc - ret - - - -; Function disk_writep flags 0x00000200 __smallc -; const int DRESULTdisk_writep(const unsigned char BYTE*buff, unsigned long sc) -; parameter 'unsigned long sc' at 2 size(4) -; parameter 'const unsigned char BYTE*buff' at 6 size(2) -._disk_writep - push bc - push bc - push bc - ld hl,4 ;const - add hl,sp - ld (hl),+(1 % 256) - inc hl - ld (hl),+(1 / 256) - ld hl,0 ;const - push hl - call _spi_cs - pop bc - ld hl,12 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_64 - ld hl,8 ;const - add hl,sp - call l_glong - pop de - pop bc - push hl - push de -.i_65 - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_67 - ld hl,(_st_disk_writep_wc) - ld a,h - or l - jr nz,i_68_i_67 -.i_67 - jp i_66 -.i_68_i_67 - ld hl,12 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - ld l,(hl) - ld h,0 - push hl - call _spi_out - pop bc - ld hl,(_st_disk_writep_wc) - dec hl - ld (_st_disk_writep_wc),hl - pop de - pop hl - dec hl - push hl - push de - inc hl - jp i_65 -.i_66 - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint - jp i_69 -.i_64 - ld hl,8 ;const - add hl,sp - call l_glong - ld a,h - or l - or d - or e - jp z,i_70 - ld hl,(_CardType) - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jp nc,i_71 - ld hl,8 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_mult - pop bc - call l_plong -.i_71 - ld hl,24 ;const - push hl - ld hl,10 ;const - call l_glongsp ; - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp nz,i_72 - ld hl,255 ;const - push hl - call _spi_out - pop bc - ld hl,254 ;const - push hl - call _spi_out - pop bc - ld hl,512 ;const - ld (_st_disk_writep_wc),hl - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_72 - jp i_73 -.i_70 - ld hl,(_st_disk_writep_wc) - inc hl - inc hl - pop de - pop bc - push hl - push de -.i_74 - pop de - pop hl - dec hl - push hl - push de - inc hl - ld a,h - or l - jp z,i_75 - ld hl,0 ;const - push hl - call _spi_out - pop bc - jp i_74 -.i_75 - call _spi_in - ld a,l - and +(31 % 256) - ld l,a - ld h,0 - cp 5 - jp nz,i_76 - ld hl,10000 ;const - pop bc - push hl - jp i_79 -.i_77 - pop hl - dec hl - push hl - inc hl -.i_79 - call _spi_in - ld a,l - cp 255 - jp z,i_80 - pop hl - push hl - ld a,h - or l - jr nz,i_81_i_80 -.i_80 - jp i_78 -.i_81_i_80 - ld hl,200 ;const - call t_delay - jp i_77 -.i_78 - pop hl - push hl - ld a,h - or l - jp z,i_82 - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_82 -.i_76 - ld hl,255 ;const - push hl - call _spi_cs - pop bc -.i_73 -.i_69 - ld hl,4 ;const - call l_gintsp ; - pop bc - pop bc - pop bc - ret - - - SECTION rodata_compiler -.i_1 - defm "Identified v2 card" - defb 10 - - defm "" - defb 0 - - defm "Identified v1 card" - defb 10 - - defm "" - defb 0 - - -; --- Start of Static Variables --- - - SECTION bss_compiler -._CardType defs 1 -._st_disk_writep_wc defs 2 - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _spi_init - GLOBAL _spi_cs - GLOBAL _spi_out - GLOBAL _spi_in - GLOBAL _spi_skip - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 16:37:44 2020 - - - - MODULE pff_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION code_compiler - -; Function ld_word flags 0x00000200 __smallc -; unsigned int WORDld_word(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_word - push bc - ld hl,4 ;const - call l_gintsp ; - inc hl - ld l,(hl) - ld h,0 - pop bc - push hl - ld h,l - ld l,0 - push hl - ld hl,6 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop bc - ret - - - -; Function ld_dword flags 0x00000200 __smallc -; unsigned long DWORDld_dword(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_dword - push bc - push bc - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - ret - - - -; Function mem_set flags 0x00000200 __smallc -; void mem_set(void *dst, int val, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'int val' at 4 size(2) -; parameter 'void *dst' at 6 size(2) -._mem_set - ld hl,6 ;const - call l_gintsp ; - push hl -.i_2 - ld hl,4 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_3 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,l - call l_sxt - ld a,l - call l_sxt - pop de - ld a,l - ld (de),a - jp i_2 -.i_3 - pop bc - ret - - - -; Function mem_cmp flags 0x00000200 __smallc -; int mem_cmp(const void *dst, const void *src, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'const void *src' at 4 size(2) -; parameter 'const void *dst' at 6 size(2) -._mem_cmp - ld hl,6 ;const - call l_g2intspsp ; - ld hl,0 ;const - push hl -.i_4 - ld hl,8 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_6 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - push hl - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - pop de - ex de,hl - and a - sbc hl,de - pop bc - push hl - ld a,h - or l - jp nz,i_6 - inc hl - jr i_7 -.i_6 - ld hl,0 ;const -.i_7 - ld a,h - or l - jp nz,i_4 -.i_5 - pop hl - pop bc - pop bc - ret - - - -; Function get_fat flags 0x00000200 __smallc -; unsigned long DWORDget_fat(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._get_fat - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - call l_glong - ld a,l - sub 2 - ld a,h - sbc 0 - ld a,e - sbc 0 - ld a,d - sbc 0 - jp c,i_9 - ld hl,8 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_8 -.i_9 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - -.i_8 - pop hl - push hl - ld l,(hl) - ld h,0 -.i_13 - ld a,l - cp +(3% 256) - jp nz,i_12 -.i_14 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,10 - add hl,bc - call l_glong2sp - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld l,+(7 % 256) - call l_long_asr_u - call l_long_add - push de - push hl - ld hl,14 ;const - add hl,sp - call l_glong - ld a,l - and +(127 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - push hl - ld hl,4 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp nz,i_12 -.i_15 - ld hl,2 ;const - add hl,sp - push hl - call _ld_dword - pop bc - ld a,d - and +(15 % 256) - ld d,a - pop bc - pop bc - pop bc - ret - - -.i_12 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - - -; Function clust2sect flags 0x00000200 __smallc -; unsigned long DWORDclust2sect(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._clust2sect - ld hl,(_FatFs) - push hl - ld hl,4 ;const - add hl,sp - push hl - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - call l_long_uge - jp nc,i_16 - ld hl,0 ;const - ld d,h - ld e,l - pop bc - ret - - -.i_16 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - call l_long_mult - push de - push hl - ld hl,4 ;const - call l_gintsp ; - ld bc,18 - add hl,bc - call l_glong - call l_long_add - pop bc - ret - - - -; Function get_clust flags 0x00000200 __smallc -; unsigned long DWORDget_clust(unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -._get_clust - ld hl,(_FatFs) - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - ld hl,0 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,20 - add hl,bc - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong - ex de,hl - ld hl,0 ;const - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld bc,26 - add hl,bc - push hl - call _ld_word - pop bc - pop de - call l_or - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - pop bc - ret - - - -; Function dir_rewind flags 0x00000200 __smallc -; const int FRESULTdir_rewind(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_rewind - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_glong - pop bc - call l_plong - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_eq - jp c,i_18 - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_17 -.i_18 - ld hl,1 ;const - pop bc - pop bc - pop bc - ret - - -.i_17 - ld hl,2 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_20 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,14 - add hl,bc - call l_glong - pop bc - call l_plong -.i_20 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - jp i_21 - ld hl,4 ;const - add hl,sp - call l_glong - ld a,h - or l - or d - or e - jp nz,i_21 - ld hl,0 ;const - jr i_22 -.i_21 - ld hl,1 ;const -.i_22 - jp nc,i_23 - ld hl,4 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - jp i_24 -.i_23 - pop bc - pop hl - push hl - push bc - ld bc,14 - add hl,bc - call l_glong -.i_24 - pop bc - call l_plong - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,4 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,0 ;const - pop bc - pop bc - pop bc - ret - - - -; Function dir_next flags 0x00000200 __smallc -; const int FRESULTdir_next(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_next - push bc - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,10 ;const - call l_gintsp ; - call l_gint ; - inc hl - pop de - pop bc - push hl - push de - call l_lneg - jp c,i_26 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - call l_long_lneg - jp nc,i_25 -.i_26 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_25 - pop bc - pop hl - push hl - push bc - ld a,l - and +(15 % 256) - jp nz,i_28 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - call l_glong - call l_inclong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_29 - ld hl,2 ;const - call l_gintspsp ; - pop bc - pop hl - push hl - push bc - ld bc,4 - add hl,bc - call l_gint ; - pop de - call l_uge - jp nc,i_30 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_30 - jp i_31 -.i_29 - pop bc - pop hl - push hl - push bc - ld de,4 - call l_asr_u_hl_by_e - pop de - push de - push hl - ex de,hl - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - pop de - call l_and - ld a,h - or l - jp nz,i_32 - ld hl,4 ;const - add hl,sp - push hl - ld hl,12 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_33 - ld hl,1 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_33 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_34 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_34 - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,6 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,6 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong -.i_32 -.i_31 -.i_28 - ld hl,10 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - call l_pint_pop - ld hl,0 ;const - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function dir_find flags 0x00000200 __smallc -; const int FRESULTdir_find(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_find - push bc - dec sp - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_35 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - -.i_35 -.i_38 - ld hl,1 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintspsp ; - ld hl,11 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,15 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_39 - ld hl,1 ;const - jp i_40 -.i_39 - ld hl,0 ;const -.i_40 - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_37 -.i_41 - ld hl,0 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_42 - ld hl,1 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint - jp i_37 -.i_42 - ld hl,5 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(8 % 256) - jp nz,i_44 - ld hl,5 ;const - call l_gintspsp ; - ld hl,9 ;const - call l_gintsp ; - inc hl - inc hl - ld e,(hl) - inc hl - ld d,(hl) - push de - ld hl,11 ;const - push hl - call _mem_cmp - pop bc - pop bc - pop bc - call l_lneg - jr c,i_45_i_44 -.i_44 - jp i_43 -.i_45_i_44 - jp i_37 -.i_43 - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop -.i_36 - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_38 -.i_37 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - - -; Function dir_read flags 0x00000200 __smallc -; const int FRESULTdir_read(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_read - ld hl,3 ;const - push hl - push bc -.i_46 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_47 - ld hl,i_1+0 - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - call l_gint ; - push hl - ld a,4 - call printf - pop bc - pop bc - pop bc - pop bc - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_48 - ld hl,1 ;const - jp i_49 -.i_48 - ld hl,0 ;const -.i_49 - pop de - pop bc - push hl - push de - ld a,h - or l - jp nz,i_47 -.i_50 - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_51 - ld hl,3 ;const - pop de - pop bc - push hl - push de - jp i_47 -.i_51 - ld hl,1 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(63 % 256) - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - add hl,sp - ld a,(hl) - cp 229 - jp z,i_53 - pop hl - push hl - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_53 - pop hl - push hl - ld l,h - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jr c,i_54_i_53 -.i_53 - jp i_52 -.i_54_i_53 - jp i_47 -.i_52 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - pop de - pop bc - push hl - push de - ld a,h - or l - jr nz,i_47 -.i_55 - jp i_46 -.i_47 - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_56 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,0 ;const - ld d,h - ld e,l - pop bc - call l_plong -.i_56 - pop bc - pop hl - ret - - - -; Function create_name flags 0x00000200 __smallc -; const int FRESULTcreate_name(struct 0__anonstruct_5 DIR*dj, const char **path) -; parameter 'const char **path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._create_name - push bc - push bc - push bc - push bc - dec sp - ld hl,13 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - pop de - pop bc - push hl - push de - ld hl,2 ;const - call l_gintspsp ; - ld hl,32 ;const - push hl - ld hl,11 ;const - push hl - call _mem_set - pop bc - pop bc - pop bc - ld hl,5 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,11 ;const - call l_gintsp ; - call l_gint ; - pop bc - push hl -.i_57 -.i_59 - ld hl,8 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp c,i_61 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,47 - and a - sbc hl,de - jr nz,i_60 -.i_61 - jp i_58 -.i_60 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr z,ASMPC+3 - ccf - jp c,i_64 - ld hl,4 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,6 ;const - add hl,sp - ld l,(hl) - ld h,0 - call l_uge - jp nc,i_63 -.i_64 - ld hl,6 ;const - add hl,sp - ld a,(hl) - cp 8 - jr z,ASMPC+3 - scf - jp c,i_67 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jr nc,i_66 -.i_67 - jp i_58 -.i_66 - ld hl,4 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,6 ;const - add hl,sp - ld (hl),+(11 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_57 -.i_63 - jp i_70 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - dec hl - pop de - ex de,hl - and a - sbc hl,de - jr c,i_71_i_70 -.i_70 - jp i_69 -.i_71_i_70 - ld hl,7 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - ex de,hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,9 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 - jp i_72 -.i_69 - jp i_74 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,97 - call l_uge - jp nc,i_75 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,122 - and a - sbc hl,de - ccf - jr c,i_76_i_75 -.i_75 - jp i_74 -.i_76_i_75 - jr i_77_i_74 -.i_74 - jp i_73 -.i_77_i_74 - ld hl,8 ;const - add hl,sp - ld a,(hl) - add a,+(-32 % 256) - ld (hl),a -.i_73 - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,10 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 -.i_72 - jp i_57 -.i_58 - ld hl,11 ;const - call l_gintspsp ; - ld hl,2 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - call l_pint_pop - pop bc - pop hl - push hl - push bc - ld bc,11 - add hl,bc - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp nc,i_78 - ld hl,1 ;const - jp i_79 -.i_78 - ld hl,0 ;const -.i_79 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - inc sp - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function get_fileinfo flags 0x00000200 __smallc -; void get_fileinfo(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._get_fileinfo - push bc - push bc - ld hl,6 ;const - call l_gintsp ; - ld bc,9 - add hl,bc - pop bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_80 - ld hl,3 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_83 -.i_81 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_83 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 8 - jp nc,i_82 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_82 -.i_84 - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 5 - jp nz,i_85 - ld hl,2 ;const - add hl,sp - ld (hl),+(229 % 256 % 256) -.i_85 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_81 -.i_82 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_86 - pop hl - ld (hl),+(46 % 256) - inc hl - push hl - ld hl,3 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_89 -.i_87 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_89 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 11 - jp nc,i_88 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_88 -.i_90 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_87 -.i_88 -.i_86 - ld hl,6 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,28 - add hl,bc - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,6 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,24 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop - ld hl,6 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop -.i_80 - pop de - push de - ld hl,0 ;const - ld a,l - ld (de),a - pop bc - pop bc - ret - - - -; Function follow_path flags 0x00000200 __smallc -; const int FRESULTfollow_path(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._follow_path - push bc -.i_91 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 32 - jp nz,i_92 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - jp i_91 -.i_92 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 47 - jp nz,i_93 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) -.i_93 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - ld hl,4 ;const - call l_gintsp ; - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp nc,i_94 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - pop bc - push hl - ld hl,6 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,0 % 256 ;const - ld a,l - ld (de),a - jp i_95 -.i_94 -.i_96 -.i_98 - ld hl,8 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _create_name - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_97 -.i_99 - ld hl,8 ;const - call l_gintspsp ; - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_find - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_97 -.i_100 - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - ld bc,11 - add hl,bc - ld l,(hl) - ld a,l - and a - jp nz,i_97 -.i_101 - ld hl,6 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(16 % 256) - jp nz,i_102 - ld hl,3 ;const - pop bc - push hl - jp i_97 -.i_102 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,8 ;const - call l_gintsp ; - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_96 -.i_97 -.i_95 - pop hl - ret - - - -; Function check_fs flags 0x00000200 __smallc -; unsigned char BYTEcheck_fs(unsigned char BYTE*buf, unsigned long sect) -; parameter 'unsigned long sect' at 2 size(4) -; parameter 'unsigned char BYTE*buf' at 6 size(2) -._check_fs - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,510 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_103 - ld hl,3 % 256 ;const - ret - - -.i_103 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,43605 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_104 - ld hl,2 % 256 ;const - ret - - -.i_104 - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,82 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - call l_lneg - jp nc,i_106 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,16710 - and a - sbc hl,de - jr z,i_107_i_106 -.i_106 - jp i_105 -.i_107_i_106 - ld hl,0 % 256 ;const - ret - - -.i_105 - ld hl,1 % 256 ;const - ret - - - -; Function pf_mount flags 0x00000200 __smallc -; const int FRESULTpf_mount(struct 0__anonstruct_4 FATFS*fs) -; parameter 'struct 0__anonstruct_4 FATFS*fs' at 2 size(2) -._pf_mount - ld hl,65483 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ld (_FatFs),hl - call _disk_initialize - ld a,l - and +(1 % 256) - jp z,i_108 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,2 ;const - ret - - -.i_108 - ld hl,12 ;const - add hl,sp - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - ld hl,52 ;const - add hl,sp - push hl - ld hl,18 ;const - add hl,sp - push hl - ld hl,16 ;const - call l_glongsp ; - call _check_fs - pop bc - pop bc - pop bc - pop de - ld a,l - ld (de),a - ld hl,52 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 1 - jp nz,i_109 - ld hl,16 ;const - add hl,sp - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,446 ;const - push hl - ld hl,16 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_110 - ld hl,52 ;const - add hl,sp - ld (hl),+(3 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_111 -.i_110 - ld hl,20 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_112 - ld hl,12 ;const - add hl,sp - push hl - ld hl,26 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,52 ;const - add hl,sp - push hl - ld hl,18 ;const - add hl,sp - push hl - ld hl,16 ;const - call l_glongsp ; - call _check_fs - pop bc - pop bc - pop bc - pop de - ld a,l - ld (de),a -.i_112 -.i_111 -.i_109 - ld hl,52 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 3 - jp nz,i_113 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_113 - ld hl,52 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_114 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,6 ;const - ret - - -.i_114 - ld hl,16 ;const - add hl,sp - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,13 ;const - push hl - ld hl,36 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_115 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_115 - ld hl,8 ;const - add hl,sp - push hl - ld hl,27 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,8 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_116 - ld hl,8 ;const - add hl,sp - push hl - ld hl,41 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong -.i_116 - ld hl,8 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,25 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_mult - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,10 - add hl,bc - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,23 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - inc hl - inc hl - ex de,hl - ld hl,16 ;const - add hl,sp - ld a,(hl) - ld (de),a - ld hl,55 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,22 ;const - add hl,sp - push hl - call _ld_word - pop bc - call l_pint_pop - ld hl,4 ;const - add hl,sp - push hl - ld hl,24 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_117 - ld hl,4 ;const - add hl,sp - push hl - ld hl,37 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong -.i_117 - ld hl,0 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - call l_glong2sp - ld hl,23 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - call l_long_sub - push de - push hl - ld hl,14 ;const - add hl,sp - call l_glong - call l_long_sub - push de - push hl - ld hl,61 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_gint ; - ld de,4 - call l_asr_u_hl_by_e - ld de,0 - call l_long_sub - push de - push hl - ld hl,61 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - call l_long_div_u - ld bc,2 - add hl,bc - jr nc,ASMPC+3 - inc de - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - push hl - ld hl,2 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,52 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld hl,0 ;const - add hl,sp - call l_glong2sp - ld hl,65527 ;const - ld de,0 - call l_long_uge - jp nc,i_118 - ld hl,52 ;const - add hl,sp - ld (hl),+(3 % 256 % 256) -.i_118 - ld hl,52 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_119 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,6 ;const - ret - - -.i_119 - ld hl,55 ;const - call l_gintspsp ; - ld hl,54 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld hl,55 ;const - call l_gintsp ; - ld bc,14 - add hl,bc - push hl - ld hl,49 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,18 - add hl,bc - push hl - ld hl,57 ;const - call l_gintsp ; - ld bc,10 - add hl,bc - call l_glong2sp - ld hl,14 ;const - add hl,sp - call l_glong - call l_long_add - push de - push hl - ld hl,61 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_gint ; - ld de,4 - call l_asr_u_hl_by_e - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,55 ;const - call l_gintsp ; - ld (_FatFs),hl - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_open flags 0x00000200 __smallc -; const int FRESULTpf_open(const char *path) -; parameter 'const char *path' at 2 size(2) -._pf_open - ld hl,65474 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_120 - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_120 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,48 ;const - add hl,sp - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,62 ;const - add hl,sp - push hl - ld hl,48 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - push hl - ld hl,72 ;const - call l_gintsp ; - push hl - call _follow_path - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,62 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_121 - ld hl,62 ;const - call l_gintsp ; - exx - ld hl,64 ;const - add hl,sp - ld sp,hl - exx - ret - - -.i_121 - ld hl,2 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_123 - ld hl,13 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_122 -.i_123 - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,3 ;const - ret - - -.i_122 - pop hl - push hl - ld bc,30 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - push hl - call _get_clust - pop bc - pop bc - call l_plong - pop hl - push hl - ld bc,26 - add hl,bc - push hl - ld hl,32 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - pop hl - push hl - ld bc,22 - add hl,bc - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - inc hl - ld (hl),+(1 % 256 % 256) - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_read flags 0x00000200 __smallc -; const int FRESULTpf_read(void *buff, unsigned int btr, unsigned int UINT*br) -; parameter 'unsigned int UINT*br' at 2 size(2) -; parameter 'unsigned int btr' at 4 size(2) -; parameter 'void *buff' at 6 size(2) -._pf_read - ld hl,65519 ;const - add hl,sp - ld sp,hl - ld hl,23 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - push de - ld hl,(_FatFs) - push hl - ld hl,23 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - call l_lneg - jp nc,i_125 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_125 - pop hl - push hl - inc hl - ld a,(hl) - and +(1 % 256) - jp nz,i_126 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,4 ;const - ret - - -.i_126 - ld hl,7 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,26 - add hl,bc - call l_glong2sp - ld hl,6 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_glong - call l_long_sub - pop bc - call l_plong - ld hl,25 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - call l_glong - exx - pop hl - ld de,0 - push de - push hl - exx - call l_long_ugt - jp nc,i_127 - ld hl,25 ;const - add hl,sp - push hl - ld hl,9 ;const - add hl,sp - call l_glong - call l_pint_pop -.i_127 -.i_128 - ld hl,25 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_129 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - exx - ld a,d - or e - or h - or l - jp nz,i_130 - ld hl,4 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - push de - push hl - ld hl,6 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - ld de,0 - call l_long_and - pop de - ld a,l - ld (de),a - ld hl,4 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_131 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_132 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,30 - add hl,bc - call l_glong - pop bc - call l_plong - jp i_133 -.i_132 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong -.i_133 - ld hl,15 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_134 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_134 - pop hl - push hl - ld bc,34 - add hl,bc - push hl - ld hl,17 ;const - add hl,sp - call l_glong - pop bc - call l_plong -.i_131 - ld hl,11 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,11 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_135 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_135 - pop hl - push hl - ld bc,38 - add hl,bc - push hl - ld hl,13 ;const - add hl,sp - call l_glong2sp - ld hl,10 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_add - pop bc - call l_plong -.i_130 - ld hl,5 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ld hl,512 - and a - sbc hl,de - call l_pint_pop - ld hl,5 ;const - call l_gintspsp ; - ld hl,27 ;const - call l_gintsp ; - pop de - and a - sbc hl,de - jp nc,i_136 - ld hl,5 ;const - add hl,sp - ex de,hl - ld hl,25 ;const - call l_gintsp ; - call l_pint -.i_136 - ld hl,19 ;const - add hl,sp - push hl - ld hl,4 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - ld bc,38 - add hl,bc - call l_glong2sp - ld hl,8 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - push hl - ld hl,15 ;const - call l_gintsp ; - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,19 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_137 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_137 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,11 ;const - call l_gintsp ; - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,25 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - call l_gint - ex de,hl - and a - sbc hl,de - call l_pint_pop - ld hl,23 ;const - call l_gintsp ; - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_138 - ld hl,2 ;const - call l_gintspsp ; - ld hl,7 ;const - call l_gintsp ; - pop de - add hl,de - pop de - pop bc - push hl - push de -.i_138 - jp i_128 -.i_129 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_write flags 0x00000200 __smallc -; const int FRESULTpf_write(const void *buff, unsigned int btw, unsigned int UINT*bw) -; parameter 'unsigned int UINT*bw' at 2 size(2) -; parameter 'unsigned int btw' at 4 size(2) -; parameter 'const void *buff' at 6 size(2) -._pf_write - ld hl,65524 ;const - add hl,sp - ld sp,hl - ld hl,18 ;const - call l_gintsp ; - push hl - push bc - dec sp - ld hl,(_FatFs) - push hl - ld hl,21 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - call l_lneg - jp nc,i_139 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_139 - pop hl - push hl - inc hl - ld a,(hl) - and +(1 % 256) - jp nz,i_140 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,4 ;const - ret - - -.i_140 - ld hl,23 ;const - call l_gintsp ; - call l_lneg - jp nc,i_141 - pop hl - push hl - inc hl - ld a,+(64 % 256) - and (hl) - jp z,i_143 - ld hl,0 ;const - push hl - ld d,h - ld e,l - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jr nz,i_144_i_143 -.i_143 - jp i_142 -.i_144_i_143 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_142 - pop hl - push hl - inc hl - push hl - ld a,(hl) - and 191 - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - -.i_141 - pop hl - push hl - inc hl - ld a,(hl) - and +(64 % 256) - jp nz,i_146 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,65024 ;const - ld de,65535 - call l_long_and - pop bc - call l_plong -.i_146 -.i_145 - ld hl,7 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,26 - add hl,bc - call l_glong2sp - ld hl,6 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_glong - call l_long_sub - pop bc - call l_plong - ld hl,23 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - call l_glong - exx - pop hl - ld de,0 - push de - push hl - exx - call l_long_ugt - jp nc,i_147 - ld hl,23 ;const - add hl,sp - push hl - ld hl,9 ;const - add hl,sp - call l_glong - call l_pint_pop -.i_147 -.i_148 - ld hl,23 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_149 - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - ld a,h - or l - jp nz,i_150 - ld hl,4 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - push de - push hl - ld hl,6 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - ld de,0 - call l_long_and - pop de - ld a,l - ld (de),a - ld hl,4 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_151 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_152 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,30 - add hl,bc - call l_glong - pop bc - call l_plong - jp i_153 -.i_152 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong -.i_153 - ld hl,15 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_154 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_154 - pop hl - push hl - ld bc,34 - add hl,bc - push hl - ld hl,17 ;const - add hl,sp - call l_glong - pop bc - call l_plong -.i_151 - ld hl,11 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,11 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_155 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_155 - pop hl - push hl - ld bc,38 - add hl,bc - push hl - ld hl,13 ;const - add hl,sp - call l_glong2sp - ld hl,10 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_add - pop bc - call l_plong - pop hl - push hl - ld bc,0 - push bc - ld bc,38 - add hl,bc - call l_glong - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_156 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_156 - pop hl - push hl - inc hl - ld a,(hl) - or 64 - ld (hl),a -.i_150 - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ld hl,512 - and a - sbc hl,de - pop de - pop bc - push hl - push de - ld hl,2 ;const - call l_gintspsp ; - ld hl,25 ;const - call l_gintsp ; - pop de - and a - sbc hl,de - jp nc,i_157 - ld hl,23 ;const - call l_gintsp ; - pop de - pop bc - push hl - push de -.i_157 - ld hl,5 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - ld de,0 - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_158 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_158 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,8 ;const - call l_gintsp ; - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,5 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - ld hl,23 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - ex de,hl - and a - sbc hl,de - call l_pint_pop - ld hl,21 ;const - call l_gintsp ; - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - ld a,h - or l - jp nz,i_159 - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_160 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_160 - pop hl - push hl - inc hl - push hl - ld a,(hl) - and 191 - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a -.i_159 - jp i_148 -.i_149 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_opendir flags 0x00000200 __smallc -; const int FRESULTpf_opendir(struct 0__anonstruct_5 DIR*dj, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_opendir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_161 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_162 -.i_161 - ld hl,i_1+33 - push hl - ld a,1 - call printf - pop bc - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - ld hl,56 ;const - call l_gintsp ; - push hl - call _follow_path - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,i_1+42 - push hl - ld hl,48 ;const - call l_gintsp ; - push hl - ld a,2 - call printf - pop bc - pop bc - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_163 - ld hl,2 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_164 - ld hl,i_1+55 - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld a,2 - call printf - pop bc - pop bc - ld hl,13 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_165 - ld hl,52 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_166 -.i_165 - ld hl,46 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint -.i_166 -.i_164 - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_167 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop -.i_167 -.i_163 -.i_162 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - -; Function pf_readdir flags 0x00000200 __smallc -; const int FRESULTpf_readdir(struct 0__anonstruct_5 DIR*dj, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_readdir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_168 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_169 -.i_168 - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,50 ;const - call l_gintsp ; - call l_lneg - jp nc,i_170 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - jp i_171 -.i_170 - ld hl,i_1+70 - push hl - ld a,1 - call printf - pop bc - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _dir_read - pop bc - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_172 - ld hl,52 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _get_fileinfo - pop bc - pop bc - pop bc - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld de,3 - and a - sbc hl,de - jp nz,i_173 - ld hl,46 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_173 -.i_172 -.i_171 -.i_169 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - SECTION rodata_compiler -.i_1 - defm "dir_read: sector:%ld, index:%l" - defm "d" - defb 10 - - defm "" - defb 0 - - defm "OPENDIR" - defb 10 - - defm "" - defb 0 - - defm "RESDIR:%02x" - defb 10 - - defm "" - defb 0 - - defm "IS A DIR:%02x" - defb 10 - - defm "" - defb 0 - - defm "Readdir" - defb 10 - - defm "" - defb 0 - - -; --- Start of Static Variables --- - - SECTION bss_compiler -._FatFs defs 2 - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/new.err b/software/src/PetitFS/pff_obj/new.err deleted file mode 100644 index 958118e..0000000 --- a/software/src/PetitFS/pff_obj/new.err +++ /dev/null @@ -1,592 +0,0 @@ -Error at file 'new.asm' line 13: cannot read file 'z80_crt0.hdr' -Error at file 'new.asm' line 858: cannot read file 'z80_crt0.hdr' -Error at file 'new.asm' line 951: symbol 'i_5' already defined -Error at file 'new.asm' line 959: symbol 'i_3' already defined -Error at file 'new.asm' line 973: symbol 'i_4' already defined -Error at file 'new.asm' line 1030: symbol 'i_7' already defined -Error at file 'new.asm' line 1031: symbol 'i_6' already defined -Error at file 'new.asm' line 1089: symbol 'i_8' already defined -Error at file 'new.asm' line 1100: symbol 'i_9' already defined -Error at file 'new.asm' line 1111: symbol 'i_12' already defined -Error at file 'new.asm' line 1132: symbol 'i_13' already defined -Error at file 'new.asm' line 1136: symbol 'i_11' already defined -Error at file 'new.asm' line 1194: symbol 'i_17' already defined -Error at file 'new.asm' line 1218: symbol 'i_18' already defined -Error at file 'new.asm' line 1233: symbol 'i_21' already defined -Error at file 'new.asm' line 1240: symbol 'i_23' already defined -Error at file 'new.asm' line 1245: symbol 'i_25' already defined -Error at file 'new.asm' line 1264: symbol 'i_26' already defined -Error at file 'new.asm' line 1268: symbol 'i_24' already defined -Error at file 'new.asm' line 1288: symbol 'i_28' already defined -Error at file 'new.asm' line 1301: symbol 'i_32' already defined -Error at file 'new.asm' line 1321: symbol 'i_31' already defined -Error at file 'new.asm' line 1332: symbol 'i_33' already defined -Error at file 'new.asm' line 1334: symbol 'i_34' already defined -Error at file 'new.asm' line 1338: symbol 'i_27' already defined -Error at file 'new.asm' line 1339: symbol 'i_20' already defined -Error at file 'new.asm' line 1341: symbol 'i_16' already defined -Error at file 'new.asm' line 1440: symbol 'i_35' already defined -Error at file 'new.asm' line 1441: symbol 'i_15' already defined -Error at file 'new.asm' line 1898: symbol 'i_1' already defined -Error at file 'new.asm' line 2112: cannot read file 'z80_crt0.hdr' -Error at file 'new.asm' line 2254: symbol 'i_2' already defined -Error at file 'new.asm' line 2284: symbol 'i_3' already defined -Error at file 'new.asm' line 2300: symbol 'i_4' already defined -Error at file 'new.asm' line 2349: symbol 'i_6' already defined -Error at file 'new.asm' line 2351: symbol 'i_7' already defined -Error at file 'new.asm' line 2355: symbol 'i_5' already defined -Error at file 'new.asm' line 2393: symbol 'i_9' already defined -Error at file 'new.asm' line 2402: symbol 'i_8' already defined -Error at file 'new.asm' line 2407: symbol 'i_13' already defined -Error at file 'new.asm' line 2411: symbol 'i_14' already defined -Error at file 'new.asm' line 2450: symbol 'i_15' already defined -Error at file 'new.asm' line 2465: symbol 'i_12' already defined -Error at file 'new.asm' line 2512: symbol 'i_16' already defined -Error at file 'new.asm' line 2640: symbol 'i_18' already defined -Error at file 'new.asm' line 2648: symbol 'i_17' already defined -Error at file 'new.asm' line 2665: symbol 'i_20' already defined -Error at file 'new.asm' line 2692: symbol 'i_21' already defined -Error at file 'new.asm' line 2694: symbol 'i_22' already defined -Error at file 'new.asm' line 2702: symbol 'i_23' already defined -Error at file 'new.asm' line 2710: symbol 'i_24' already defined -Error at file 'new.asm' line 2759: symbol 'i_26' already defined -Error at file 'new.asm' line 2768: symbol 'i_25' already defined -Error at file 'new.asm' line 2815: symbol 'i_30' already defined -Error at file 'new.asm' line 2817: symbol 'i_29' already defined -Error at file 'new.asm' line 2868: symbol 'i_33' already defined -Error at file 'new.asm' line 2887: symbol 'i_34' already defined -Error at file 'new.asm' line 2910: symbol 'i_32' already defined -Error at file 'new.asm' line 2911: symbol 'i_31' already defined -Error at file 'new.asm' line 2912: symbol 'i_28' already defined -Error at file 'new.asm' line 2955: symbol 'i_35' already defined -Error at file 'new.asm' line 2956: symbol 'i_38' already defined -Error at file 'new.asm' line 2992: symbol 'i_39' already defined -Error at file 'new.asm' line 2994: symbol 'i_40' already defined -Error at file 'new.asm' line 3001: symbol 'i_41' already defined -Error at file 'new.asm' line 3022: symbol 'i_42' already defined -Error at file 'new.asm' line 3052: symbol 'i_43' already defined -Error at file 'new.asm' line 3062: symbol 'i_36' already defined -Error at file 'new.asm' line 3068: symbol 'i_37' already defined -Error at file 'new.asm' line 3085: symbol 'i_46' already defined -Error at file 'new.asm' line 3145: symbol 'i_48' already defined -Error at file 'new.asm' line 3147: symbol 'i_49' already defined -Error at file 'new.asm' line 3155: symbol 'i_50' already defined -Error at file 'new.asm' line 3176: symbol 'i_51' already defined -Error at file 'new.asm' line 3219: symbol 'i_52' already defined -Error at file 'new.asm' line 3232: symbol 'i_55' already defined -Error at file 'new.asm' line 3234: symbol 'i_47' already defined -Error at file 'new.asm' line 3252: symbol 'i_56' already defined -Error at file 'new.asm' line 3305: symbol 'i_57' already defined -Error at file 'new.asm' line 3306: symbol 'i_59' already defined -Error at file 'new.asm' line 3340: symbol 'i_61' already defined -Error at file 'new.asm' line 3342: symbol 'i_60' already defined -Error at file 'new.asm' line 3364: symbol 'i_64' already defined -Error at file 'new.asm' line 3383: symbol 'i_67' already defined -Error at file 'new.asm' line 3385: symbol 'i_66' already defined -Error at file 'new.asm' line 3395: symbol 'i_63' already defined -Error at file 'new.asm' line 3412: symbol 'i_70' already defined -Error at file 'new.asm' line 3465: symbol 'i_69' already defined -Error at file 'new.asm' line 3483: symbol 'i_75' already defined -Error at file 'new.asm' line 3487: symbol 'i_74' already defined -Error at file 'new.asm' line 3495: symbol 'i_73' already defined -Error at file 'new.asm' line 3514: symbol 'i_72' already defined -Error at file 'new.asm' line 3516: symbol 'i_58' already defined -Error at file 'new.asm' line 3548: symbol 'i_78' already defined -Error at file 'new.asm' line 3550: symbol 'i_79' already defined -Error at file 'new.asm' line 3656: symbol 'i_82' already defined -Error at file 'new.asm' line 3782: symbol 'i_80' already defined -Error at file 'new.asm' line 5748: symbol 'i_1' already defined -Error at file 'new.asm' line 25: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 62: symbol 'l_pint' not defined -Error at file 'new.asm' line 64: symbol 'l_lneg' not defined -Error at file 'new.asm' line 79: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 81: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 91: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 126: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 128: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 138: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 141: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 144: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 147: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 150: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 153: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 155: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 179: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 181: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 186: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 210: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 212: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 217: symbol 'l_gcharsp' not defined -Error at file 'new.asm' line 218: symbol 'l_lneg' not defined -Error at file 'new.asm' line 243: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 257: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 262: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 279: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 281: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 286: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 312: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 314: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 319: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 320: symbol 'l_lneg' not defined -Error at file 'new.asm' line 329: symbol 'l_pint' not defined -Error at file 'new.asm' line 341: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 343: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 353: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 366: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 371: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 390: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 392: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 397: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 423: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 425: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 430: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 431: symbol 'l_lneg' not defined -Error at file 'new.asm' line 439: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 444: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 467: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 469: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 474: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1073: symbol 'l_glong' not defined -Error at file 'new.asm' line 1418: symbol 'l_lneg' not defined -Error at file 'new.asm' line 1490: symbol 'l_lneg' not defined -Error at file 'new.asm' line 1495: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 1498: symbol 'l_long_mult' not defined -Error at file 'new.asm' line 1500: symbol 'l_plong' not defined -Error at file 'new.asm' line 1510: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 1567: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1576: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1581: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1587: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1667: symbol 'l_pint' not defined -Error at file 'new.asm' line 1675: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1702: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 1708: symbol 'l_glong' not defined -Error at file 'new.asm' line 1758: symbol 'l_pint' not defined -Error at file 'new.asm' line 1763: symbol 'l_glong' not defined -Error at file 'new.asm' line 1774: symbol 'l_lneg' not defined -Error at file 'new.asm' line 1779: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 1782: symbol 'l_long_mult' not defined -Error at file 'new.asm' line 1784: symbol 'l_plong' not defined -Error at file 'new.asm' line 1789: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 1811: symbol 'l_pint' not defined -Error at file 'new.asm' line 1880: symbol 'l_pint' not defined -Error at file 'new.asm' line 1890: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2123: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2133: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2155: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2163: symbol 'l_plong' not defined -Error at file 'new.asm' line 2177: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2188: symbol 'l_plong' not defined -Error at file 'new.asm' line 2202: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2212: symbol 'l_plong' not defined -Error at file 'new.asm' line 2226: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2235: symbol 'l_plong' not defined -Error at file 'new.asm' line 2238: symbol 'l_glong' not defined -Error at file 'new.asm' line 2252: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2275: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2277: symbol 'l_sxt' not defined -Error at file 'new.asm' line 2279: symbol 'l_sxt' not defined -Error at file 'new.asm' line 2297: symbol 'l_g2intspsp' not defined -Error at file 'new.asm' line 2325: symbol 'l_gchar' not defined -Error at file 'new.asm' line 2337: symbol 'l_gchar' not defined -Error at file 'new.asm' line 2348: integer '-2385' out of range -Error at file 'new.asm' line 2373: symbol 'l_glong' not defined -Error at file 'new.asm' line 2385: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2387: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2390: symbol 'l_glong' not defined -Error at file 'new.asm' line 2391: symbol 'l_long_uge' not defined -Error at file 'new.asm' line 2417: symbol 'l_gint' not defined -Error at file 'new.asm' line 2420: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2423: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2425: symbol 'l_long_asr_u' not defined -Error at file 'new.asm' line 2426: symbol 'l_long_add' not defined -Error at file 'new.asm' line 2431: symbol 'l_glong' not defined -Error at file 'new.asm' line 2484: symbol 'l_glong' not defined -Error at file 'new.asm' line 2490: symbol 'l_plong' not defined -Error at file 'new.asm' line 2493: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2495: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2498: symbol 'l_glong' not defined -Error at file 'new.asm' line 2503: symbol 'l_long_uge' not defined -Error at file 'new.asm' line 2515: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2517: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2523: symbol 'l_long_mult' not defined -Error at file 'new.asm' line 2527: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2530: symbol 'l_glong' not defined -Error at file 'new.asm' line 2531: symbol 'l_long_add' not defined -Error at file 'new.asm' line 2552: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2560: symbol 'l_plong' not defined -Error at file 'new.asm' line 2564: symbol 'l_glong' not defined -Error at file 'new.asm' line 2568: symbol 'l_plong' not defined -Error at file 'new.asm' line 2572: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2574: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2581: symbol 'l_or' not defined -Error at file 'new.asm' line 2584: symbol 'l_plong' not defined -Error at file 'new.asm' line 2587: symbol 'l_glong' not defined -Error at file 'new.asm' line 2617: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2620: symbol 'l_glong' not defined -Error at file 'new.asm' line 2622: symbol 'l_plong' not defined -Error at file 'new.asm' line 2625: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2628: symbol 'l_long_eq' not defined -Error at file 'new.asm' line 2632: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2634: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2637: symbol 'l_glong' not defined -Error at file 'new.asm' line 2638: symbol 'l_long_uge' not defined -Error at file 'new.asm' line 2651: symbol 'l_glong' not defined -Error at file 'new.asm' line 2652: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 2659: symbol 'l_gint' not defined -Error at file 'new.asm' line 2662: symbol 'l_glong' not defined -Error at file 'new.asm' line 2664: symbol 'l_plong' not defined -Error at file 'new.asm' line 2667: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2673: symbol 'l_glong' not defined -Error at file 'new.asm' line 2675: symbol 'l_plong' not defined -Error at file 'new.asm' line 2677: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2684: symbol 'l_glong' not defined -Error at file 'new.asm' line 2691: integer '-2689' out of range -Error at file 'new.asm' line 2697: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 2709: symbol 'l_glong' not defined -Error at file 'new.asm' line 2712: symbol 'l_plong' not defined -Error at file 'new.asm' line 2714: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2719: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 2724: symbol 'l_plong' not defined -Error at file 'new.asm' line 2743: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2744: symbol 'l_gint' not defined -Error at file 'new.asm' line 2750: symbol 'l_lneg' not defined -Error at file 'new.asm' line 2753: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2756: symbol 'l_glong' not defined -Error at file 'new.asm' line 2757: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 2777: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2781: symbol 'l_glong' not defined -Error at file 'new.asm' line 2782: symbol 'l_inclong' not defined -Error at file 'new.asm' line 2784: symbol 'l_plong' not defined -Error at file 'new.asm' line 2786: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2789: symbol 'l_glong' not defined -Error at file 'new.asm' line 2796: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 2803: symbol 'l_gint' not defined -Error at file 'new.asm' line 2805: symbol 'l_uge' not defined -Error at file 'new.asm' line 2823: symbol 'l_asr_u_hl_by_e' not defined -Error at file 'new.asm' line 2834: symbol 'l_and' not defined -Error at file 'new.asm' line 2842: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2845: symbol 'l_glong' not defined -Error at file 'new.asm' line 2852: symbol 'l_plong' not defined -Error at file 'new.asm' line 2855: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2858: symbol 'l_long_ule' not defined -Error at file 'new.asm' line 2871: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2873: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2876: symbol 'l_glong' not defined -Error at file 'new.asm' line 2877: symbol 'l_long_uge' not defined -Error at file 'new.asm' line 2889: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2895: symbol 'l_glong' not defined -Error at file 'new.asm' line 2897: symbol 'l_plong' not defined -Error at file 'new.asm' line 2899: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2904: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 2909: symbol 'l_plong' not defined -Error at file 'new.asm' line 2914: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 2916: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2917: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 2938: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2942: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 2944: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2949: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2961: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 2963: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2966: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 2968: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 2995: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 2997: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3006: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3020: symbol 'l_pint' not defined -Error at file 'new.asm' line 3024: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3031: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3033: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3046: symbol 'l_lneg' not defined -Error at file 'new.asm' line 3057: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3061: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 3064: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3070: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3087: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3090: symbol 'l_glong' not defined -Error at file 'new.asm' line 3099: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3102: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 3104: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3105: symbol 'l_gint' not defined -Error at file 'new.asm' line 3114: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3116: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3119: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 3121: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3160: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3181: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3213: symbol 'l_lneg' not defined -Error at file 'new.asm' line 3221: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3231: integer '-2386' out of range -Error at file 'new.asm' line 3243: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3251: symbol 'l_plong' not defined -Error at file 'new.asm' line 3270: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3273: symbol 'l_gint' not defined -Error at file 'new.asm' line 3279: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3301: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3302: symbol 'l_gint' not defined -Error at file 'new.asm' line 3311: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3339: integer '-2313' out of range -Error at file 'new.asm' line 3362: symbol 'l_uge' not defined -Error at file 'new.asm' line 3382: integer '-2251' out of range -Error at file 'new.asm' line 3419: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3432: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3447: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3472: symbol 'l_uge' not defined -Error at file 'new.asm' line 3497: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3518: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3529: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 3573: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3579: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3582: symbol 'l_glong' not defined -Error at file 'new.asm' line 3658: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3734: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3739: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3746: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3748: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3755: symbol 'l_plong' not defined -Error at file 'new.asm' line 3757: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3762: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3768: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 3770: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3775: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3781: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 3803: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3820: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3833: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3845: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3853: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3872: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3886: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3888: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3900: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3903: symbol 'l_gint' not defined -Error at file 'new.asm' line 3912: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3924: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3929: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3934: symbol 'l_plong' not defined -Error at file 'new.asm' line 3949: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3952: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 3972: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 3989: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 3992: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4003: symbol 'l_lneg' not defined -Error at file 'new.asm' line 4006: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4065: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 4085: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4120: symbol 'l_plong' not defined -Error at file 'new.asm' line 4128: symbol 'l_glongsp' not defined -Error at file 'new.asm' line 4172: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4204: symbol 'l_plong' not defined -Error at file 'new.asm' line 4207: symbol 'l_glong' not defined -Error at file 'new.asm' line 4208: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 4219: symbol 'l_plong' not defined -Error at file 'new.asm' line 4224: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4230: symbol 'l_long_mult' not defined -Error at file 'new.asm' line 4232: symbol 'l_plong' not defined -Error at file 'new.asm' line 4234: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4240: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4247: symbol 'l_long_add' not defined -Error at file 'new.asm' line 4249: symbol 'l_plong' not defined -Error at file 'new.asm' line 4251: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4260: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4269: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4280: symbol 'l_plong' not defined -Error at file 'new.asm' line 4283: symbol 'l_glong' not defined -Error at file 'new.asm' line 4284: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 4295: symbol 'l_plong' not defined -Error at file 'new.asm' line 4302: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4309: symbol 'l_long_sub' not defined -Error at file 'new.asm' line 4314: symbol 'l_glong' not defined -Error at file 'new.asm' line 4315: symbol 'l_long_sub' not defined -Error at file 'new.asm' line 4319: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4322: symbol 'l_gint' not defined -Error at file 'new.asm' line 4324: symbol 'l_asr_u_hl_by_e' not defined -Error at file 'new.asm' line 4326: symbol 'l_long_sub' not defined -Error at file 'new.asm' line 4330: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4336: symbol 'l_long_div_u' not defined -Error at file 'new.asm' line 4342: symbol 'l_plong' not defined -Error at file 'new.asm' line 4344: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4350: symbol 'l_glong' not defined -Error at file 'new.asm' line 4352: symbol 'l_plong' not defined -Error at file 'new.asm' line 4358: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4361: symbol 'l_long_uge' not defined -Error at file 'new.asm' line 4381: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 4388: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4398: symbol 'l_plong' not defined -Error at file 'new.asm' line 4400: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4405: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4408: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4411: symbol 'l_glong' not defined -Error at file 'new.asm' line 4412: symbol 'l_long_add' not defined -Error at file 'new.asm' line 4416: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4419: symbol 'l_gint' not defined -Error at file 'new.asm' line 4421: symbol 'l_asr_u_hl_by_e' not defined -Error at file 'new.asm' line 4423: symbol 'l_long_add' not defined -Error at file 'new.asm' line 4425: symbol 'l_plong' not defined -Error at file 'new.asm' line 4427: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4431: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4450: symbol 'l_lneg' not defined -Error at file 'new.asm' line 4469: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4480: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4486: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4488: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4493: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4533: symbol 'l_plong' not defined -Error at file 'new.asm' line 4545: symbol 'l_plong' not defined -Error at file 'new.asm' line 4599: symbol 'l_lneg' not defined -Error at file 'new.asm' line 4631: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4633: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4636: symbol 'l_glong' not defined -Error at file 'new.asm' line 4637: symbol 'l_long_sub' not defined -Error at file 'new.asm' line 4639: symbol 'l_plong' not defined -Error at file 'new.asm' line 4641: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 4644: symbol 'l_glong' not defined -Error at file 'new.asm' line 4651: symbol 'l_long_ugt' not defined -Error at file 'new.asm' line 4658: symbol 'l_glong' not defined -Error at file 'new.asm' line 4659: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4663: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4671: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4674: symbol 'l_long_div_u' not defined -Error at file 'new.asm' line 4689: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4692: symbol 'l_long_div_u' not defined -Error at file 'new.asm' line 4696: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4703: symbol 'l_long_and' not defined -Error at file 'new.asm' line 4716: symbol 'l_glong' not defined -Error at file 'new.asm' line 4730: symbol 'l_glong' not defined -Error at file 'new.asm' line 4732: symbol 'l_plong' not defined -Error at file 'new.asm' line 4743: symbol 'l_glong' not defined -Error at file 'new.asm' line 4750: symbol 'l_plong' not defined -Error at file 'new.asm' line 4754: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4757: symbol 'l_long_ule' not defined -Error at file 'new.asm' line 4778: symbol 'l_glong' not defined -Error at file 'new.asm' line 4780: symbol 'l_plong' not defined -Error at file 'new.asm' line 4790: symbol 'l_glong' not defined -Error at file 'new.asm' line 4797: symbol 'l_plong' not defined -Error at file 'new.asm' line 4800: symbol 'l_glong' not defined -Error at file 'new.asm' line 4801: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 4822: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4828: symbol 'l_long_add' not defined -Error at file 'new.asm' line 4830: symbol 'l_plong' not defined -Error at file 'new.asm' line 4840: symbol 'l_gint' not defined -Error at file 'new.asm' line 4843: symbol 'l_div_u' not defined -Error at file 'new.asm' line 4847: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4849: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 4851: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4860: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4861: symbol 'l_pint' not defined -Error at file 'new.asm' line 4867: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 4869: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4872: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4874: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4877: symbol 'l_gint' not defined -Error at file 'new.asm' line 4880: symbol 'l_div_u' not defined -Error at file 'new.asm' line 4884: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4892: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4894: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4915: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 4917: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4919: symbol 'l_long_add' not defined -Error at file 'new.asm' line 4921: symbol 'l_plong' not defined -Error at file 'new.asm' line 4930: symbol 'l_gint' not defined -Error at file 'new.asm' line 4934: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4936: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4943: symbol 'l_gint' not defined -Error at file 'new.asm' line 4945: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 4954: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 4956: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 4984: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5002: symbol 'l_lneg' not defined -Error at file 'new.asm' line 5027: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5028: symbol 'l_lneg' not defined -Error at file 'new.asm' line 5094: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5097: symbol 'l_long_and' not defined -Error at file 'new.asm' line 5099: symbol 'l_plong' not defined -Error at file 'new.asm' line 5110: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5112: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5115: symbol 'l_glong' not defined -Error at file 'new.asm' line 5116: symbol 'l_long_sub' not defined -Error at file 'new.asm' line 5118: symbol 'l_plong' not defined -Error at file 'new.asm' line 5120: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5123: symbol 'l_glong' not defined -Error at file 'new.asm' line 5130: symbol 'l_long_ugt' not defined -Error at file 'new.asm' line 5137: symbol 'l_glong' not defined -Error at file 'new.asm' line 5138: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5142: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5150: symbol 'l_gint' not defined -Error at file 'new.asm' line 5153: symbol 'l_div_u' not defined -Error at file 'new.asm' line 5166: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5169: symbol 'l_long_div_u' not defined -Error at file 'new.asm' line 5173: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5180: symbol 'l_long_and' not defined -Error at file 'new.asm' line 5193: symbol 'l_glong' not defined -Error at file 'new.asm' line 5207: symbol 'l_glong' not defined -Error at file 'new.asm' line 5209: symbol 'l_plong' not defined -Error at file 'new.asm' line 5220: symbol 'l_glong' not defined -Error at file 'new.asm' line 5227: symbol 'l_plong' not defined -Error at file 'new.asm' line 5231: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5234: symbol 'l_long_ule' not defined -Error at file 'new.asm' line 5255: symbol 'l_glong' not defined -Error at file 'new.asm' line 5257: symbol 'l_plong' not defined -Error at file 'new.asm' line 5267: symbol 'l_glong' not defined -Error at file 'new.asm' line 5274: symbol 'l_plong' not defined -Error at file 'new.asm' line 5277: symbol 'l_glong' not defined -Error at file 'new.asm' line 5278: symbol 'l_long_lneg' not defined -Error at file 'new.asm' line 5299: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5305: symbol 'l_long_add' not defined -Error at file 'new.asm' line 5307: symbol 'l_plong' not defined -Error at file 'new.asm' line 5314: symbol 'l_glong' not defined -Error at file 'new.asm' line 5347: symbol 'l_gint' not defined -Error at file 'new.asm' line 5350: symbol 'l_div_u' not defined -Error at file 'new.asm' line 5359: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5361: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5367: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5374: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5376: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5404: symbol 'l_glong2sp' not defined -Error at file 'new.asm' line 5406: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5408: symbol 'l_long_add' not defined -Error at file 'new.asm' line 5410: symbol 'l_plong' not defined -Error at file 'new.asm' line 5419: symbol 'l_gint' not defined -Error at file 'new.asm' line 5421: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5430: symbol 'l_gint' not defined -Error at file 'new.asm' line 5434: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5436: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5443: symbol 'l_gint' not defined -Error at file 'new.asm' line 5445: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5450: symbol 'l_gint' not defined -Error at file 'new.asm' line 5453: symbol 'l_div_u' not defined -Error at file 'new.asm' line 5515: symbol 'l_lneg' not defined -Error at file 'new.asm' line 5521: symbol 'l_pint' not defined -Error at file 'new.asm' line 5530: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5536: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5541: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5546: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5552: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5556: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5563: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5589: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5599: symbol 'l_plong' not defined -Error at file 'new.asm' line 5606: symbol 'l_pint' not defined -Error at file 'new.asm' line 5610: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5618: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5622: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5627: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5647: symbol 'l_lneg' not defined -Error at file 'new.asm' line 5653: symbol 'l_pint' not defined -Error at file 'new.asm' line 5657: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5663: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5665: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5666: symbol 'l_lneg' not defined -Error at file 'new.asm' line 5672: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5676: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5688: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5695: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5697: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5702: symbol 'l_gintspsp' not defined -Error at file 'new.asm' line 5707: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5717: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5721: symbol 'l_pint_pop' not defined -Error at file 'new.asm' line 5723: symbol 'l_gintsp' not defined -Error at file 'new.asm' line 5732: symbol 'l_pint' not defined -Error at file 'new.asm' line 5738: symbol 'l_gintsp' not defined diff --git a/software/src/PetitFS/pff_obj/pff.asm b/software/src/PetitFS/pff_obj/pff.asm deleted file mode 100644 index fdbaedd..0000000 --- a/software/src/PetitFS/pff_obj/pff.asm +++ /dev/null @@ -1,3863 +0,0 @@ -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 17:13:29 2020 - - - - MODULE pff_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION code_compiler - -; Function ld_word flags 0x00000200 __smallc -; unsigned int WORDld_word(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_word - push bc - ld hl,4 ;const - call l_gintsp ; - inc hl - ld l,(hl) - ld h,0 - pop bc - push hl - ld h,l - ld l,0 - push hl - ld hl,6 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop bc - ret - - - -; Function ld_dword flags 0x00000200 __smallc -; unsigned long DWORDld_dword(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_dword - push bc - push bc - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - ret - - - -; Function mem_set flags 0x00000200 __smallc -; void mem_set(void *dst, int val, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'int val' at 4 size(2) -; parameter 'void *dst' at 6 size(2) -._mem_set - ld hl,6 ;const - call l_gintsp ; - push hl -.i_2 - ld hl,4 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_3 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,l - call l_sxt - ld a,l - call l_sxt - pop de - ld a,l - ld (de),a - jp i_2 -.i_3 - pop bc - ret - - - -; Function mem_cmp flags 0x00000200 __smallc -; int mem_cmp(const void *dst, const void *src, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'const void *src' at 4 size(2) -; parameter 'const void *dst' at 6 size(2) -._mem_cmp - ld hl,6 ;const - call l_g2intspsp ; - ld hl,0 ;const - push hl -.i_4 - ld hl,8 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_6 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - push hl - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - pop de - ex de,hl - and a - sbc hl,de - pop bc - push hl - ld a,h - or l - jp nz,i_6 - inc hl - jr i_7 -.i_6 - ld hl,0 ;const -.i_7 - ld a,h - or l - jp nz,i_4 -.i_5 - pop hl - pop bc - pop bc - ret - - - -; Function get_fat flags 0x00000200 __smallc -; unsigned long DWORDget_fat(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._get_fat - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - call l_glong - ld a,l - sub 2 - ld a,h - sbc 0 - ld a,e - sbc 0 - ld a,d - sbc 0 - jp c,i_9 - ld hl,8 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_8 -.i_9 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - -.i_8 - pop hl - push hl - ld l,(hl) - ld h,0 -.i_13 - ld a,l - cp +(3% 256) - jp nz,i_12 -.i_14 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,10 - add hl,bc - call l_glong2sp - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld l,+(7 % 256) - call l_long_asr_u - call l_long_add - push de - push hl - ld hl,14 ;const - add hl,sp - call l_glong - ld a,l - and +(127 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - push hl - ld hl,4 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp nz,i_12 -.i_15 - ld hl,2 ;const - add hl,sp - push hl - call _ld_dword - pop bc - ld a,d - and +(15 % 256) - ld d,a - pop bc - pop bc - pop bc - ret - - -.i_12 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - - -; Function clust2sect flags 0x00000200 __smallc -; unsigned long DWORDclust2sect(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._clust2sect - ld hl,(_FatFs) - push hl - ld hl,4 ;const - add hl,sp - push hl - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - call l_long_uge - jp nc,i_16 - ld hl,0 ;const - ld d,h - ld e,l - pop bc - ret - - -.i_16 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - call l_long_mult - push de - push hl - ld hl,4 ;const - call l_gintsp ; - ld bc,18 - add hl,bc - call l_glong - call l_long_add - pop bc - ret - - - -; Function get_clust flags 0x00000200 __smallc -; unsigned long DWORDget_clust(unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -._get_clust - ld hl,(_FatFs) - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - ld hl,0 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,20 - add hl,bc - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong - ex de,hl - ld hl,0 ;const - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld bc,26 - add hl,bc - push hl - call _ld_word - pop bc - pop de - call l_or - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - pop bc - ret - - - -; Function dir_rewind flags 0x00000200 __smallc -; const int FRESULTdir_rewind(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_rewind - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_glong - pop bc - call l_plong - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_eq - jp c,i_18 - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_17 -.i_18 - ld hl,1 ;const - pop bc - pop bc - pop bc - ret - - -.i_17 - ld hl,2 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_20 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,14 - add hl,bc - call l_glong - pop bc - call l_plong -.i_20 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - jp i_21 - ld hl,4 ;const - add hl,sp - call l_glong - ld a,h - or l - or d - or e - jp nz,i_21 - ld hl,0 ;const - jr i_22 -.i_21 - ld hl,1 ;const -.i_22 - jp nc,i_23 - ld hl,4 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - jp i_24 -.i_23 - pop bc - pop hl - push hl - push bc - ld bc,14 - add hl,bc - call l_glong -.i_24 - pop bc - call l_plong - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,4 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,0 ;const - pop bc - pop bc - pop bc - ret - - - -; Function dir_next flags 0x00000200 __smallc -; const int FRESULTdir_next(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_next - push bc - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,10 ;const - call l_gintsp ; - call l_gint ; - inc hl - pop de - pop bc - push hl - push de - call l_lneg - jp c,i_26 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - call l_long_lneg - jp nc,i_25 -.i_26 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_25 - pop bc - pop hl - push hl - push bc - ld a,l - and +(15 % 256) - jp nz,i_28 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - call l_glong - call l_inclong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_29 - ld hl,2 ;const - call l_gintspsp ; - pop bc - pop hl - push hl - push bc - ld bc,4 - add hl,bc - call l_gint ; - pop de - call l_uge - jp nc,i_30 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_30 - jp i_31 -.i_29 - pop bc - pop hl - push hl - push bc - ld de,4 - call l_asr_u_hl_by_e - pop de - push de - push hl - ex de,hl - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - pop de - call l_and - ld a,h - or l - jp nz,i_32 - ld hl,4 ;const - add hl,sp - push hl - ld hl,12 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_33 - ld hl,1 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_33 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_34 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_34 - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,6 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,6 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong -.i_32 -.i_31 -.i_28 - ld hl,10 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - call l_pint_pop - ld hl,0 ;const - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function dir_find flags 0x00000200 __smallc -; const int FRESULTdir_find(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_find - push bc - dec sp - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_35 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - -.i_35 -.i_38 - ld hl,1 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintspsp ; - ld hl,11 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,15 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_39 - ld hl,1 ;const - jp i_40 -.i_39 - ld hl,0 ;const -.i_40 - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_37 -.i_41 - ld hl,0 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_42 - ld hl,1 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint - jp i_37 -.i_42 - ld hl,5 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(8 % 256) - jp nz,i_44 - ld hl,5 ;const - call l_gintspsp ; - ld hl,9 ;const - call l_gintsp ; - inc hl - inc hl - ld e,(hl) - inc hl - ld d,(hl) - push de - ld hl,11 ;const - push hl - call _mem_cmp - pop bc - pop bc - pop bc - call l_lneg - jr c,i_45_i_44 -.i_44 - jp i_43 -.i_45_i_44 - jp i_37 -.i_43 - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop -.i_36 - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_38 -.i_37 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - - -; Function dir_read flags 0x00000200 __smallc -; const int FRESULTdir_read(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_read - ld hl,3 ;const - push hl - push bc -.i_46 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_47 - ld hl,i_1+0 - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - call l_gint ; - push hl - ld a,4 - call printf - pop bc - pop bc - pop bc - pop bc - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_48 - ld hl,1 ;const - jp i_49 -.i_48 - ld hl,0 ;const -.i_49 - pop de - pop bc - push hl - push de - ld a,h - or l - jp nz,i_47 -.i_50 - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_51 - ld hl,3 ;const - pop de - pop bc - push hl - push de - jp i_47 -.i_51 - ld hl,1 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(63 % 256) - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - add hl,sp - ld a,(hl) - cp 229 - jp z,i_53 - pop hl - push hl - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_53 - pop hl - push hl - ld l,h - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jr c,i_54_i_53 -.i_53 - jp i_52 -.i_54_i_53 - jp i_47 -.i_52 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - pop de - pop bc - push hl - push de - ld a,h - or l - jr nz,i_47 -.i_55 - jp i_46 -.i_47 - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_56 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,0 ;const - ld d,h - ld e,l - pop bc - call l_plong -.i_56 - pop bc - pop hl - ret - - - -; Function create_name flags 0x00000200 __smallc -; const int FRESULTcreate_name(struct 0__anonstruct_5 DIR*dj, const char **path) -; parameter 'const char **path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._create_name - push bc - push bc - push bc - push bc - dec sp - ld hl,13 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - pop de - pop bc - push hl - push de - ld hl,2 ;const - call l_gintspsp ; - ld hl,32 ;const - push hl - ld hl,11 ;const - push hl - call _mem_set - pop bc - pop bc - pop bc - ld hl,5 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,11 ;const - call l_gintsp ; - call l_gint ; - pop bc - push hl -.i_57 -.i_59 - ld hl,8 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp c,i_61 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,47 - and a - sbc hl,de - jr nz,i_60 -.i_61 - jp i_58 -.i_60 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr z,ASMPC+3 - ccf - jp c,i_64 - ld hl,4 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,6 ;const - add hl,sp - ld l,(hl) - ld h,0 - call l_uge - jp nc,i_63 -.i_64 - ld hl,6 ;const - add hl,sp - ld a,(hl) - cp 8 - jr z,ASMPC+3 - scf - jp c,i_67 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jr nc,i_66 -.i_67 - jp i_58 -.i_66 - ld hl,4 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,6 ;const - add hl,sp - ld (hl),+(11 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_57 -.i_63 - jp i_70 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - dec hl - pop de - ex de,hl - and a - sbc hl,de - jr c,i_71_i_70 -.i_70 - jp i_69 -.i_71_i_70 - ld hl,7 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - ex de,hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,9 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 - jp i_72 -.i_69 - jp i_74 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,97 - call l_uge - jp nc,i_75 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,122 - and a - sbc hl,de - ccf - jr c,i_76_i_75 -.i_75 - jp i_74 -.i_76_i_75 - jr i_77_i_74 -.i_74 - jp i_73 -.i_77_i_74 - ld hl,8 ;const - add hl,sp - ld a,(hl) - add a,+(-32 % 256) - ld (hl),a -.i_73 - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,10 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 -.i_72 - jp i_57 -.i_58 - ld hl,11 ;const - call l_gintspsp ; - ld hl,2 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - call l_pint_pop - pop bc - pop hl - push hl - push bc - ld bc,11 - add hl,bc - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp nc,i_78 - ld hl,1 ;const - jp i_79 -.i_78 - ld hl,0 ;const -.i_79 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - inc sp - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function get_fileinfo flags 0x00000200 __smallc -; void get_fileinfo(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._get_fileinfo - push bc - push bc - ld hl,6 ;const - call l_gintsp ; - ld bc,9 - add hl,bc - pop bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_80 - ld hl,3 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_83 -.i_81 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_83 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 8 - jp nc,i_82 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_82 -.i_84 - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 5 - jp nz,i_85 - ld hl,2 ;const - add hl,sp - ld (hl),+(229 % 256 % 256) -.i_85 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_81 -.i_82 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_86 - pop hl - ld (hl),+(46 % 256) - inc hl - push hl - ld hl,3 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_89 -.i_87 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_89 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 11 - jp nc,i_88 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_88 -.i_90 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_87 -.i_88 -.i_86 - ld hl,6 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,28 - add hl,bc - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,6 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,24 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop - ld hl,6 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop -.i_80 - pop de - push de - ld hl,0 ;const - ld a,l - ld (de),a - pop bc - pop bc - ret - - - -; Function follow_path flags 0x00000200 __smallc -; const int FRESULTfollow_path(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._follow_path - push bc -.i_91 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 32 - jp nz,i_92 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - jp i_91 -.i_92 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 47 - jp nz,i_93 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) -.i_93 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - ld hl,4 ;const - call l_gintsp ; - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp nc,i_94 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - pop bc - push hl - ld hl,6 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,0 % 256 ;const - ld a,l - ld (de),a - jp i_95 -.i_94 -.i_96 -.i_98 - ld hl,8 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _create_name - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_97 -.i_99 - ld hl,8 ;const - call l_gintspsp ; - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_find - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_97 -.i_100 - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - ld bc,11 - add hl,bc - ld l,(hl) - ld a,l - and a - jp nz,i_97 -.i_101 - ld hl,6 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(16 % 256) - jp nz,i_102 - ld hl,3 ;const - pop bc - push hl - jp i_97 -.i_102 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,8 ;const - call l_gintsp ; - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_96 -.i_97 -.i_95 - pop hl - ret - - - -; Function check_fs flags 0x00000200 __smallc -; unsigned char BYTEcheck_fs(unsigned char BYTE*buf, unsigned long sect) -; parameter 'unsigned long sect' at 2 size(4) -; parameter 'unsigned char BYTE*buf' at 6 size(2) -._check_fs - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,510 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_103 - ld hl,3 % 256 ;const - ret - - -.i_103 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,43605 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_104 - ld hl,2 % 256 ;const - ret - - -.i_104 - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,82 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - call l_lneg - jp nc,i_106 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,16710 - and a - sbc hl,de - jr z,i_107_i_106 -.i_106 - jp i_105 -.i_107_i_106 - ld hl,0 % 256 ;const - ret - - -.i_105 - ld hl,1 % 256 ;const - ret - - - -; Function pf_mount flags 0x00000200 __smallc -; const int FRESULTpf_mount(struct 0__anonstruct_4 FATFS*fs) -; parameter 'struct 0__anonstruct_4 FATFS*fs' at 2 size(2) -._pf_mount - ld hl,65483 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ld (_FatFs),hl - call _disk_initialize - ld a,l - and +(1 % 256) - jp z,i_108 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,2 ;const - ret - - -.i_108 - ld hl,12 ;const - add hl,sp - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - ld hl,52 ;const - add hl,sp - push hl - ld hl,18 ;const - add hl,sp - push hl - ld hl,16 ;const - call l_glongsp ; - call _check_fs - pop bc - pop bc - pop bc - pop de - ld a,l - ld (de),a - ld hl,52 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 1 - jp nz,i_109 - ld hl,16 ;const - add hl,sp - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,446 ;const - push hl - ld hl,16 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_110 - ld hl,52 ;const - add hl,sp - ld (hl),+(3 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_111 -.i_110 - ld hl,20 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_112 - ld hl,12 ;const - add hl,sp - push hl - ld hl,26 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,52 ;const - add hl,sp - push hl - ld hl,18 ;const - add hl,sp - push hl - ld hl,16 ;const - call l_glongsp ; - call _check_fs - pop bc - pop bc - pop bc - pop de - ld a,l - ld (de),a -.i_112 -.i_111 -.i_109 - ld hl,52 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 3 - jp nz,i_113 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_113 - ld hl,52 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_114 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,6 ;const - ret - - -.i_114 - ld hl,16 ;const - add hl,sp - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,13 ;const - push hl - ld hl,36 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_115 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_115 - ld hl,8 ;const - add hl,sp - push hl - ld hl,27 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,8 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_116 - ld hl,8 ;const - add hl,sp - push hl - ld hl,41 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong -.i_116 - ld hl,8 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,25 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_mult - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,10 - add hl,bc - push hl - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld hl,23 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - inc hl - inc hl - ex de,hl - ld hl,16 ;const - add hl,sp - ld a,(hl) - ld (de),a - ld hl,55 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,22 ;const - add hl,sp - push hl - call _ld_word - pop bc - call l_pint_pop - ld hl,4 ;const - add hl,sp - push hl - ld hl,24 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_117 - ld hl,4 ;const - add hl,sp - push hl - ld hl,37 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong -.i_117 - ld hl,0 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - call l_glong2sp - ld hl,23 ;const - add hl,sp - push hl - call _ld_word - pop bc - ld de,0 - call l_long_sub - push de - push hl - ld hl,14 ;const - add hl,sp - call l_glong - call l_long_sub - push de - push hl - ld hl,61 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_gint ; - ld de,4 - call l_asr_u_hl_by_e - ld de,0 - call l_long_sub - push de - push hl - ld hl,61 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - call l_long_div_u - ld bc,2 - add hl,bc - jr nc,ASMPC+3 - inc de - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - push hl - ld hl,2 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,52 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld hl,0 ;const - add hl,sp - call l_glong2sp - ld hl,65527 ;const - ld de,0 - call l_long_uge - jp nc,i_118 - ld hl,52 ;const - add hl,sp - ld (hl),+(3 % 256 % 256) -.i_118 - ld hl,52 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_119 - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,6 ;const - ret - - -.i_119 - ld hl,55 ;const - call l_gintspsp ; - ld hl,54 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld hl,55 ;const - call l_gintsp ; - ld bc,14 - add hl,bc - push hl - ld hl,49 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - ld bc,18 - add hl,bc - push hl - ld hl,57 ;const - call l_gintsp ; - ld bc,10 - add hl,bc - call l_glong2sp - ld hl,14 ;const - add hl,sp - call l_glong - call l_long_add - push de - push hl - ld hl,61 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_gint ; - ld de,4 - call l_asr_u_hl_by_e - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,55 ;const - call l_gintsp ; - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,55 ;const - call l_gintsp ; - ld (_FatFs),hl - ld hl,53 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_open flags 0x00000200 __smallc -; const int FRESULTpf_open(const char *path) -; parameter 'const char *path' at 2 size(2) -._pf_open - ld hl,65474 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_120 - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_120 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,48 ;const - add hl,sp - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,62 ;const - add hl,sp - push hl - ld hl,48 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - push hl - ld hl,72 ;const - call l_gintsp ; - push hl - call _follow_path - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,62 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_121 - ld hl,62 ;const - call l_gintsp ; - exx - ld hl,64 ;const - add hl,sp - ld sp,hl - exx - ret - - -.i_121 - ld hl,2 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_123 - ld hl,13 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_122 -.i_123 - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,3 ;const - ret - - -.i_122 - pop hl - push hl - ld bc,30 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - push hl - call _get_clust - pop bc - pop bc - call l_plong - pop hl - push hl - ld bc,26 - add hl,bc - push hl - ld hl,32 ;const - add hl,sp - push hl - call _ld_dword - pop bc - pop bc - call l_plong - pop hl - push hl - ld bc,22 - add hl,bc - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - inc hl - ld (hl),+(1 % 256 % 256) - ld hl,64 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_read flags 0x00000200 __smallc -; const int FRESULTpf_read(void *buff, unsigned int btr, unsigned int UINT*br) -; parameter 'unsigned int UINT*br' at 2 size(2) -; parameter 'unsigned int btr' at 4 size(2) -; parameter 'void *buff' at 6 size(2) -._pf_read - ld hl,65519 ;const - add hl,sp - ld sp,hl - ld hl,23 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - push de - ld hl,(_FatFs) - push hl - ld hl,23 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - call l_lneg - jp nc,i_125 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_125 - pop hl - push hl - inc hl - ld a,(hl) - and +(1 % 256) - jp nz,i_126 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,4 ;const - ret - - -.i_126 - ld hl,7 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,26 - add hl,bc - call l_glong2sp - ld hl,6 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_glong - call l_long_sub - pop bc - call l_plong - ld hl,25 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - call l_glong - exx - pop hl - ld de,0 - push de - push hl - exx - call l_long_ugt - jp nc,i_127 - ld hl,25 ;const - add hl,sp - push hl - ld hl,9 ;const - add hl,sp - call l_glong - call l_pint_pop -.i_127 -.i_128 - ld hl,25 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_129 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - exx - ld a,d - or e - or h - or l - jp nz,i_130 - ld hl,4 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - push de - push hl - ld hl,6 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - ld de,0 - call l_long_and - pop de - ld a,l - ld (de),a - ld hl,4 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_131 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_132 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,30 - add hl,bc - call l_glong - pop bc - call l_plong - jp i_133 -.i_132 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong -.i_133 - ld hl,15 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_134 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_134 - pop hl - push hl - ld bc,34 - add hl,bc - push hl - ld hl,17 ;const - add hl,sp - call l_glong - pop bc - call l_plong -.i_131 - ld hl,11 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,11 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_135 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_135 - pop hl - push hl - ld bc,38 - add hl,bc - push hl - ld hl,13 ;const - add hl,sp - call l_glong2sp - ld hl,10 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_add - pop bc - call l_plong -.i_130 - ld hl,5 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ld hl,512 - and a - sbc hl,de - call l_pint_pop - ld hl,5 ;const - call l_gintspsp ; - ld hl,27 ;const - call l_gintsp ; - pop de - and a - sbc hl,de - jp nc,i_136 - ld hl,5 ;const - add hl,sp - ex de,hl - ld hl,25 ;const - call l_gintsp ; - call l_pint -.i_136 - ld hl,19 ;const - add hl,sp - push hl - ld hl,4 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - ld bc,38 - add hl,bc - call l_glong2sp - ld hl,8 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - push hl - ld hl,15 ;const - call l_gintsp ; - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,19 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_137 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_137 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,11 ;const - call l_gintsp ; - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,25 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - call l_gint - ex de,hl - and a - sbc hl,de - call l_pint_pop - ld hl,23 ;const - call l_gintsp ; - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_138 - ld hl,2 ;const - call l_gintspsp ; - ld hl,7 ;const - call l_gintsp ; - pop de - add hl,de - pop de - pop bc - push hl - push de -.i_138 - jp i_128 -.i_129 - ld hl,21 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_write flags 0x00000200 __smallc -; const int FRESULTpf_write(const void *buff, unsigned int btw, unsigned int UINT*bw) -; parameter 'unsigned int UINT*bw' at 2 size(2) -; parameter 'unsigned int btw' at 4 size(2) -; parameter 'const void *buff' at 6 size(2) -._pf_write - ld hl,65524 ;const - add hl,sp - ld sp,hl - ld hl,18 ;const - call l_gintsp ; - push hl - push bc - dec sp - ld hl,(_FatFs) - push hl - ld hl,21 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - pop hl - push hl - call l_lneg - jp nc,i_139 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,5 ;const - ret - - -.i_139 - pop hl - push hl - inc hl - ld a,(hl) - and +(1 % 256) - jp nz,i_140 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,4 ;const - ret - - -.i_140 - ld hl,23 ;const - call l_gintsp ; - call l_lneg - jp nc,i_141 - pop hl - push hl - inc hl - ld a,+(64 % 256) - and (hl) - jp z,i_143 - ld hl,0 ;const - push hl - ld d,h - ld e,l - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jr nz,i_144_i_143 -.i_143 - jp i_142 -.i_144_i_143 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_142 - pop hl - push hl - inc hl - push hl - ld a,(hl) - and 191 - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - -.i_141 - pop hl - push hl - inc hl - ld a,(hl) - and +(64 % 256) - jp nz,i_146 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,65024 ;const - ld de,65535 - call l_long_and - pop bc - call l_plong -.i_146 -.i_145 - ld hl,7 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,26 - add hl,bc - call l_glong2sp - ld hl,6 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - call l_glong - call l_long_sub - pop bc - call l_plong - ld hl,23 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - call l_glong - exx - pop hl - ld de,0 - push de - push hl - exx - call l_long_ugt - jp nc,i_147 - ld hl,23 ;const - add hl,sp - push hl - ld hl,9 ;const - add hl,sp - call l_glong - call l_pint_pop -.i_147 -.i_148 - ld hl,23 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_149 - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - ld a,h - or l - jp nz,i_150 - ld hl,4 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,22 - add hl,bc - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_div_u - push de - push hl - ld hl,6 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - ld de,0 - call l_long_and - pop de - ld a,l - ld (de),a - ld hl,4 ;const - add hl,sp - ld a,(hl) - and a - jp nz,i_151 - pop hl - push hl - ld bc,22 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_152 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,30 - add hl,bc - call l_glong - pop bc - call l_plong - jp i_153 -.i_152 - ld hl,15 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong -.i_153 - ld hl,15 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_154 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_154 - pop hl - push hl - ld bc,34 - add hl,bc - push hl - ld hl,17 ;const - add hl,sp - call l_glong - pop bc - call l_plong -.i_151 - ld hl,11 ;const - add hl,sp - pop de - push de - push hl - ex de,hl - ld bc,34 - add hl,bc - call l_glong - push de - push hl - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,11 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_155 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_155 - pop hl - push hl - ld bc,38 - add hl,bc - push hl - ld hl,13 ;const - add hl,sp - call l_glong2sp - ld hl,10 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,0 - call l_long_add - pop bc - call l_plong - pop hl - push hl - ld bc,0 - push bc - ld bc,38 - add hl,bc - call l_glong - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_156 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_156 - pop hl - push hl - inc hl - ld a,(hl) - or 64 - ld (hl),a -.i_150 - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ld hl,512 - and a - sbc hl,de - pop de - pop bc - push hl - push de - ld hl,2 ;const - call l_gintspsp ; - ld hl,25 ;const - call l_gintsp ; - pop de - and a - sbc hl,de - jp nc,i_157 - ld hl,23 ;const - call l_gintsp ; - pop de - pop bc - push hl - push de -.i_157 - ld hl,5 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - ld de,0 - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_158 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_158 - pop hl - push hl - ld bc,22 - add hl,bc - push hl - call l_glong2sp - ld hl,8 ;const - call l_gintsp ; - ld de,0 - call l_long_add - pop bc - call l_plong - ld hl,5 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - ld hl,23 ;const - add hl,sp - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - ex de,hl - and a - sbc hl,de - call l_pint_pop - ld hl,21 ;const - call l_gintsp ; - push hl - ld e,(hl) - inc hl - ld d,(hl) - ld hl,4 ;const - add hl,sp - call l_gint - add hl,de - call l_pint_pop - pop hl - push hl - ld bc,22 - add hl,bc - call l_gint - ld de,512 - ex de,hl - call l_div_u - ex de,hl - ld a,h - or l - jp nz,i_159 - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - call _disk_writep - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_160 - pop hl - push hl - inc hl - ld (hl),+(0 % 256 % 256) - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,1 ;const - ret - - -.i_160 - pop hl - push hl - inc hl - push hl - ld a,(hl) - and 191 - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a -.i_159 - jp i_148 -.i_149 - ld hl,19 ;const - add hl,sp - ld sp,hl - ld hl,0 ;const - ret - - - -; Function pf_opendir flags 0x00000200 __smallc -; const int FRESULTpf_opendir(struct 0__anonstruct_5 DIR*dj, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_opendir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_161 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_162 -.i_161 - ld hl,i_1+33 - push hl - ld a,1 - call printf - pop bc - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - ld hl,56 ;const - call l_gintsp ; - push hl - call _follow_path - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,i_1+42 - push hl - ld hl,48 ;const - call l_gintsp ; - push hl - ld a,2 - call printf - pop bc - pop bc - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_163 - ld hl,2 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_164 - ld hl,i_1+55 - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld a,2 - call printf - pop bc - pop bc - ld hl,13 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_165 - ld hl,52 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_166 -.i_165 - ld hl,46 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint -.i_166 -.i_164 - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_167 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop -.i_167 -.i_163 -.i_162 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - -; Function pf_readdir flags 0x00000200 __smallc -; const int FRESULTpf_readdir(struct 0__anonstruct_5 DIR*dj, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_readdir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_168 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_169 -.i_168 - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,50 ;const - call l_gintsp ; - call l_lneg - jp nc,i_170 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - jp i_171 -.i_170 - ld hl,i_1+70 - push hl - ld a,1 - call printf - pop bc - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _dir_read - pop bc - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_172 - ld hl,52 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _get_fileinfo - pop bc - pop bc - pop bc - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld de,3 - and a - sbc hl,de - jp nz,i_173 - ld hl,46 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_173 -.i_172 -.i_171 -.i_169 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - SECTION rodata_compiler -.i_1 - defm "dir_read: sector:%ld, index:%l" - defm "d" - defb 10 - - defm "" - defb 0 - - defm "OPENDIR" - defb 10 - - defm "" - defb 0 - - defm "RESDIR:%02x" - defb 10 - - defm "" - defb 0 - - defm "IS A DIR:%02x" - defb 10 - - defm "" - defb 0 - - defm "Readdir" - defb 10 - - defm "" - defb 0 - - -; --- Start of Static Variables --- - - SECTION bss_compiler -._FatFs defs 2 - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/pff_dir.asm b/software/src/PetitFS/pff_obj/pff_dir.asm deleted file mode 100644 index 2be7af1..0000000 --- a/software/src/PetitFS/pff_obj/pff_dir.asm +++ /dev/null @@ -1,1267 +0,0 @@ -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 22:51:17 2020 - - - - MODULE pff_dir_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION code_compiler - -; Function dir_rewind flags 0x00000200 __smallc -; const int FRESULTdir_rewind(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_rewind - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - inc hl - ld h,(hl) - ld l,a - xor a - ld (hl),a - inc hl - ld (hl),a - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - call l_glong - pop bc - call l_plong - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_eq - jp c,i_3 - ld hl,2 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_2 -.i_3 - ld hl,1 ;const - pop bc - pop bc - pop bc - ret - - -.i_2 - ld hl,2 ;const - add hl,sp - call l_glong - call l_long_lneg - jp nc,i_5 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,14 - add hl,bc - call l_glong - pop bc - call l_plong -.i_5 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,4 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong - ld hl,0 ;const - pop bc - pop bc - pop bc - ret - - - -; Function dir_next flags 0x00000200 __smallc -; const int FRESULTdir_next(struct 0__anonstruct_5 DIR*dj) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 2 size(2) -._dir_next - push bc - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,10 ;const - call l_gintsp ; - call l_gint ; - inc hl - pop de - pop bc - push hl - push de - call l_lneg - jp c,i_7 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - call l_long_lneg - jp nc,i_6 -.i_7 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_6 - pop bc - pop hl - push hl - push bc - ld a,l - and +(15 % 256) - jp nz,i_9 - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - call l_glong - call l_inclong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - ld a,d - or e - or h - or l - jp nz,i_10 - ld hl,2 ;const - call l_gintspsp ; - pop bc - pop hl - push hl - push bc - ld bc,4 - add hl,bc - call l_gint ; - pop de - call l_uge - jp nc,i_11 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_11 - jp i_12 -.i_10 - pop bc - pop hl - push hl - push bc - ld de,4 - call l_asr_u_hl_by_e - pop de - push de - push hl - ex de,hl - inc hl - inc hl - ld l,(hl) - ld h,0 - dec hl - pop de - call l_and - ld a,h - or l - jp nz,i_13 - ld hl,4 ;const - add hl,sp - push hl - ld hl,12 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - call l_glong - push de - push hl - call _get_fat - pop bc - pop bc - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,1 ;const - ld de,0 - call l_long_ule - jp nc,i_14 - ld hl,1 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_14 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_15 - ld hl,3 ;const - pop bc - pop bc - pop bc - pop bc - ret - - -.i_15 - ld hl,10 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,6 ;const - add hl,sp - call l_glong - pop bc - call l_plong - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,6 ;const - call l_glongsp ; - call _clust2sect - pop bc - pop bc - pop bc - call l_plong -.i_13 -.i_12 -.i_9 - ld hl,10 ;const - call l_gintspsp ; - ld hl,4 ;const - call l_gintsp ; - call l_pint_pop - ld hl,0 ;const - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function dir_find flags 0x00000200 __smallc -; const int FRESULTdir_find(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_find - push bc - dec sp - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_16 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - -.i_16 -.i_19 - ld hl,1 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintspsp ; - ld hl,11 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,15 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_20 - ld hl,1 ;const - jp i_21 -.i_20 - ld hl,0 ;const -.i_21 - call l_pint_pop - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_18 -.i_22 - ld hl,0 ;const - add hl,sp - push hl - ld hl,7 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_23 - ld hl,1 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint - jp i_18 -.i_23 - ld hl,5 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(8 % 256) - jp nz,i_25 - ld hl,5 ;const - call l_gintspsp ; - ld hl,9 ;const - call l_gintsp ; - inc hl - inc hl - ld e,(hl) - inc hl - ld d,(hl) - push de - ld hl,11 ;const - push hl - call _mem_cmp - pop bc - pop bc - pop bc - call l_lneg - jr c,i_26_i_25 -.i_25 - jp i_24 -.i_26_i_25 - jp i_18 -.i_24 - ld hl,1 ;const - add hl,sp - push hl - ld hl,9 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop -.i_17 - ld hl,1 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_19 -.i_18 - ld hl,1 ;const - call l_gintsp ; - inc sp - pop bc - ret - - - -; Function dir_read flags 0x00000200 __smallc -; const int FRESULTdir_read(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._dir_read - ld hl,3 ;const - push hl - push bc -.i_27 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_28 - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld a,(hl) - and +(15 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - add hl,hl - add hl,hl - add hl,hl - push hl - ld hl,32 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_29 - ld hl,1 ;const - jp i_30 -.i_29 - ld hl,0 ;const -.i_30 - pop de - pop bc - push hl - push de - ld a,h - or l - jp nz,i_28 -.i_31 - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,(hl) - pop de - ld (de),a - pop hl - push hl - ld h,0 - ld a,l - and a - jp nz,i_32 - ld hl,3 ;const - pop de - pop bc - push hl - push de - jp i_28 -.i_32 - ld hl,1 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(63 % 256) - ld l,a - ld h,0 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - add hl,sp - ld a,(hl) - cp 229 - jp z,i_34 - pop hl - push hl - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_34 - pop hl - push hl - ld l,h - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jr c,i_35_i_34 -.i_34 - jp i_33 -.i_35_i_34 - jp i_28 -.i_33 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - pop de - pop bc - push hl - push de - ld a,h - or l - jr nz,i_28 -.i_36 - jp i_27 -.i_28 - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_37 - ld hl,8 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - push hl - ld hl,0 ;const - ld d,h - ld e,l - pop bc - call l_plong -.i_37 - pop bc - pop hl - ret - - - -; Function get_fileinfo flags 0x00000200 __smallc -; void get_fileinfo(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._get_fileinfo - push bc - push bc - ld hl,6 ;const - call l_gintsp ; - ld bc,9 - add hl,bc - pop bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,12 - add hl,bc - call l_glong - ld a,h - or l - or d - or e - jp z,i_38 - ld hl,3 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_41 -.i_39 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_41 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 8 - jp nc,i_40 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_40 -.i_42 - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 5 - jp nz,i_43 - ld hl,2 ;const - add hl,sp - ld (hl),+(229 % 256 % 256) -.i_43 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_39 -.i_40 - ld hl,8 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_44 - pop hl - ld (hl),+(46 % 256) - inc hl - push hl - ld hl,3 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_47 -.i_45 - ld hl,3 ;const - add hl,sp - inc (hl) -.i_47 - ld hl,3 ;const - add hl,sp - ld a,(hl) - sub 11 - jp nc,i_46 - ld hl,2 ;const - add hl,sp - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,5 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - ld a,(hl) - pop de - ld (de),a - ld hl,2 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp z,i_46 -.i_48 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld a,l - rla - sbc a - ld h,a - pop de - ld a,l - ld (de),a - jp i_45 -.i_46 -.i_44 - ld hl,6 ;const - call l_gintsp ; - ld bc,8 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - call l_gintspsp ; - ld hl,10 ;const - call l_gintsp ; - ld bc,28 - add hl,bc - push hl - call _ld_dword - pop bc - pop bc - call l_plong - ld hl,6 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,24 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop - ld hl,6 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,22 - add hl,bc - push hl - call _ld_word - pop bc - call l_pint_pop -.i_38 - pop de - push de - ld hl,0 ;const - ld a,l - ld (de),a - pop bc - pop bc - ret - - - -; Function pf_opendir flags 0x00000200 __smallc -; const int FRESULTpf_opendir(struct 0__anonstruct_5 DIR*dj, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_opendir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_49 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_50 -.i_49 - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - ld hl,56 ;const - call l_gintsp ; - push hl - call _follow_path - pop bc - pop bc - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_51 - ld hl,2 ;const - add hl,sp - ld a,(hl) - and a - jp z,i_52 - ld hl,13 ;const - add hl,sp - ld a,+(16 % 256) - and (hl) - jp z,i_53 - ld hl,52 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,4 ;const - add hl,sp - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_54 -.i_53 - ld hl,46 ;const - add hl,sp - ld de,3 ;const - ex de,hl - call l_pint -.i_54 -.i_52 - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_55 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop -.i_55 -.i_51 -.i_50 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - -; Function pf_readdir flags 0x00000200 __smallc -; const int FRESULTpf_readdir(struct 0__anonstruct_5 DIR*dj, struct 0__anonstruct_6 FILINFO*fno) -; parameter 'struct 0__anonstruct_6 FILINFO*fno' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._pf_readdir - ld hl,65490 ;const - add hl,sp - ld sp,hl - ld hl,(_FatFs) - push hl - call l_lneg - jp nc,i_56 - ld hl,46 ;const - add hl,sp - ld de,5 ;const - ex de,hl - call l_pint - jp i_57 -.i_56 - ld hl,52 ;const - call l_gintsp ; - inc hl - inc hl - push hl - ld hl,36 ;const - add hl,sp - call l_pint_pop - ld hl,50 ;const - call l_gintsp ; - call l_lneg - jp nc,i_58 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - call l_pint_pop - jp i_59 -.i_58 - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _dir_read - pop bc - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld a,h - or l - jp nz,i_60 - ld hl,52 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _get_fileinfo - pop bc - pop bc - pop bc - ld hl,46 ;const - add hl,sp - push hl - ld hl,54 ;const - call l_gintsp ; - push hl - call _dir_next - pop bc - call l_pint_pop - ld hl,46 ;const - call l_gintsp ; - ld de,3 - and a - sbc hl,de - jp nz,i_61 - ld hl,46 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_61 -.i_60 -.i_59 -.i_57 - ld hl,46 ;const - call l_gintsp ; - exx - ld hl,48 ;const - add hl,sp - ld sp,hl - exx - ret - - - -; --- Start of Static Variables --- - - SECTION bss_compiler - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _FatFs - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _ld_word - GLOBAL _ld_dword - GLOBAL _mem_set - GLOBAL _mem_cmp - GLOBAL _get_fat - GLOBAL _clust2sect - GLOBAL _create_name - GLOBAL _follow_path - GLOBAL _get_clust - GLOBAL _check_fs - GLOBAL _dir_rewind - GLOBAL _dir_find - GLOBAL _dir_next - GLOBAL _dir_read - GLOBAL _get_fileinfo - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/pff_dir.o b/software/src/PetitFS/pff_obj/pff_dir.o deleted file mode 100644 index 2f881d935948941de83fa2062bde242f949122e4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 12326 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 I3-R~=0Hjj&d;kCd diff --git a/software/src/PetitFS/pff_obj/pff_func.asm b/software/src/PetitFS/pff_obj/pff_func.asm deleted file mode 100644 index 65cf055..0000000 --- a/software/src/PetitFS/pff_obj/pff_func.asm +++ /dev/null @@ -1,1227 +0,0 @@ -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Fri Mar 13 22:51:17 2020 - - - - MODULE pff_func_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION code_compiler - -; Function ld_word flags 0x00000200 __smallc -; unsigned int WORDld_word(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_word - push bc - ld hl,4 ;const - call l_gintsp ; - inc hl - ld l,(hl) - ld h,0 - pop bc - push hl - ld h,l - ld l,0 - push hl - ld hl,6 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop bc - ret - - - -; Function ld_dword flags 0x00000200 __smallc -; unsigned long DWORDld_dword(const unsigned char BYTE*ptr) -; parameter 'const unsigned char BYTE*ptr' at 2 size(2) -._ld_dword - push bc - push bc - ld hl,0 ;const - add hl,sp - push hl - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - inc hl - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - ld a,(hl) - inc hl - ld e,(hl) - inc hl - ld d,(hl) - ld h,a - ld l,0 - push de - push hl - ld hl,12 ;const - call l_gintsp ; - ld l,(hl) - pop de - ld h,d - ld a,l - or e - ld l,a - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - ret - - - -; Function mem_set flags 0x00000200 __smallc -; void mem_set(void *dst, int val, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'int val' at 4 size(2) -; parameter 'void *dst' at 6 size(2) -._mem_set - ld hl,6 ;const - call l_gintsp ; - push hl -.i_2 - ld hl,4 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_3 - pop hl - inc hl - push hl - dec hl - push hl - ld hl,8 ;const - call l_gintsp ; - ld a,l - call l_sxt - ld a,l - call l_sxt - pop de - ld a,l - ld (de),a - jp i_2 -.i_3 - pop bc - ret - - - -; Function mem_cmp flags 0x00000200 __smallc -; int mem_cmp(const void *dst, const void *src, int cnt) -; parameter 'int cnt' at 2 size(2) -; parameter 'const void *src' at 4 size(2) -; parameter 'const void *dst' at 6 size(2) -._mem_cmp - ld hl,6 ;const - call l_g2intspsp ; - ld hl,0 ;const - push hl -.i_4 - ld hl,8 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - inc hl - ld a,h - or l - jp z,i_6 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - push hl - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - call l_gchar - pop de - ex de,hl - and a - sbc hl,de - pop bc - push hl - ld a,h - or l - jp nz,i_6 - inc hl - jr i_7 -.i_6 - ld hl,0 ;const -.i_7 - ld a,h - or l - jp nz,i_4 -.i_5 - pop hl - pop bc - pop bc - ret - - - -; Function get_fat flags 0x00000200 __smallc -; unsigned long DWORDget_fat(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._get_fat - push bc - push bc - ld hl,(_FatFs) - push hl - ld hl,8 ;const - add hl,sp - call l_glong - ld a,l - sub 2 - ld a,h - sbc 0 - ld a,e - sbc 0 - ld a,d - sbc 0 - jp c,i_9 - ld hl,8 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - call l_long_uge - jp nc,i_8 -.i_9 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - -.i_8 - pop hl - push hl - ld l,(hl) - ld h,0 -.i_13 - ld a,l - cp +(3% 256) - jp nz,i_12 -.i_14 - ld hl,2 ;const - add hl,sp - push hl - dec hl - dec hl - call l_gint ; - ld bc,10 - add hl,bc - call l_glong2sp - ld hl,14 ;const - add hl,sp - call l_glong2sp - ld l,+(7 % 256) - call l_long_asr_u - call l_long_add - push de - push hl - ld hl,14 ;const - add hl,sp - call l_glong - ld a,l - and +(127 % 256) - ld l,a - ld h,0 - add hl,hl - add hl,hl - push hl - ld hl,4 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp nz,i_12 -.i_15 - ld hl,2 ;const - add hl,sp - push hl - call _ld_dword - pop bc - ld a,d - and +(15 % 256) - ld d,a - pop bc - pop bc - pop bc - ret - - -.i_12 - ld hl,1 ;const - ld de,0 - pop bc - pop bc - pop bc - ret - - - -; Function clust2sect flags 0x00000200 __smallc -; unsigned long DWORDclust2sect(unsigned long clst) -; parameter 'unsigned long clst' at 2 size(4) -._clust2sect - ld hl,(_FatFs) - push hl - ld hl,4 ;const - add hl,sp - push hl - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - pop bc - call l_plong - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - ld bc,6 - add hl,bc - call l_glong - ld bc,65534 - add hl,bc - jr c,ASMPC+3 - dec de - call l_long_uge - jp nc,i_16 - ld hl,0 ;const - ld d,h - ld e,l - pop bc - ret - - -.i_16 - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,4 ;const - call l_gintsp ; - inc hl - inc hl - ld l,(hl) - ld h,0 - ld de,0 - call l_long_mult - push de - push hl - ld hl,4 ;const - call l_gintsp ; - ld bc,18 - add hl,bc - call l_glong - call l_long_add - pop bc - ret - - - -; Function get_clust flags 0x00000200 __smallc -; unsigned long DWORDget_clust(unsigned char BYTE*dir) -; parameter 'unsigned char BYTE*dir' at 2 size(2) -._get_clust - ld hl,(_FatFs) - push hl - ld hl,0 ;const - ld d,h - ld e,l - push de - push hl - ld hl,0 ;const - add hl,sp - push hl - ld hl,10 ;const - call l_gintsp ; - ld bc,20 - add hl,bc - push hl - call _ld_word - pop bc - ld de,0 - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong - ex de,hl - ld hl,0 ;const - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,14 ;const - call l_gintsp ; - ld bc,26 - add hl,bc - push hl - call _ld_word - pop bc - pop de - call l_or - pop de - pop bc - call l_plong - ld hl,0 ;const - add hl,sp - call l_glong - pop bc - pop bc - pop bc - ret - - - -; Function create_name flags 0x00000200 __smallc -; const int FRESULTcreate_name(struct 0__anonstruct_5 DIR*dj, const char **path) -; parameter 'const char **path' at 2 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 4 size(2) -._create_name - push bc - push bc - push bc - push bc - dec sp - ld hl,13 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - pop de - pop bc - push hl - push de - ld hl,2 ;const - call l_gintspsp ; - ld hl,32 ;const - push hl - ld hl,11 ;const - push hl - call _mem_set - pop bc - pop bc - pop bc - ld hl,5 ;const - add hl,sp - push hl - ld hl,6 ;const - add hl,sp - ld (hl),+(0 % 256 % 256) - ld a,(hl) - pop de - ld (de),a - ld hl,6 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,11 ;const - call l_gintsp ; - call l_gint ; - pop bc - push hl -.i_17 -.i_19 - ld hl,8 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp c,i_21 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,47 - and a - sbc hl,de - jr nz,i_20 -.i_21 - jp i_18 -.i_20 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr z,ASMPC+3 - ccf - jp c,i_24 - ld hl,4 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,6 ;const - add hl,sp - ld l,(hl) - ld h,0 - call l_uge - jp nc,i_23 -.i_24 - ld hl,6 ;const - add hl,sp - ld a,(hl) - cp 8 - jr z,ASMPC+3 - scf - jp c,i_27 - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld de,46 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jr nc,i_26 -.i_27 - jp i_18 -.i_26 - ld hl,4 ;const - add hl,sp - ld (hl),+(8 % 256 % 256) - ld hl,6 ;const - add hl,sp - ld (hl),+(11 % 256 % 256) - ld l,(hl) - ld h,0 - jp i_17 -.i_23 - jp i_30 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - push hl - ld hl,8 ;const - add hl,sp - ld l,(hl) - ld h,0 - dec hl - pop de - ex de,hl - and a - sbc hl,de - jr c,i_31_i_30 -.i_30 - jp i_29 -.i_31_i_30 - ld hl,7 ;const - add hl,sp - push hl - ld hl,2 ;const - call l_gintspsp ; - ld hl,9 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - pop de - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - ex de,hl - ld hl,8 ;const - add hl,sp - ld a,(hl) - ld (de),a - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,9 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 - jp i_32 -.i_29 - jp i_34 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,97 - call l_uge - jp nc,i_35 - ld hl,8 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,122 - and a - sbc hl,de - ccf - jr c,i_36_i_35 -.i_35 - jp i_34 -.i_36_i_35 - jr i_37_i_34 -.i_34 - jp i_33 -.i_37_i_34 - ld hl,8 ;const - add hl,sp - ld a,(hl) - add a,+(-32 % 256) - ld (hl),a -.i_33 - ld hl,2 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - inc (hl) - ld l,(hl) - ld h,0 - dec l - pop de - add hl,de - push hl - ld hl,10 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a - ld l,a - ld h,0 -.i_32 - jp i_17 -.i_18 - ld hl,11 ;const - call l_gintspsp ; - ld hl,2 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,7 ;const - add hl,sp - ld l,(hl) - ld h,0 - add hl,de - call l_pint_pop - pop bc - pop hl - push hl - push bc - ld bc,11 - add hl,bc - push hl - ld hl,10 ;const - add hl,sp - ld e,(hl) - ld d,0 - ld hl,32 - and a - sbc hl,de - ccf - jp nc,i_38 - ld hl,1 ;const - jp i_39 -.i_38 - ld hl,0 ;const -.i_39 - pop de - ld a,l - ld (de),a - ld hl,0 ;const - inc sp - pop bc - pop bc - pop bc - pop bc - ret - - - -; Function follow_path flags 0x00000200 __smallc -; const int FRESULTfollow_path(struct 0__anonstruct_5 DIR*dj, unsigned char BYTE*dir, const char *path) -; parameter 'const char *path' at 2 size(2) -; parameter 'unsigned char BYTE*dir' at 4 size(2) -; parameter 'struct 0__anonstruct_5 DIR*dj' at 6 size(2) -._follow_path - push bc -.i_40 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 32 - jp nz,i_41 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - jp i_40 -.i_41 - ld hl,4 ;const - call l_gintsp ; - ld a,(hl) - cp 47 - jp nz,i_42 - ld hl,4 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) -.i_42 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - xor a - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - inc hl - ld (hl),a - ld hl,4 ;const - call l_gintsp ; - ld l,(hl) - ld h,0 - ld de,32 - and a - sbc hl,de - jp nc,i_43 - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_rewind - pop bc - pop bc - push hl - ld hl,6 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,0 % 256 ;const - ld a,l - ld (de),a - jp i_44 -.i_43 -.i_45 -.i_47 - ld hl,8 ;const - call l_gintspsp ; - ld hl,6 ;const - add hl,sp - push hl - call _create_name - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_46 -.i_48 - ld hl,8 ;const - call l_gintspsp ; - ld hl,8 ;const - call l_gintsp ; - push hl - call _dir_find - pop bc - pop bc - pop bc - push hl - ld a,h - or l - jp nz,i_46 -.i_49 - ld hl,8 ;const - call l_gintsp ; - inc hl - inc hl - call l_gint ; - ld bc,11 - add hl,bc - ld l,(hl) - ld a,l - and a - jp nz,i_46 -.i_50 - ld hl,6 ;const - call l_gintsp ; - ld bc,11 - add hl,bc - ld a,(hl) - and +(16 % 256) - jp nz,i_51 - ld hl,3 ;const - pop bc - push hl - jp i_46 -.i_51 - ld hl,8 ;const - call l_gintsp ; - ld bc,4 - add hl,bc - push hl - ld hl,8 ;const - call l_gintsp ; - push hl - call _get_clust - pop bc - pop bc - call l_plong - jp i_45 -.i_46 -.i_44 - pop hl - ret - - - -; Function check_fs flags 0x00000200 __smallc -; unsigned char BYTEcheck_fs(unsigned char BYTE*buf, unsigned long sect) -; parameter 'unsigned long sect' at 2 size(4) -; parameter 'unsigned char BYTE*buf' at 6 size(2) -._check_fs - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,510 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - ld a,h - or l - jp z,i_52 - ld hl,3 % 256 ;const - ret - - -.i_52 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,43605 - and a - sbc hl,de - scf - jr nz,ASMPC+3 - ccf - jp nc,i_53 - ld hl,2 % 256 ;const - ret - - -.i_53 - ld hl,6 ;const - call l_gintspsp ; - ld hl,4 ;const - add hl,sp - call l_glong2sp - ld hl,82 ;const - push hl - ld hl,2 ;const - push hl - call _disk_readp - pop bc - pop bc - pop bc - pop bc - pop bc - call l_lneg - jp nc,i_55 - ld hl,6 ;const - call l_gintsp ; - push hl - call _ld_word - pop bc - ld de,16710 - and a - sbc hl,de - jr z,i_56_i_55 -.i_55 - jp i_54 -.i_56_i_55 - ld hl,0 % 256 ;const - ret - - -.i_54 - ld hl,1 % 256 ;const - ret - - - -; --- Start of Static Variables --- - - SECTION bss_compiler - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _FatFs - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _ld_word - GLOBAL _ld_dword - GLOBAL _mem_set - GLOBAL _mem_cmp - GLOBAL _get_fat - GLOBAL _clust2sect - GLOBAL _create_name - GLOBAL _follow_path - GLOBAL _get_clust - GLOBAL _check_fs - GLOBAL _dir_rewind - GLOBAL _dir_find - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/pff_func.o b/software/src/PetitFS/pff_obj/pff_func.o deleted file mode 100644 index 423d5a8ca15022df65159231b6afdcfe2bd5e4d1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9314 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 diff --git a/software/src/PetitFS/pff_obj/sdmmc.asm b/software/src/PetitFS/pff_obj/sdmmc.asm deleted file mode 100644 index e8c9f74..0000000 --- a/software/src/PetitFS/pff_obj/sdmmc.asm +++ /dev/null @@ -1,1111 +0,0 @@ -;* * * * * Small-C/Plus z88dk * * * * * -; Version: 16120-f784809cf-20200301 -; -; Reconstructed for z80 Module Assembler -; -; Module compile time: Sun Mar 15 00:33:56 2020 - - - - MODULE sdmmc_c - - - INCLUDE "z80_crt0.hdr" - - - SECTION data_compiler -._Stat - defb 1 - SECTION code_compiler - -; Function spi_init flags 0x00000200 __smallc -; int spi_init() -._spi_init - ; Method to initialise communications with the SD card. We basically train it to our clock characteristics. - ; This is important, as is maintaining the same clock for read or write otherwise the card may not respond. -SPI_INIT: LD B,80 -SPI_INIT1: LD A, 0x04 | 0x02 | 0x01 ; Output a 1 - OUT ( 0xFF ),A - LD A, 0x04 | 0x00 | 0x01 ; Output a 1 - OUT ( 0xFF ),A - DJNZ SPI_INIT1 - LD HL,0 ; hl is the return parameter - ret - - - -; Function spi_cs flags 0x00000200 __smallc -; int spi_cs(unsigned char b) -; parameter 'unsigned char b' at 2 size(1) -._spi_cs - ; Method to set the Chip Select level on the SD card. The Chip Select is active LOW. - ; - ; A = 0 - Set CS HIGH - ; A = 0xFF - Set CS LOW -SPI_CS: LD HL,2 - ADD HL,SP ; skip over return address on stack - LD A,(HL) ; a = b, "char b" occupies 16 bits on stack - ; but only the LSB is relevant - OR A - LD A, 0x04 | 0x00 | 0x01 ; Set CS High if parameter = 0 (ie. disable) - JR Z, SPI_CS0 - LD A, 0x04 | 0x00 | 0x00 ; Set CS Low if parameter != 0 (ie. disable) -SPI_CS0: OUT ( 0xFF ),A - LD HL,0 ; hl is the return parameter - ret - - - -; Function spi_out flags 0x00000200 __smallc -; int spi_out(unsigned char b) -; parameter 'unsigned char b' at 2 size(1) -._spi_out - ; Method to send a byte to the SD card via the SPI protocol. - ; This method uses the bitbang technique, change if hardware spi is available. - ; - ; Input A = Byte to send. - ; - LD HL,2 - ADD HL,SP ; skip over return address on stack - LD A,(HL) ; a = b, "char b" occupies 16 bits on stack - ; but only the LSB is relevant - RLCA ; 65432107 - RLCA ; 54321076 - RLCA ; 43210765 - Adjust so that starting bit is same position as Data line. - LD E,A ; E = Character to send. - LD B,8 ; B = Bit count -SPI_OUT0: LD A,E - AND 0x04 ; Data bit to data line, clock and cs low. - RLC E -SPI_OUT1: OUT ( 0xFF ),A - OR 0x02 ; Clock high - OUT ( 0xFF ),A - AND 0xFD ; Clock low - OUT ( 0xFF ),A - DJNZ SPI_OUT0 ; Perform actions for the full 8 bits. - LD HL,0 ; hl is the return parameter - ret - - - -; Function spi_in flags 0x00000200 __smallc -; unsigned char uint8_tspi_in() -._spi_in - ; Method to receive a byte from the SD card via the SPI protocol. - ; This method uses the bitbang technique, change if hardware spi is available. - ; NB. Timing must be very similar in SPIOUT and SPIIN. - ; - ; Output: A = received byte. - ; - LD BC,$800 | 0xFF ; B = Bit count, C = clock port - LD L,0 ; L = Character being read. - LD D, 0x04 | 0x00 | 0x00 ; Output a 0 - OUT (C),D ; To start ensure clock is low and CS is low. - LD E, 0x04 | 0x02 | 0x00 ; Output a 0 -SPI_IN1: OUT (C),E ; Clock to high. - IN A,( 0xFE ) ; Input the received bit - OUT (C),D ; Clock to low. - SRL A - RL L - DJNZ SPI_IN1 ; Perform actions for the full 8 bits. - LD H,0 ; hl is the return parameter, L already set to received byte. - ret - - - -; Function spi_skip flags 0x00000200 __smallc -; void spi_skip(unsigned int n) -; parameter 'unsigned int n' at 2 size(2) -._spi_skip - LD HL,2 - ADD HL,SP ; skip over return address on stack - LD C,(HL) ; n occupies 16 bits on stack - INC HL - LD B,(HL) -SPISKIP0: PUSH BC - CALL SPIIN - POP BC - DEC BC - LD A,B - OR C - JR NZ,SPISKIP0 - ret - - - -; Function send_cmd flags 0x00000200 __smallc -; unsigned char BYTEsend_cmd(unsigned char cmd, unsigned long arg) -; parameter 'unsigned long arg' at 2 size(4) -; parameter 'unsigned char cmd' at 6 size(1) -._send_cmd - ; Method to send a command to the card and receive back a response. - ; - ; A = CMD to send - ; LHED = Argument, ie. CMD = A, L, H, E, D, CRC - ; - LD HL,2 - ADD HL,SP ; skip over return address on stack - LD A,(HL) - LD (_SDBUF+4),A - INC HL - LD A,(HL) - LD (_SDBUF+3),A - INC HL - LD A,(HL) - LD (_SDBUF+2),A - INC HL - LD A,(HL) - LD (_SDBUF+1),A - INC HL - LD A,(HL) - LD (_SDBUF),A - ; - LD B,5 ; R1 + 32bit argument for (8) , (58) - CP (8) - LD C,135 - JP Z,SD_CMD0 - LD C,1 ; (58) is not CRC checked so just set to 0x01. - CP (58) - LD B,5 ; R1 + 32bit argument - JP Z,SD_CMD0 - ; - LD B,1 ; Default, expect R1 which is 1 byte. - CP (0) ; Work out the CRC based on the command. CRC checking is - LD C,149 ; not implemented but certain commands require a fixed argument and CRC. - JP Z,SD_CMD0 - LD C,1 ; Remaining commands are not CRC checked so just set to 0x01. -SD_CMD0: PUSH BC ; Save the CRC and the number of bytes to be returned, - LD A,C ; Store the CRC - LD (_SDBUF+5),A - LD A,255 ; Preamble byte - CALL SPIOUT - LD HL,_SDBUF - LD B,6 -SD_CMD1: PUSH BC - LD A,(HL) - INC HL - CALL SPIOUT ; Send the command and parameters. - POP BC - DJNZ SD_CMD1 - PUSH HL -SD_CMD2: CALL SPIIN - CP $FF - JR Z,SD_CMD2 - JR SD_CMD4 -SD_CMD3: PUSH BC - PUSH HL - CALL SPIIN ; -SD_CMD4: POP HL - LD (HL),A - INC HL - POP BC ; Get back number of expected bytes. HL = place in buffer to store response. - DJNZ SD_CMD3 - LD A, 0x04 | 0x00 | 0x01 - OUT ( 0xFF ),A - LD A,(_SDBUF+6) - LD L,A - LD H,0 - ret - - - -; Function disk_initialize flags 0x00000200 __smallc -; unsigned char DSTATUSdisk_initialize() -._disk_initialize - ; Method to initialise the SD card. - ; -SDINIT: LD A,$00 ; CS to high - CALL SPICS - ; - CALL SPIINIT ; Train SD with our clock. - ; - LD A,$FF ; CS to low - CALL SPICS - LD BC,$FFFF -SDINIT1: LD A, (0) ; Command 0 - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0000 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - PUSH BC - LD A,(_SDBUF+6) ; Get response code. - DEC A ; Set Z flag to test if response is 0x01 - JP Z,SDINIT2 ; Command response 0x01? Exit if match. - POP BC - DEC BC - LD A,B - OR C - JR NZ,SDINIT1 ; Retry for BC times. - LD A,1 - JP SD_EXIT ; Error, card is not responding to (0) -SDINIT2: POP BC - ; Now send (8) to get card details. This command can only be sent - ; when the card is idle. - LD A, (8) ; (8) has 0x00001AA as parameter, load up registers and call command routine. - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$AA01 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - ; Version 2 card, check its voltage range. IF not in the 2.7-3.6V dont try the (0x80+41) to get capabilities. -SDINIT3: LD A,1 ; Check that we receive 0x0001AA in response. - LD (_SDVER),A ; Indicate this is not a version 2 card. - LD A,(_SDBUF+9) - CP 1 - JP NZ,SDINIT8 - LD A,(_SDBUF+10) - CP $AA - JP NZ,SDINIT8 -SDINIT4: LD A,2 ; This is a version 2 card. -SDINIT5: LD (_SDVER),A ; Indicate this is not a version 2 card. - CALL SDACMD41 - JR Z,SDINIT6 - LD A,2 ; Error, card is not responding to (0x80+41) - JP SD_EXIT -SDINIT6: LD A, (58) ; (58) has 0x00000000 as parameter, load up registers and call command routine. - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0000 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - LD A,(_SDBUF+6) - CP $40 - LD A, 0x04 - JR Z,SDINIT7 - LD A, 0x04 | 0x08 -SDINIT7: LD (_SDCAP),A ; Set the capabilities according to the returned flag. - JR SDINIT14 - ; Version 1 card or MMC v3. -SDINIT8: CALL SDACMD41 - LD A, 0x02 - LD E, (0x80+41) ; SD1 cards we use the (0x80+41) command. - JR Z,SDINIT9 - LD A, 0x01 - LD E, (1) ; MMC cards we use the (1) command. -SDINIT9: LD (_SDCAP),A - LD A,E - CP (0x80+41) - JR NZ,SDINIT10 - CALL SDACMD41 - JR Z,SDINIT14 - LD A,3 ; Exit code, failed to initialise v1 card. - JP SD_EXIT -SDINIT10: LD BC,10 ; (0x80+41) / (55) may take some cards time to process or respond, so give a large number of retries. -SDINIT11: PUSH BC - LD A, (1) ; (1) has 0x00000000 as parameter, load up registers and call command routine. - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0000 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - LD A,(_SDBUF+6) ; Should be a response of 0 whereby the card has left idle. - OR A - JR Z,SDINIT13 - LD BC,$FFFF ; Delay for at least 200mS for the card to recover and be ready. -SDINIT12: DEC BC ; 6T - LD A,B ; 9T - OR C ; 4T - JR NZ,SDINIT12 ; 12T = 31T x 500ns = 15.5uS x 12903 = 200mS - ; - POP BC - DEC BC - LD A,B - OR C - JR NZ,SDINIT11 - LD A,4 ; Exit code, failed to initialise v1 MMC card. - JP SD_EXIT -SDINIT13: LD A, (16) ; No response from the card for an (0x80+41) / (1) so try (16) with parameter 0x00000200 - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0002 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - LD A,(_SDBUF+6) - OR A - JR Z,SDINIT14 - LD A,0 - LD (_SDCAP),A ; No capabilities on this unknown card. -SDINIT14: LD A,0 - JR SD_EXIT -SD_EXIT: LD L,A ; Return value goes into HL. - LD H,0 - RET - ; Method to initialise communications with the SD card. We basically train it to our clock characteristics. - ; This is important, as is maintaining the same clock for read or write otherwise the card may not respond. -SPIINIT: LD B,80 -SPIINIT1: LD A, 0x04 | 0x02 | 0x01 ; Output a 1 - OUT ( 0xFF ),A - LD A, 0x04 | 0x00 | 0x01 ; Output a 1 - OUT ( 0xFF ),A - DJNZ SPIINIT1 - RET - ; Method to set the Chip Select level on the SD card. The Chip Select is active LOW. - ; - ; A = 0 - Set CS HIGH - ; A = 0xFF - Set CS LOW -SPICS: OR A - LD A, 0x04 | 0x00 | 0x01 ; Set CS High if parameter = 0 (ie. disable) - JR Z, SPICS0 - LD A, 0x04 | 0x00 | 0x00 ; Set CS Low if parameter != 0 (ie. disable) -SPICS0: OUT ( 0xFF ),A - RET - ; Method to send a command to the card and receive back a response. - ; - ; A = CMD to send - ; LHED = Argument, ie. CMD = A, L, H, E, D, CRC - ; -SDCMD: LD (_SDBUF),A - LD (_SDBUF+1),HL - EX DE,HL - LD (_SDBUF+3),HL - ; - LD B,5 ; R1 + 32bit argument for (8) , (58) - CP (8) - LD C,135 - JP Z,SDCMD0 - LD C,1 ; (58) is not CRC checked so just set to 0x01. - CP (58) - LD B,5 ; R1 + 32bit argument - JP Z,SDCMD0 - ; - LD B,1 ; Default, expect R1 which is 1 byte. - CP (0) ; Work out the CRC based on the command. CRC checking is - LD C,149 ; not implemented but certain commands require a fixed argument and CRC. - JP Z,SDCMD0 - LD C,1 ; Remaining commands are not CRC checked so just set to 0x01. -SDCMD0: PUSH BC ; Save the CRC and the number of bytes to be returned, - LD A,C ; Store the CRC - LD (_SDBUF+5),A - LD A,255 ; Preamble byte - CALL SPIOUT - LD HL,_SDBUF - LD B,6 -SDCMD1: PUSH BC - LD A,(HL) - INC HL - CALL SPIOUT ; Send the command and parameters. - POP BC - DJNZ SDCMD1 - PUSH HL -SDCMD2: CALL SPIIN - CP $FF - JR Z,SDCMD2 - JR SDCMD4 -SDCMD3: PUSH BC - PUSH HL - CALL SPIIN ; -SDCMD4: POP HL - LD (HL),A - INC HL - POP BC ; Get back number of expected bytes. HL = place in buffer to store response. - DJNZ SDCMD3 - LD A, 0x04 | 0x00 | 0x01 - OUT ( 0xFF ),A - RET - ; Method to send an Application Command to the SD Card. This involves sending (55) followed by the required command. - ; - ; A = ACMD to send - ; LHED = Argument, ie. ACMD = A, L, H, E, D, CRC - ; -SDACMD: PUSH AF - PUSH DE - PUSH HL - LD A, (55) ; (55) has 0x00000000 as parameter, load up registers and call command routine. - LD HL,$0000 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0000 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDCMD - LD A,(_SDBUF+6) ; Should be a response of 0 whereby the card has left idle. - DEC A - JR NZ,SDACMD - POP HL - POP DE - POP AF - CALL SDCMD - LD A,(_SDBUF+6) ; Should be a response of 0 whereby the card has left idle. - OR A - RET - ; Method to send Application Command 41 to the SD card. This command involves retries and delays - ; hence coded seperately. - ; - ; Returns Z set if successful, else NZ. - ; -SDACMD41: LD BC,10 ; (0x80+41) / (55) may take some cards time to process or respond, so give a large number of retries. -SDACMD1: PUSH BC - LD A, (0x80+41) ; (0x80+41) has 0x40000000 as parameter, load up registers and call command routine. - LD HL,$0040 ; NB. Important, HL should be coded as LH due to little endian and the way it is used in SDCMD. - LD DE,$0000 ; NB. Important, DE should be coded as ED due to little endian and the way it is used in SDCMD. - CALL SDACMD - LD A,(_SDBUF+6) ; Should be a response of 0 whereby the card has left idle. - OR A - JR Z,SDACMD3 - LD BC,12903 ; Delay for at least 200mS for the card to recover and be ready. -SDACMD2: DEC BC ; 6T - LD A,B ; 9T - OR C ; 4T - JR NZ,SDACMD2 ; 12T = 31T x 500ns = 15.5uS x 12903 = 200mS - ; - POP BC - DEC BC - LD A,B - OR C - JR NZ,SDACMD1 - LD A,1 -SDACMD3: OR A - RET - ; Method to send a byte to the SD card via the SPI protocol. - ; This method uses the bitbang technique, change if hardware spi is available. - ; - ; Input A = Byte to send. - ; -SPIOUT: RLCA ; 65432107 - RLCA ; 54321076 - RLCA ; 43210765 - Adjust so that starting bit is same position as Data line. - LD E,A ; E = Character to send. - LD B,8 ; B = Bit count -SPIOUT0: LD A,E - AND 0x04 ; Data bit to data line, clock and cs low. - RLC E -SPIOUT1: OUT ( 0xFF ),A - OR 0x02 ; Clock high - OUT ( 0xFF ),A - AND 0xFD ; Clock low - OUT ( 0xFF ),A - DJNZ SPIOUT0 ; Perform actions for the full 8 bits. - RET - ; Method to receive a byte from the SD card via the SPI protocol. - ; This method uses the bitbang technique, change if hardware spi is available. - ; NB. Timing must be very similar in SPIOUT and SPIIN. - ; - ; Output: A = received byte. - ; -SPIIN: LD BC,$800 | 0xFF ; B = Bit count, C = clock port - LD L,0 ; L = Character being read. - LD D, 0x04 | 0x00 | 0x00 ; Output a 0 - OUT (C),D ; To start ensure clock is low and CS is low. - LD E, 0x04 | 0x02 | 0x00 ; Output a 0 -SPIIN1: OUT (C),E ; Clock to high. - IN A,( 0xFE ) ; Input the received bit - OUT (C),D ; Clock to low. - SRL A - RL L - DJNZ SPIIN1 ; Perform actions for the full 8 bits. - LD A,L ; return value - RET - ret - - - -; Function disk_readp flags 0x00000200 __smallc -; const int DRESULTdisk_readp(unsigned char BYTE*buff, unsigned long sector, unsigned int offset, unsigned int count) -; parameter 'unsigned int count' at 2 size(2) -; parameter 'unsigned int offset' at 4 size(2) -; parameter 'unsigned long sector' at 6 size(4) -; parameter 'unsigned char BYTE*buff' at 10 size(2) -._disk_readp - push bc - push bc - push bc - dec sp - ld hl,0 ;const - push hl - call _spi_cs - pop bc - ld hl,(_SDCAP) - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jp nc,i_3 - ld hl,13 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_mult - pop bc - call l_plong -.i_3 - ld hl,5 ;const - add hl,sp - ld (hl),+(1 % 256) - inc hl - ld (hl),+(1 / 256) - ld hl,17 ;const - push hl - ld hl,15 ;const - call l_glongsp ; - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp nz,i_4 - ld hl,1000 ;const - pop bc - push hl -.i_7 - ld hl,200 ;const - call t_delay - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_5 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 255 - jp nz,i_8 - pop hl - dec hl - push hl - ld a,h - or l - jr nz,i_9_i_8 -.i_8 - jp i_6 -.i_9_i_8 - jp i_7 -.i_6 - ld hl,4 ;const - add hl,sp - ld l,(hl) - ld h,0 - ld a,l - cp 254 - jp nz,i_10 - ld hl,11 ;const - add hl,sp - ld e,(hl) - inc hl - ld d,(hl) - ld hl,514 - and a - sbc hl,de - ex de,hl - ld hl,9 ;const - call l_gintsp ; - ex de,hl - and a - sbc hl,de - pop de - pop bc - push hl - push de - ld hl,11 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_11 - ld hl,11 ;const - call l_gintsp ; - push hl - call _spi_skip - pop bc -.i_11 - ld hl,17 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_12 -.i_15 - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a - ld hl,17 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - push hl - ld hl,6 ;const - add hl,sp - ld a,(hl) - pop de - ld (de),a -.i_13 - ld hl,9 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - ld a,h - or l - jp nz,i_15 -.i_14 - jp i_16 -.i_12 -.i_19 - ld hl,4 ;const - add hl,sp - push hl - call _spi_in - pop de - ld a,l - ld (de),a -.i_17 - ld hl,9 ;const - add hl,sp - dec (hl) - ld a,(hl) - inc hl - cp 255 - jr nz,ASMPC+3 - dec (hl) - ld h,(hl) - ld l,a - ld a,h - or l - jp nz,i_19 -.i_18 -.i_16 - pop bc - pop hl - push hl - push bc - push hl - call _spi_skip - pop bc - ld hl,5 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_10 -.i_4 - ld hl,255 ;const - push hl - call _spi_cs - pop bc - ld hl,5 ;const - call l_gintsp ; - inc sp - pop bc - pop bc - pop bc - ret - - - -; Function disk_writep flags 0x00000200 __smallc -; const int DRESULTdisk_writep(const unsigned char BYTE*buff, unsigned long sc) -; parameter 'unsigned long sc' at 2 size(4) -; parameter 'const unsigned char BYTE*buff' at 6 size(2) -._disk_writep - push bc - push bc - push bc - ld hl,4 ;const - add hl,sp - ld (hl),+(1 % 256) - inc hl - ld (hl),+(1 / 256) - ld hl,0 ;const - push hl - call _spi_cs - pop bc - ld hl,12 ;const - call l_gintsp ; - ld a,h - or l - jp z,i_20 - ld hl,8 ;const - add hl,sp - call l_glong - pop de - pop bc - push hl - push de -.i_21 - pop bc - pop hl - push hl - push bc - ld a,h - or l - jp z,i_23 - ld hl,(_st_disk_writep_wc) - ld a,h - or l - jr nz,i_24_i_23 -.i_23 - jp i_22 -.i_24_i_23 - ld hl,12 ;const - add hl,sp - inc (hl) - ld a,(hl) - inc hl - jr nz,ASMPC+3 - inc (hl) - ld h,(hl) - ld l,a - dec hl - ld l,(hl) - ld h,0 - push hl - call _spi_out - pop bc - ld hl,(_st_disk_writep_wc) - dec hl - ld (_st_disk_writep_wc),hl - pop de - pop hl - dec hl - push hl - push de - inc hl - jp i_21 -.i_22 - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint - jp i_25 -.i_20 - ld hl,8 ;const - add hl,sp - call l_glong - ld a,h - or l - or d - or e - jp z,i_26 - ld hl,(_SDCAP) - ld h,0 - ld a,+(8 % 256) - and l - ld l,a - call l_lneg - jp nc,i_27 - ld hl,8 ;const - add hl,sp - push hl - call l_glong2sp - ld hl,512 ;const - ld de,0 - call l_long_mult - pop bc - call l_plong -.i_27 - ld hl,24 ;const - push hl - ld hl,10 ;const - call l_glongsp ; - call _send_cmd - pop bc - pop bc - pop bc - ld a,l - and a - jp nz,i_28 - ld hl,255 ;const - push hl - call _spi_out - pop bc - ld hl,254 ;const - push hl - call _spi_out - pop bc - ld hl,512 ;const - ld (_st_disk_writep_wc),hl - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_28 - jp i_29 -.i_26 - ld hl,(_st_disk_writep_wc) - inc hl - inc hl - pop de - pop bc - push hl - push de -.i_30 - pop de - pop hl - dec hl - push hl - push de - inc hl - ld a,h - or l - jp z,i_31 - ld hl,0 ;const - push hl - call _spi_out - pop bc - jp i_30 -.i_31 - call _spi_in - ld a,l - and +(31 % 256) - ld l,a - ld h,0 - cp 5 - jp nz,i_32 - ld hl,10000 ;const - pop bc - push hl - jp i_35 -.i_33 - pop hl - dec hl - push hl - inc hl -.i_35 - call _spi_in - ld a,l - cp 255 - jp z,i_36 - pop hl - push hl - ld a,h - or l - jr nz,i_37_i_36 -.i_36 - jp i_34 -.i_37_i_36 - ld hl,200 ;const - call t_delay - jp i_33 -.i_34 - pop hl - push hl - ld a,h - or l - jp z,i_38 - ld hl,4 ;const - add hl,sp - ld de,0 ;const - ex de,hl - call l_pint -.i_38 -.i_32 - ld hl,255 ;const - push hl - call _spi_cs - pop bc -.i_29 -.i_25 - ld hl,4 ;const - call l_gintsp ; - pop bc - pop bc - pop bc - ret - - - -; --- Start of Static Variables --- - - SECTION bss_compiler -._SDBUF defs 11 -._SDVER defs 1 -._SDCAP defs 1 -._st_disk_writep_wc defs 2 - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _FatFs - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _SDBUF - GLOBAL _SDVER - GLOBAL _SDCAP - GLOBAL _spi_init - GLOBAL _spi_cs - GLOBAL _spi_out - GLOBAL _spi_in - GLOBAL _spi_skip - GLOBAL _send_cmd - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/sdmmc.o b/software/src/PetitFS/pff_obj/sdmmc.o deleted file mode 100644 index 5f32a95a6703bb78f99e78706f4d0892a8025cd4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8204 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 T6{BI %s" - defb 10 - - defm "" - defb 0 - - defm "%8lu %s" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Open a test file (message.txt)" - defm "." - defb 10 - - defm "" - defb 0 - - defm "MESSAGE.TXT" - defb 0 - - defm "" - defb 10 - - defm "Type the file content." - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Open a file to write (readme.t" - defm "xt)." - defb 10 - - defm "" - defb 0 - - defm "README.TXT" - defb 0 - - defm "" - defb 10 - - defm "Write a text data. (Hello worl" - defm "d!)" - defb 10 - - defm "" - defb 0 - - defm "Hello world!" - defb 13 - - defm "" - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Terminate the file write proce" - defm "ss." - defb 10 - - defm "" - defb 0 - - defm "" - defb 10 - - defm "Test completed." - defb 10 - - defm "" - defb 0 - - -; --- Start of Static Variables --- - - SECTION bss_compiler -._FatFs defs 2 - SECTION code_compiler - - -; --- Start of Scope Defns --- - - GLOBAL open - GLOBAL creat - GLOBAL close - GLOBAL read - GLOBAL write - GLOBAL lseek - GLOBAL readbyte - GLOBAL writebyte - GLOBAL getcwd - GLOBAL chdir - GLOBAL getwd - GLOBAL rmdir - GLOBAL _RND_BLOCKSIZE - GLOBAL rnd_loadblock - GLOBAL rnd_saveblock - GLOBAL rnd_erase - GLOBAL __FOPEN_MAX - GLOBAL __sgoioblk - GLOBAL __sgoioblk_end - GLOBAL fopen_zsock - GLOBAL fopen - GLOBAL freopen - GLOBAL fdopen - GLOBAL _freopen1 - GLOBAL fmemopen - GLOBAL funopen - GLOBAL fclose - GLOBAL fflush - GLOBAL closeall - GLOBAL fgets - GLOBAL fputs - GLOBAL fputc - GLOBAL fputs_callee - GLOBAL fputc_callee - GLOBAL fgetc - GLOBAL ungetc - GLOBAL feof - GLOBAL ferror - GLOBAL puts - GLOBAL ftell - GLOBAL fgetpos - GLOBAL fseek - GLOBAL fread - GLOBAL fwrite - GLOBAL gets - GLOBAL printf - GLOBAL fprintf - GLOBAL sprintf - GLOBAL snprintf - GLOBAL vfprintf - GLOBAL vsnprintf - GLOBAL printn - GLOBAL scanf - GLOBAL fscanf - GLOBAL sscanf - GLOBAL vfscanf - GLOBAL vsscanf - GLOBAL getarg - GLOBAL fchkstd - GLOBAL fgetc_cons - GLOBAL fgetc_cons_inkey - GLOBAL fputc_cons - GLOBAL fgets_cons - GLOBAL puts_cons - GLOBAL fabandon - GLOBAL fdtell - GLOBAL fdgetpos - GLOBAL rename - GLOBAL remove - GLOBAL getk - GLOBAL getk_inkey - GLOBAL printk - GLOBAL perror - GLOBAL atoi - GLOBAL atol - GLOBAL itoa - GLOBAL itoa_callee - GLOBAL ltoa - GLOBAL ltoa_callee - GLOBAL strtol - GLOBAL strtol_callee - GLOBAL strtoul - GLOBAL strtoul_callee - GLOBAL ultoa - GLOBAL ultoa_callee - GLOBAL utoa - GLOBAL utoa_callee - GLOBAL rand - GLOBAL srand - GLOBAL mallinit - GLOBAL sbrk - GLOBAL sbrk_callee - GLOBAL calloc - GLOBAL calloc_callee - GLOBAL free - GLOBAL malloc - GLOBAL realloc - GLOBAL realloc_callee - GLOBAL mallinfo - GLOBAL mallinfo_callee - GLOBAL HeapCreate - GLOBAL HeapSbrk - GLOBAL HeapSbrk_callee - GLOBAL HeapCalloc - GLOBAL HeapCalloc_callee - GLOBAL HeapFree - GLOBAL HeapFree_callee - GLOBAL HeapAlloc - GLOBAL HeapAlloc_callee - GLOBAL HeapRealloc - GLOBAL HeapRealloc_callee - GLOBAL HeapInfo - GLOBAL HeapInfo_callee - GLOBAL exit - GLOBAL atexit - GLOBAL getopt - GLOBAL _optarg - GLOBAL _opterr - GLOBAL _optind - GLOBAL _optopt - GLOBAL _optreset - GLOBAL l_bsearch - GLOBAL l_bsearch_callee - GLOBAL l_qsort - GLOBAL l_qsort_callee - GLOBAL qsort_sccz80 - GLOBAL qsort_sccz80_callee - GLOBAL qsort_sdcc - GLOBAL qsort_sdcc_callee - GLOBAL _div_ - GLOBAL _div__callee - GLOBAL _divu_ - GLOBAL _divu__callee - GLOBAL _ldiv_ - GLOBAL _ldiv__callee - GLOBAL _ldivu_ - GLOBAL _ldivu__callee - GLOBAL abs - GLOBAL labs - GLOBAL isqrt - GLOBAL inp - GLOBAL outp - GLOBAL outp_callee - GLOBAL swapendian - GLOBAL bpoke - GLOBAL bpoke_callee - GLOBAL wpoke - GLOBAL wpoke_callee - GLOBAL bpeek - GLOBAL wpeek - GLOBAL t_delay - GLOBAL sleep - GLOBAL msleep - GLOBAL extract_bits - GLOBAL extract_bits_callee - GLOBAL wcmatch - GLOBAL unbcd - GLOBAL _pf_mount - GLOBAL _pf_open - GLOBAL _pf_read - GLOBAL _pf_write - GLOBAL _pf_lseek - GLOBAL _pf_opendir - GLOBAL _pf_readdir - GLOBAL _FatFs - GLOBAL _disk_initialize - GLOBAL _disk_readp - GLOBAL _disk_writep - GLOBAL _die - GLOBAL _main - - -; --- End of Scope Defns --- - - -; --- End of Compilation --- diff --git a/software/src/PetitFS/pff_obj/sdtest.o b/software/src/PetitFS/pff_obj/sdtest.o deleted file mode 100644 index 8ebb17d9dbf34f3af2fd67605a4ecb8c82d276a9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9520 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 C4W4uW