Skip to content

Commit 853a0ab

Browse files
committed
update
1 parent eab9d93 commit 853a0ab

File tree

231 files changed

+26361
-18
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

231 files changed

+26361
-18
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
.vscode
22
*.sys
33
*.lst
4-
*.bak
4+
*.bak
5+
cpm*.dsk
6+
release/

bin/cpm.bin

-7.69 KB
Binary file not shown.

bootstrap/crt.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@ mos_fclose: equ $0b
3535
mos_fgetc: equ $0c
3636
mos_fputc: equ $0d
3737
mos_feof: equ $0e
38+
mos_setint: equ $14
3839
mos_uopen: equ $15
3940
mos_uclose: equ $16
4041
mos_ugetc: equ $17
4142
mos_uputc: equ $18
4243
mos_fread: equ $1a
4344
mos_fwrite: equ $1b
4445
mos_flseek: equ $1c
45-
4646
;; File modes
4747
fa_read: equ $01
4848
fa_write: equ $02

bootstrap/drive_emu.inc

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -110,17 +110,16 @@ fs_init:
110110
ld c, 0
111111
MOSCALL mos_fclose
112112

113+
MOSCALL mos_sysvars
114+
xor a
115+
ld (ix+$28), a
116+
ld ix, (sys_ix)
117+
113118
ld hl, drive
114119
ld c, fa_read+fa_write
115120
MOSCALL mos_fopen
116121
ld (f_handle), a
117122
or a
118-
push af
119-
MOSCALL mos_sysvars
120-
xor a
121-
ld (ix+$28), a
122-
ld ix, (sys_ix)
123-
pop af
124123
ret
125124

126125
fs_seek:

bootstrap/terminal.inc

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ _term_init:
2424
ld a, 7
2525
out0 (REG_FTC), a ; Disable fifo
2626

27-
ld a, 0
27+
xor a
2828
out0 (REG_IER), a ; Disable ints
2929

3030
@wait:
@@ -36,7 +36,7 @@ _term_init:
3636
ret
3737

3838
serial_cfg:
39-
dl 115200
39+
dl 57600
4040
db 8
4141
db 1
4242
db 0
@@ -45,6 +45,9 @@ serial_cfg:
4545

4646
vdu_init:
4747
db 23, 0, 255 ; Switch to terminal emulation
48+
db "CP/M to MOS gate v.1.1", 13, 10
49+
db "2023 (c) Aleksandr Sharikhin", 13, 10
50+
db 13,10
4851
init_end:
4952

5053

@@ -55,21 +58,25 @@ _ser_out:
5558

5659
ld a, c
5760
out0 ($D0), a
61+
5862
xor a
5963
ret.lil
6064

6165
_ser_in:
62-
in0 a, ($D5)
66+
in0 a, ($d5)
6367
and UART_LSR_RDY
6468
jr z, _ser_in
69+
6570
in0 a, ($d0)
71+
6672
ret.lil
6773

68-
_ser_status:
69-
in0 a, ($D5)
74+
_ser_status:
75+
in0 a, ($d5)
7076
and UART_LSR_RDY
7177
ret.lil z
7278
ld a, $ff
79+
or a
7380
ret.lil
7481
7582
_term_out:
@@ -121,3 +128,6 @@ _tty_status:
121128
ret.lil z
122129
ld a, $ff
123130
ret.lil
131+
132+
133+

disks/build.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/bash -e
2+
3+
rm -rf cpm*.dsk
4+
for pth in images/*
5+
do
6+
drive="${pth: -1}"
7+
image_name="cpm$drive.dsk"
8+
cp template.dsk $image_name
9+
echo "Working with drive image: $image_name"
10+
cpmcp -fnihirash $image_name $pth/*.* 0:
11+
echo "Image prepared"
12+
done

disks/cpma.dsk

-8 MB
Binary file not shown.

disks/cpmb.dsk

-8 MB
Binary file not shown.

disks/cpmc.dsk

-8 MB
Binary file not shown.

disks/cpmd.dsk

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)