14
14
; // You should have received a copy of the GNU General Public License
15
15
; // along with SE Basic IV. If not, see <http://www.gnu.org/licenses/>.
16
16
17
- org $ 0000 ;
18
- ;;
19
- ; // --- RESTART ROUTINES ----------------------------------------------------
20
- ;;
21
-
22
17
;;
23
18
; Short description of module.
24
19
; @author Name of contributing author.
30
25
; @throws Error number and description handled by RST 8 routine.
31
26
; @version Version in which the module was last udpated.
32
27
;;
28
+
29
+ ;;
30
+ ; // --- RESTART ROUTINES ----------------------------------------------------
31
+ ;;
32
+
33
+ org $ 0000 ;
34
+ ;;
35
+ ; cold start
36
+ ;;
33
37
rst_00:
34
38
di ; // interrupts off
39
+
40
+ ; // PC = $0001 is trapped by the divMMC hardware and the OS ROM paged in.
41
+ ; // Regardless of whether the BOOT or BASIC ROM is paged in, control is
42
+ ; // returned here. As a result, BC is set to HOME bank paging ($7ffd).
43
+
35
44
xor a ; // LD A, 0
36
- ; ld bc, paging; // HOME bank paging
37
45
out (c) , a ; // ROM 0, RAM 0, VIDEO 0, paging enabled
38
- nop ; // enter ROM 0 beofer hitting RST 8 trap
46
+ nop ; // enter BOOT ROM before hitting RST 8 trap
39
47
40
- org $ 0005 ; // BDOS
41
- cpm:
42
- jp bdos ; // immediate jump
48
+ org $ 0005 ;
49
+ ;;
50
+ ; BDOS entry point for CP/M compatibility
51
+ ;;
52
+ bdos:
53
+ nop ; // FIXME - should jump somewhere
54
+ nop ; //
55
+ nop ; //
43
56
44
57
org $ 0008 ;
45
58
;;
@@ -50,7 +63,6 @@ rst_08:
50
63
ld (x_ptr) , hl ; // to error pointer
51
64
jr error_2 ; // then jump
52
65
53
-
54
66
org $ 0010 ;
55
67
;;
56
68
; print a character
@@ -66,7 +78,6 @@ from_rom0:
66
78
xor a ; // LD A, 0
67
79
jp start_new ; // deal with a cold start
68
80
69
-
70
81
org $ 0018 ;
71
82
;;
72
83
; collect character
0 commit comments