diff --git a/InputTest.sv b/InputTest.sv
index 1bf855e..26a3e73 100644
--- a/InputTest.sv
+++ b/InputTest.sv
@@ -294,8 +294,6 @@ hps_io #(.CONF_STR(CONF_STR)) hps_io
//////////////////// CLOCKS ///////////////////
wire clk_sys;
-reg ce_pix;
-
pll pll
(
.refclk(CLK_50M),
@@ -303,15 +301,13 @@ pll pll
.outclk_0(clk_sys)
);
-
/////////////////// CLOCK DIVIDER ////////////////////
-
-always @(posedge clk_sys) begin
- reg div;
- div <= div + 1'd1;
- ce_pix <= !div;
-end
-
+wire ce_pix;
+jtframe_cen24 divider
+(
+ .clk(clk_sys),
+ .cen4(ce_pix)
+);
/////////////////// VIDEO ////////////////////
wire hblank, vblank;
@@ -321,7 +317,7 @@ wire [7:0] r;
wire [7:0] g;
wire [7:0] b;
wire [23:0] rgb = {r,g,b};
-arcade_video #(224,24) arcade_video
+arcade_video #(320,24) arcade_video
(
.*,
.clk_video(clk_sys),
@@ -357,7 +353,7 @@ system system(
.joystick({joystick_5,joystick_4,joystick_3,joystick_2,joystick_1,joystick_0}),
.analog({joystick_analog_5,joystick_analog_4,joystick_analog_3,joystick_analog_2,joystick_analog_1,joystick_analog_0}),
.paddle({paddle_5,paddle_4,paddle_3,paddle_2,paddle_1,paddle_0}),
- .spinner({spinner_5,spinner_4,spinner_3,spinner_2,spinner_1,spinner_0})
+ .spinner({7'b0,spinner_5,7'b0,spinner_4,7'b0,spinner_3,7'b0,spinner_2,7'b0,spinner_1,7'b0,spinner_0})
);
endmodule
diff --git a/release/InputTest.mra b/release/InputTest.mra
index c6959b8..46d5d71 100644
--- a/release/InputTest.mra
+++ b/release/InputTest.mra
@@ -8,7 +8,7 @@
-C3 00 01 00 00 00 00 00 FB ED 4D FB 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 31 00 00 CD 9A 12 CD 50 04 C3 04 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3E 02 CF C9 3E 00 CF 76 18 FD 01 00 00 21 00 C0 79 96 78 23 9E D0 21 00 80 09 36 00 03 18 EE 40 20 DD E5 DD 21 00 00 DD 39 F5 21 1F 02 4E 06 00 C5 DD 6E 09 DD 66 0A E5 CD 65 06 F1 F1 4D 44 DD 6E 07 DD 66 08 09 EB DD 6E 04 DD 66 05 E5 CD 08 07 F1 4D 06 00 78 91 30 20 21 00 80 19 E3 DD 7E 04 80 6F DD 7E 05 CE 00 67 7E E1 E5 77 21 00 88 19 DD 7E 06 77 13 04 18 DC DD F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 1F 02 4E 06 00 C5 DD 6E 08 DD 66 09 E5 CD 65 06 F1 F1 4D 44 DD 6E 06 DD 66 07 09 4D 44 21 00 80 09 DD 7E 04 77 21 00 88 09 DD 7E 05 77 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 00 00 E5 2E 00 E5 DD 56 04 1E 80 D5 CD 7E 02 21 06 00 39 F9 21 00 00 E5 2E 27 E5 DD 56 04 1E 82 D5 CD 7E 02 21 06 00 39 F9 21 1D 00 E5 2E 00 E5 DD 56 04 1E 85 D5 CD 7E 02 21 06 00 39 F9 21 1D 00 E5 2E 27 E5 DD 56 04 1E 84 D5 CD 7E 02 21 06 00 39 F9 0E 01 79 D6 27 30 30 59 16 00 C5 D5 21 00 00 E5 D5 DD 56 04 1E 81 D5 CD 7E 02 21 06 00 39 F9 D1 21 1D 00 E5 D5 DD 56 04 1E 81 D5 CD 7E 02 21 06 00 39 F9 C1 0C 18 CB 0E 01 79 D6 1D 30 2E 59 16 00 C5 D5 D5 21 00 00 E5 DD 56 04 1E 83 D5 CD 7E 02 21 06 00 39 F9 21 27 00 E5 DD 56 04 1E 83 D5 CD 7E 02 21 06 00 39 F9 C1 0C 18 CD DD E1 C9 DD E5 DD 21 00 00 DD 39 21 F6 FF 39 F9 CD 0A 02 3E 07 F5 33 CD B7 02 33 21 03 00 E5 2E 07 E5 3E FF F5 33 21 34 04 E5 CD 21 02 21 07 00 39 F9 21 03 00 E5 2E 19 E5 3E FF F5 33 21 43 04 E5 CD 21 02 21 07 00 39 F9 21 00 00 39 DD 75 FD DD 74 FE DD 7E FD DD 77 FB DD 7E FE DD 77 FC DD 36 FF 00 DD 7E FF D6 06 30 46 DD 4E FF 06 00 59 50 13 DD 6E FD DD 66 FE C5 D5 11 4A 04 D5 E5 CD D4 06 21 06 00 39 F9 C1 03 03 03 03 DD 7E FF 87 5F 3E FF 93 67 DD 5E FB DD 56 FC C5 01 02 00 C5 E5 33 D5 CD 21 02 21 07 00 39 F9 DD 34 FF 18 B3 DD F9 DD E1 C9 55 44 4C 52 41 42 43 58 59 5A 4C 52 53 73 00 41 58 20 20 41 59 00 4A 4F 59 25 64 00 DD E5 DD 21 00 00 DD 39 21 E8 FF 39 F9 21 20 02 5E 21 1F 02 66 2E 00 55 06 08 29 30 01 19 10 FA 22 00 C0 CD 82 03 DD 36 FB AB 3A 00 60 E6 80 32 02 C0 3A 00 60 E6 40 FD 21 04 C0 FD 77 00 FD 7E 00 B7 CA 31 06 3A 05 C0 B7 C2 31 06 DD 34 FB 21 01 00 E5 2E 06 E5 DD 7E FB F5 33 21 40 06 E5 CD 21 02 21 07 00 39 F9 0E 00 79 D6 02 D2 53 05 06 01 1E 00 7B FE 08 D2 4F 05 C6 07 57 79 87 87 87 DD 77 FA 7A DD 86 FA DD 77 FF DD 36 FC 00 DD 7E FC D6 06 30 64 DD 7E FC 2E 00 C6 04 DD 77 F2 7D CE 00 DD 77 F3 DD 7E FF DD 77 F0 DD 36 F1 00 DD 7E FC 0F 0F 0F E6 E0 DD 86 FA 57 17 9F 67 3E 00 82 6F 3E 70 8C 67 7E A0 28 06 21 07 C0 56 18 04 21 06 C0 56 C5 D5 DD 6E F2 DD 66 F3 E5 DD 6E F0 DD 66 F1 E5 3E FF F5 33 D5 33 CD 7E 02 21 06 00 39 F9 D1 C1 DD 34 FC 18 95 CB 20 1C C3 C3 04 0C C3 B9 04 DD 36 F0 01 21 04 00 39 DD 75 F2 DD 74 F3 DD 7E F2 DD 77 F8 DD 7E F3 DD 77 F9 21 00 00 39 DD 75 F6 DD 74 F7 DD 7E F6 DD 77 F4 DD 7E F7 DD 77 F5 DD 36 FE 00 DD 7E FE D6 06 D2 31 06 DD 6E FE 26 00 29 29 29 29 11 00 71 19 4E DD 7E FE 07 07 07 07 E6 F0 C6 08 5F 17 9F 57 21 00 71 19 7E DD 77 FD 79 17 9F 47 DD 5E F2 DD 56 F3 C5 21 5C 06 E5 D5 CD D4 06 21 06 00 39 F9 DD 4E FE 06 00 03 03 03 03 DD 5E F8 DD 56 F9 C5 C5 21 17 00 E5 3E FF F5 33 D5 CD 21 02 21 07 00 39 F9 C1 DD 7E FD 5F 17 9F 57 DD 6E F6 DD 66 F7 C5 D5 11 60 06 D5 E5 CD D4 06 21 06 00 39 F9 C1 DD 5E F4 DD 56 F5 C5 21 1C 00 E5 3E FF F5 33 D5 CD 21 02 21 07 00 39 F9 DD 7E F0 87 DD 77 F0 DD 34 FE C3 87 05 3A 02 C0 32 03 C0 3A 04 C0 32 05 C0 C3 7A 04 2D 2D 2D 20 4D 69 53 54 65 72 20 49 6E 70 75 74 20 54 65 73 74 65 72 20 2D 2D 2D 00 25 34 64 00 25 2D 34 64 00 F1 C1 D1 D5 C5 F5 AF 6F B0 06 10 20 04 06 08 79 29 CB 11 17 30 01 19 10 F7 C9 DD E5 DD 21 00 00 DD 39 DD 6E 05 DD 66 06 E5 4E 23 46 E1 59 50 13 73 23 72 DD 7E 04 02 DD E1 C9 21 02 00 39 FD 21 06 00 FD 39 FD 4E 00 FD 46 01 C5 FD 21 06 00 FD 39 FD 4E 00 FD 46 01 C5 E5 21 7F 06 E5 CD 32 08 F1 F1 F1 F1 4D 44 D1 E1 E5 D5 36 00 69 60 C9 DD E5 DD 21 00 00 DD 39 21 08 00 39 EB 21 04 00 39 D5 DD 4E 06 DD 46 07 C5 E5 21 7F 06 E5 CD 32 08 F1 F1 F1 F1 4D 44 DD 5E 04 DD 56 05 AF 12 69 60 DD E1 C9 C1 E1 E5 C5 AF 47 4F ED B1 21 FF FF ED 42 C9 21 02 00 39 7E C6 30 47 3E 39 90 30 10 78 C6 07 47 21 03 00 39 CB 46 28 04 78 C6 20 47 21 06 00 39 7E 23 66 6F E5 C5 33 21 07 00 39 7E 23 66 6F CD 97 12 F1 33 C9 DD E5 DD 21 00 00 DD 39 DD 7E 04 07 07 07 07 E6 0F 47 DD 6E 08 DD 66 09 E5 DD 6E 06 DD 66 07 E5 DD 7E 05 F5 33 C5 33 CD 17 07 21 06 00 39 F9 DD 7E 04 E6 0F 47 DD 6E 08 DD 66 09 E5 DD 6E 06 DD 66 07 E5 DD 7E 05 F5 33 C5 33 CD 17 07 21 06 00 39 F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 F9 FF 39 F9 DD 5E 04 DD 56 05 D5 21 04 00 39 EB 01 04 00 ED B0 D1 21 04 00 19 4D 44 DD 36 FF 20 0A 87 DD 77 FA DD 7E FE CB 07 E6 01 DD 77 F9 DD 7E FA DD B6 F9 DD 77 F9 02 DD CB FB 26 DD CB FC 16 DD CB FD 16 DD CB FE 16 DD 7E F9 DD 96 06 38 1F 0A DD 96 06 02 DD 7E FB F6 01 DD 77 FB DD 7E FC DD 77 FC DD 7E FD DD 77 FD DD 7E FE DD 77 FE DD 35 FF DD 7E FF B7 20 A7 21 02 00 39 01 04 00 ED B0 DD F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 C5 FF 39 F9 DD 36 E6 00 DD 36 E7 00 21 06 00 39 DD 75 E8 DD 74 E9 21 05 00 39 DD 75 E4 DD 74 E5 21 06 00 39 DD 75 D0 DD 74 D1 DD 7E D0 C6 04 DD 77 D4 DD 7E D1 CE 00 DD 77 D5 DD 7E D4 DD 77 D2 DD 7E D5 DD 77 D3 DD 7E D4 DD 77 D7 DD 7E D5 DD 77 D8 DD 6E 08 DD 66 09 5E 23 DD 75 08 DD 74 09 DD 73 D6 7B B7 CA 81 12 DD 7E D6 D6 25 C2 5E 12 DD 36 FC 00 DD 36 F9 00 DD 36 F8 00 DD 36 F7 00 DD 36 FF 00 DD 36 FE 00 DD 36 FD 00 DD 36 FB 00 DD 36 F3 00 DD 36 DB 00 DD 36 F2 FF DD 7E 08 DD 77 D9 DD 7E 09 DD 77 DA DD 6E D9 DD 66 DA 7E DD 77 DD DD 34 D9 20 03 DD 34 DA DD 7E D9 DD 77 08 DD 7E DA DD 77 09 DD 7E DD D6 25 20 23 DD 6E 06 DD 66 07 E5 DD 7E DD F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 C2 8D 08 DD 34 E7 C3 8D 08 DD 7E DD D6 30 38 40 3E 39 DD 96 DD 38 39 DD 7E F2 3C 20 1F DD 7E DB DD 77 DC 6F 4D 29 29 09 29 DD 7E DD 85 C6 D0 DD 77 DB B7 20 8C DD 36 F9 01 C3 E3 08 DD 6E F2 4D 29 29 09 29 DD 7E DD 85 C6 D0 DD 77 F2 C3 E3 08 DD 7E DD D6 2E 20 0E DD 7E F2 3C C2 E3 08 DD 36 F2 00 C3 E3 08 DD 7E DD D6 61 38 15 3E 7A DD 96 DD 38 0E DD 7E DD E6 DF DD 77 DD DD 36 FA 01 18 04 DD 36 FA 00 DD 7E DD D6 20 CA 46 0A DD 7E DD D6 2B CA 3F 0A DD 7E DD D6 2D 28 7A DD 7E DD D6 42 CA 4D 0A DD 7E DD D6 43 CA 5B 0A DD 7E DD D6 44 CA 63 0C DD 7E DD D6 46 CA 7F 0C DD 7E DD D6 48 CA E3 08 DD 7E DD D6 49 CA 63 0C DD 7E DD D6 4A CA E3 08 DD 7E DD D6 4C 28 57 DD 7E DD D6 4F CA 6D 0C DD 7E DD D6 50 CA BA 0B DD 7E DD D6 53 CA A3 0A DD 7E DD D6 54 CA E3 08 DD 7E DD D6 55 CA 73 0C DD 7E DD D6 58 CA 79 0C DD 7E DD D6 5A CA E3 08 C3 85 0C DD 36 FC 01 C3 E3 08 DD 36 F8 01 C3 E3 08 DD 36 F7 01 C3 E3 08 DD 36 FE 01 C3 E3 08 DD 36 FD 01 C3 E3 08 DD CB FE 46 28 11 DD 6E 0A DD 66 0B 23 DD 75 0A DD 74 0B 2B 46 18 11 DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 46 DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 C2 AF 0C DD 34 E7 C3 AF 0C 21 06 00 39 DD 75 D9 DD 74 DA DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 4E 23 46 DD 6E D9 DD 66 DA 71 23 70 C5 CD 08 07 F1 4D DD 7E F2 3C 20 03 DD 71 F2 DD CB FC 46 20 3C 79 DD 96 DB 30 36 DD 7E DB 91 47 DD 5E E6 DD 56 E7 78 05 B7 28 1D C5 D5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 D1 C1 13 18 DE DD 73 E6 DD 72 E7 DD 70 DB DD 46 F2 DD 5E E6 DD 56 E7 DD 6E D9 DD 66 DA 7E 23 66 6F 7E DD 77 DC B7 28 4A 68 05 AF 95 E2 3D 0B EE 80 F2 7E 0B C5 D5 DD 6E 06 DD 66 07 E5 DD 7E DC F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 D1 C1 13 DD 6E D9 DD 66 DA 7E 23 66 6F 23 DD 75 DE DD 74 DF DD 6E D9 DD 66 DA DD 7E DE 77 23 DD 7E DF 77 18 A5 DD 73 E6 DD 72 E7 DD CB FC 46 CA AF 0C 79 DD 96 DB D2 AF 0C DD 7E DB 91 4F 79 0D B7 CA A6 0C C5 D5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 D1 C1 13 18 DD 21 06 00 39 EB DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 4E 23 46 79 12 13 78 12 DD 6E 06 DD 66 07 E5 3E 30 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 4E E6 DD 46 E7 03 C5 DD 6E 06 DD 66 07 E5 3E 78 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 C1 03 21 07 00 39 56 C5 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 D5 33 CD 4D 07 21 06 00 39 F9 C1 03 03 DD 6E E8 DD 66 E9 56 C5 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 D5 33 CD 4D 07 21 06 00 39 F9 C1 03 03 DD 71 E6 DD 70 E7 18 4C DD 36 FF 01 DD 36 F3 0A 18 42 DD 36 F3 08 18 3C DD 36 F3 0A 18 36 DD 36 F3 10 18 30 DD 36 FB 01 18 2A DD 6E 06 DD 66 07 E5 DD 7E DD F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 20 0E DD 34 E7 18 09 DD 73 E6 DD 72 E7 DD 71 DB DD CB FB 46 CA 6B 0D 21 06 00 39 DD 75 DE DD 74 DF DD 7E 0A C6 04 DD 77 D9 DD 7E 0B CE 00 DD 77 DA DD 7E D9 DD 77 0A DD 7E DA DD 77 0B DD 7E D9 C6 FC DD 77 D9 DD 7E DA CE FF DD 77 DA DD 5E D9 DD 56 DA 21 1B 00 39 EB 01 04 00 ED B0 DD 5E DE DD 56 DF 21 1B 00 39 01 04 00 ED B0 21 06 00 39 DD 75 E0 DD 74 E1 36 8C 23 36 12 DD 7E E6 DD 77 DE DD 7E E7 DD 77 DF DD 6E E0 DD 66 E1 4E 23 46 59 50 13 DD 6E E0 DD 66 E1 73 23 72 0A 47 B7 CA 8D 08 DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 DE 20 03 DD 34 DF DD 7E DE DD 77 E6 DD 7E DF DD 77 E7 18 BB DD 7E F3 B7 CA 8D 08 DD 7E E4 DD 77 E0 DD 7E E5 DD 77 E1 DD CB FE 46 CA 0F 0E 21 06 00 39 DD 75 DE DD 74 DF DD 7E 0A C6 01 DD 77 D9 DD 7E 0B CE 00 DD 77 DA DD 7E D9 DD 77 0A DD 7E DA DD 77 0B DD 6E D9 DD 66 DA 2B 7E DD 77 DC DD 77 EA DD 36 EB 00 DD 36 EC 00 DD 36 ED 00 DD 5E DE DD 56 DF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 C2 1A 0F DD 5E DE DD 56 DF 21 25 00 39 EB 01 04 00 ED B0 DD 7E EA DD 77 EA DD 36 EB 00 DD 36 EC 00 DD 36 ED 00 DD 5E DE DD 56 DF 21 25 00 39 01 04 00 ED B0 C3 1A 0F DD CB FD 46 28 58 21 06 00 39 DD 75 EA DD 74 EB DD 7E 0A C6 04 DD 77 DE DD 7E 0B CE 00 DD 77 DF DD 7E DE DD 77 0A DD 7E DF DD 77 0B DD 7E DE C6 FC DD 77 DE DD 7E DF CE FF DD 77 DF DD 5E DE DD 56 DF 21 29 00 39 EB 01 04 00 ED B0 DD 5E EA DD 56 EB 21 29 00 39 01 04 00 ED B0 C3 1A 0F 21 06 00 39 DD 75 EE DD 74 EF DD 7E 0A C6 02 DD 77 EA DD 7E 0B CE 00 DD 77 EB DD 7E EA DD 77 0A DD 7E EB DD 77 0B DD 7E EA C6 FE DD 77 EA DD 7E EB CE FF DD 77 EB DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 6E EA DD 66 EB 7E DD 77 EA 23 7E DD 77 EB DD 7E EA DD 77 EA DD 7E EB DD 77 EB 17 9F DD 77 EC DD 77 ED DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 20 33 DD 5E EE DD 56 EF 21 25 00 39 EB 01 04 00 ED B0 DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 36 EC 00 DD 36 ED 00 DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 28 5F 21 06 00 39 DD 75 EE DD 74 EF EB 21 25 00 39 EB 01 04 00 ED B0 DD CB ED 7E 28 40 DD 5E EE DD 56 EF 21 25 00 39 EB 01 04 00 ED B0 AF DD 96 EA DD 77 EA 3E 00 DD 9E EB DD 77 EB 3E 00 DD 9E EC DD 77 EC 3E 00 DD 9E ED DD 77 ED DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 18 04 DD 36 FF 00 DD 36 F4 01 DD 4E E0 DD 46 E1 DD 36 EE 00 21 0A 00 39 36 00 DD 5E D0 DD 56 D1 C5 DD 7E F3 F5 33 D5 CD A2 07 F1 33 C1 DD CB F4 46 20 23 DD 6E D2 DD 66 D3 7E 07 07 07 07 E6 F0 5F DD 6E D2 DD 66 D3 7E 07 07 07 07 E6 0F B3 5F 0A B3 02 0B 18 08 DD 6E D4 DD 66 D5 7E 02 DD 34 EE DD 7E F4 EE 01 DD 77 F4 DD 6E D0 DD 66 D1 5E 23 56 23 23 7E 2B 6E B5 B2 B3 20 98 DD 71 EA DD 70 EB DD 7E EE DD 77 EE DD 7E DB B7 20 04 DD 36 DB 01 DD CB F9 46 20 5E DD CB FC 46 20 58 DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E DB DD 77 DE DD 7E EE DD 77 DC DD 34 DC DD 7E DC DD 96 DE 30 23 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E0 20 03 DD 34 E1 DD 35 DE 18 CC DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD 7E DE DD 77 DB DD CB FF 46 28 23 DD 6E 06 DD 66 07 E5 3E 2D F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB 18 56 DD 7E EE B7 28 50 DD CB F8 46 28 23 DD 6E 06 DD 66 07 E5 3E 2B F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB 18 27 DD CB F7 46 28 21 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB DD CB FC 46 20 57 DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E DB DD 77 DE DD 4E DE DD 35 DE DD 7E EE 91 30 52 DD CB F9 46 28 0A DD 36 D9 30 DD 36 DA 00 18 08 DD 36 D9 20 DD 36 DA 00 DD 46 D9 DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E0 20 C0 DD 34 E1 18 BB DD 7E EE DD 96 DB 30 0B DD 7E DB DD 96 EE DD 77 DC 18 18 DD 36 DC 00 18 12 DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD 7E DE DD 77 DC DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E EE DD 77 EE DD 4E EE DD 35 EE 79 B7 28 6A DD 7E F4 EE 01 DD 77 F4 DD CB F4 46 20 1E DD 34 EA 20 03 DD 34 EB DD 6E EA DD 66 EB 7E 07 07 07 07 E6 0F DD 6E D4 DD 66 D5 77 18 10 DD 6E EA DD 66 EB 7E E6 0F DD 6E D4 DD 66 D5 77 DD 6E D7 DD 66 D8 46 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 C5 33 CD 17 07 21 06 00 39 F9 DD 34 E0 20 91 DD 34 E1 18 8C DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD CB FC 46 CA 8D 08 DD 7E E0 DD 77 F5 DD 7E E1 DD 77 F6 DD 4E DC 79 0D B7 CA 8D 08 C5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 C1 DD 34 F5 20 03 DD 34 F6 DD 7E F5 DD 77 E6 DD 7E F6 DD 77 E7 18 CC DD 6E 06 DD 66 07 E5 DD 7E D6 F5 33 DD 6E 04 DD 66 05 CD 97 12 F1 33 DD 34 E6 C2 8D 08 DD 34 E7 C3 8D 08 DD 6E E6 DD 66 E7 DD F9 DD E1 C9 3C 4E 4F 20 46 4C 4F 41 54 3E 00 E9 30 31 01 02 00 78 B1 28 08 11 06 C0 21 98 12 ED B0 C9
+C3 00 01 00 00 00 00 00 FB ED 4D FB 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 FB ED 4D 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 31 00 00 CD 3A 14 CD 2A 05 C3 04 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3E 02 CF C9 3E 00 CF 76 18 FD 01 00 00 21 00 C0 79 96 78 23 9E D0 21 00 80 09 36 00 03 18 EE 40 20 DD E5 DD 21 00 00 DD 39 F5 21 1F 02 4E 06 00 C5 DD 6E 09 DD 66 0A E5 CD 05 08 F1 F1 4D 44 DD 6E 07 DD 66 08 09 EB DD 6E 04 DD 66 05 E5 CD A8 08 F1 4D 06 00 78 91 30 20 21 00 80 19 E3 DD 7E 04 80 6F DD 7E 05 CE 00 67 7E E1 E5 77 21 00 88 19 DD 7E 06 77 13 04 18 DC DD F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 1F 02 4E 06 00 C5 DD 6E 08 DD 66 09 E5 CD 05 08 F1 F1 4D 44 DD 6E 06 DD 66 07 09 4D 44 21 00 80 09 DD 7E 04 77 21 00 88 09 DD 7E 05 77 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 00 00 E5 2E 00 E5 DD 56 04 1E 80 D5 CD 7E 02 21 06 00 39 F9 21 00 00 E5 2E 27 E5 DD 56 04 1E 82 D5 CD 7E 02 21 06 00 39 F9 21 1D 00 E5 2E 00 E5 DD 56 04 1E 85 D5 CD 7E 02 21 06 00 39 F9 21 1D 00 E5 2E 27 E5 DD 56 04 1E 84 D5 CD 7E 02 21 06 00 39 F9 0E 01 79 D6 27 30 30 59 16 00 C5 D5 21 00 00 E5 D5 DD 56 04 1E 81 D5 CD 7E 02 21 06 00 39 F9 D1 21 1D 00 E5 D5 DD 56 04 1E 81 D5 CD 7E 02 21 06 00 39 F9 C1 0C 18 CB 0E 01 79 D6 1D 30 2E 59 16 00 C5 D5 D5 21 00 00 E5 DD 56 04 1E 83 D5 CD 7E 02 21 06 00 39 F9 21 27 00 E5 DD 56 04 1E 83 D5 CD 7E 02 21 06 00 39 F9 C1 0C 18 CD DD E1 C9 DD E5 DD 21 00 00 DD 39 21 EB FF 39 F9 CD 0A 02 3E 07 F5 33 CD B7 02 33 21 03 00 E5 2E 07 E5 3E FF F5 33 21 03 05 E5 CD 21 02 21 07 00 39 F9 21 03 00 E5 2E 1A E5 3E FF F5 33 21 12 05 E5 CD 21 02 21 07 00 39 F9 21 03 00 E5 2E 1F E5 3E FF F5 33 21 15 05 E5 CD 21 02 21 07 00 39 F9 21 00 00 39 EB DD 73 FA DD 72 FB DD 73 FC DD 72 FD DD 73 F4 DD 72 F5 DD 73 F2 DD 72 F3 DD 73 F0 DD 72 F1 DD 36 FF 00 DD 7E FF D6 06 D2 FE 04 DD 7E FF DD 77 F8 DD 36 F9 00 DD 7E F8 C6 01 DD 77 F6 DD 7E F9 CE 00 DD 77 F7 4B 42 D5 DD 6E F6 DD 66 F7 E5 21 18 05 E5 C5 CD 74 08 21 06 00 39 F9 D1 DD 7E F8 C6 04 6F DD 7E F9 CE 00 67 DD 7E FF 87 4F 3E FF 91 DD 77 FE DD 4E FA DD 46 FB D5 E5 21 02 00 E5 DD 7E FE F5 33 C5 CD 21 02 21 07 00 39 F9 D1 DD 4E FC DD 46 FD D5 DD 6E F6 DD 66 F7 E5 21 1E 05 E5 C5 CD 74 08 21 06 00 39 F9 D1 DD 7E F8 C6 0B 6F DD 7E F9 CE 00 67 DD 4E F4 DD 46 F5 D5 E5 21 02 00 E5 DD 7E FE F5 33 C5 CD 21 02 21 07 00 39 F9 D1 DD 4E F2 DD 46 F3 D5 DD 6E F6 DD 66 F7 E5 21 24 05 E5 C5 CD 74 08 21 06 00 39 F9 D1 DD 7E F8 C6 12 6F DD 7E F9 CE 00 67 DD 4E F0 DD 46 F1 D5 E5 21 02 00 E5 DD 7E FE F5 33 C5 CD 21 02 21 07 00 39 F9 D1 DD 34 FF C3 06 04 DD F9 DD E1 C9 55 44 4C 52 41 42 43 58 59 5A 4C 52 53 73 00 41 58 00 41 59 00 4A 4F 59 25 64 00 50 41 44 25 64 00 53 50 4E 25 64 00 DD E5 DD 21 00 00 DD 39 21 E5 FF 39 F9 21 20 02 5E 21 1F 02 66 2E 00 55 06 08 29 30 01 19 10 FA 22 00 C0 CD 82 03 0E AB 3A 00 60 E6 80 32 02 C0 3A 00 60 E6 40 FD 21 04 C0 FD 77 00 FD 7E 00 B7 CA CE 07 3A 05 C0 B7 C2 CE 07 0C C5 21 01 00 E5 2E 06 E5 79 F5 33 21 DD 07 E5 CD 21 02 21 07 00 39 F9 C1 1E 00 7B D6 02 D2 3A 06 DD 36 FE 01 DD 36 FD 00 DD 7E FD D6 08 D2 36 06 DD 7E FD C6 07 47 7B 87 87 87 DD 77 F9 78 DD 86 F9 DD 77 FA DD 36 FF 00 DD 7E FF 16 00 C6 04 DD 77 F5 7A CE 00 DD 77 F6 DD 7E FA DD 77 F7 DD 36 F8 00 DD 7E FF 0F 0F 0F E6 E0 DD 86 F9 47 17 9F 57 3E 00 80 6F 3E 70 8A 67 7E DD A6 FE B7 28 06 21 07 C0 46 18 04 21 06 C0 46 C5 D5 DD 6E F5 DD 66 F6 E5 DD 6E F7 DD 66 F8 E5 3E FF F5 33 C5 33 CD 7E 02 21 06 00 39 F9 D1 C1 DD 34 FF DD 7E FF D6 06 38 94 DD 7E FE 87 DD 77 FE DD 34 FD C3 9D 05 1C C3 8F 05 DD 36 FB 04 DD 36 FC 00 06 01 21 06 00 39 DD 75 F7 DD 74 F8 DD 7E F7 DD 77 F5 DD 7E F8 DD 77 F6 DD 36 FF 00 11 00 71 DD 6E FF 26 00 29 29 29 29 19 5E DD 7E FF 07 07 07 07 E6 F0 C6 08 6F 17 9F 67 D5 11 00 71 19 D1 7E 6F 17 9F 67 7B 17 9F 57 E5 DD 6E F7 DD 66 F8 E5 FD E1 E1 C5 E5 D5 21 F9 07 E5 FD E5 CD 74 08 21 08 00 39 F9 C1 DD 5E FF 16 00 DD 6E FB DD 66 FC 19 DD 5E F5 DD 56 F6 C5 E5 21 18 00 E5 3E FF F5 33 D5 CD 21 02 21 07 00 39 F9 C1 CB 20 DD 34 FF DD 7E FF D6 06 38 85 06 01 21 03 00 39 DD 75 F7 DD 74 F8 DD 7E F7 DD 77 F5 DD 7E F8 DD 77 F6 DD 36 FF 00 DD 5E FF 16 00 6B 62 29 29 29 3E 00 85 6F 3E 72 8C 67 6E 26 00 E5 DD 6E F7 DD 66 F8 E5 FD E1 E1 C5 D5 E5 21 01 08 E5 FD E5 CD 74 08 21 06 00 39 F9 D1 C1 21 0B 00 19 DD 5E F5 DD 56 F6 C5 E5 21 06 00 E5 3E FF F5 33 D5 CD 21 02 21 07 00 39 F9 C1 CB 20 DD 34 FF DD 7E FF D6 06 38 A3 06 01 21 00 00 39 DD 75 F7 DD 74 F8 DD 7E F7 DD 77 F5 DD 7E F8 DD 77 F6 DD 36 FF 00 DD 5E FF 16 00 6B 62 29 29 29 29 3E 00 85 6F 3E 73 8C 67 7E 6F 17 9F 67 E5 DD 6E F7 DD 66 F8 E5 FD E1 E1 C5 D5 E5 21 01 08 E5 FD E5 CD 74 08 21 06 00 39 F9 D1 C1 21 12 00 19 DD 5E F5 DD 56 F6 C5 E5 21 07 00 E5 3E FF F5 33 D5 CD 21 02 21 07 00 39 F9 C1 CB 20 DD 34 FF DD 7E FF D6 06 38 A0 3A 02 C0 32 03 C0 3A 04 C0 32 05 C0 C3 52 05 2D 2D 2D 20 4D 69 53 54 65 72 20 49 6E 70 75 74 20 54 65 73 74 65 72 20 2D 2D 2D 00 25 34 64 20 25 34 64 00 25 34 64 00 F1 C1 D1 D5 C5 F5 AF 6F B0 06 10 20 04 06 08 79 29 CB 11 17 30 01 19 10 F7 C9 DD E5 DD 21 00 00 DD 39 DD 6E 05 DD 66 06 E5 4E 23 46 E1 59 50 13 73 23 72 DD 7E 04 02 DD E1 C9 21 02 00 39 FD 21 06 00 FD 39 FD 4E 00 FD 46 01 C5 FD 21 06 00 FD 39 FD 4E 00 FD 46 01 C5 E5 21 1F 08 E5 CD D2 09 F1 F1 F1 F1 4D 44 D1 E1 E5 D5 36 00 69 60 C9 DD E5 DD 21 00 00 DD 39 21 08 00 39 EB 21 04 00 39 D5 DD 4E 06 DD 46 07 C5 E5 21 1F 08 E5 CD D2 09 F1 F1 F1 F1 4D 44 DD 5E 04 DD 56 05 AF 12 69 60 DD E1 C9 C1 E1 E5 C5 AF 47 4F ED B1 21 FF FF ED 42 C9 21 02 00 39 7E C6 30 47 3E 39 90 30 10 78 C6 07 47 21 03 00 39 CB 46 28 04 78 C6 20 47 21 06 00 39 7E 23 66 6F E5 C5 33 21 07 00 39 7E 23 66 6F CD 37 14 F1 33 C9 DD E5 DD 21 00 00 DD 39 DD 7E 04 07 07 07 07 E6 0F 47 DD 6E 08 DD 66 09 E5 DD 6E 06 DD 66 07 E5 DD 7E 05 F5 33 C5 33 CD B7 08 21 06 00 39 F9 DD 7E 04 E6 0F 47 DD 6E 08 DD 66 09 E5 DD 6E 06 DD 66 07 E5 DD 7E 05 F5 33 C5 33 CD B7 08 21 06 00 39 F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 F9 FF 39 F9 DD 5E 04 DD 56 05 D5 21 04 00 39 EB 01 04 00 ED B0 D1 21 04 00 19 4D 44 DD 36 FF 20 0A 87 DD 77 FA DD 7E FE CB 07 E6 01 DD 77 F9 DD 7E FA DD B6 F9 DD 77 F9 02 DD CB FB 26 DD CB FC 16 DD CB FD 16 DD CB FE 16 DD 7E F9 DD 96 06 38 1F 0A DD 96 06 02 DD 7E FB F6 01 DD 77 FB DD 7E FC DD 77 FC DD 7E FD DD 77 FD DD 7E FE DD 77 FE DD 35 FF DD 7E FF B7 20 A7 21 02 00 39 01 04 00 ED B0 DD F9 DD E1 C9 DD E5 DD 21 00 00 DD 39 21 C5 FF 39 F9 DD 36 E6 00 DD 36 E7 00 21 06 00 39 DD 75 E8 DD 74 E9 21 05 00 39 DD 75 E4 DD 74 E5 21 06 00 39 DD 75 D0 DD 74 D1 DD 7E D0 C6 04 DD 77 D4 DD 7E D1 CE 00 DD 77 D5 DD 7E D4 DD 77 D2 DD 7E D5 DD 77 D3 DD 7E D4 DD 77 D7 DD 7E D5 DD 77 D8 DD 6E 08 DD 66 09 5E 23 DD 75 08 DD 74 09 DD 73 D6 7B B7 CA 21 14 DD 7E D6 D6 25 C2 FE 13 DD 36 FC 00 DD 36 F9 00 DD 36 F8 00 DD 36 F7 00 DD 36 FF 00 DD 36 FE 00 DD 36 FD 00 DD 36 FB 00 DD 36 F3 00 DD 36 DB 00 DD 36 F2 FF DD 7E 08 DD 77 D9 DD 7E 09 DD 77 DA DD 6E D9 DD 66 DA 7E DD 77 DD DD 34 D9 20 03 DD 34 DA DD 7E D9 DD 77 08 DD 7E DA DD 77 09 DD 7E DD D6 25 20 23 DD 6E 06 DD 66 07 E5 DD 7E DD F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 C2 2D 0A DD 34 E7 C3 2D 0A DD 7E DD D6 30 38 40 3E 39 DD 96 DD 38 39 DD 7E F2 3C 20 1F DD 7E DB DD 77 DC 6F 4D 29 29 09 29 DD 7E DD 85 C6 D0 DD 77 DB B7 20 8C DD 36 F9 01 C3 83 0A DD 6E F2 4D 29 29 09 29 DD 7E DD 85 C6 D0 DD 77 F2 C3 83 0A DD 7E DD D6 2E 20 0E DD 7E F2 3C C2 83 0A DD 36 F2 00 C3 83 0A DD 7E DD D6 61 38 15 3E 7A DD 96 DD 38 0E DD 7E DD E6 DF DD 77 DD DD 36 FA 01 18 04 DD 36 FA 00 DD 7E DD D6 20 CA E6 0B DD 7E DD D6 2B CA DF 0B DD 7E DD D6 2D 28 7A DD 7E DD D6 42 CA ED 0B DD 7E DD D6 43 CA FB 0B DD 7E DD D6 44 CA 03 0E DD 7E DD D6 46 CA 1F 0E DD 7E DD D6 48 CA 83 0A DD 7E DD D6 49 CA 03 0E DD 7E DD D6 4A CA 83 0A DD 7E DD D6 4C 28 57 DD 7E DD D6 4F CA 0D 0E DD 7E DD D6 50 CA 5A 0D DD 7E DD D6 53 CA 43 0C DD 7E DD D6 54 CA 83 0A DD 7E DD D6 55 CA 13 0E DD 7E DD D6 58 CA 19 0E DD 7E DD D6 5A CA 83 0A C3 25 0E DD 36 FC 01 C3 83 0A DD 36 F8 01 C3 83 0A DD 36 F7 01 C3 83 0A DD 36 FE 01 C3 83 0A DD 36 FD 01 C3 83 0A DD CB FE 46 28 11 DD 6E 0A DD 66 0B 23 DD 75 0A DD 74 0B 2B 46 18 11 DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 46 DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 C2 4F 0E DD 34 E7 C3 4F 0E 21 06 00 39 DD 75 D9 DD 74 DA DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 4E 23 46 DD 6E D9 DD 66 DA 71 23 70 C5 CD A8 08 F1 4D DD 7E F2 3C 20 03 DD 71 F2 DD CB FC 46 20 3C 79 DD 96 DB 30 36 DD 7E DB 91 47 DD 5E E6 DD 56 E7 78 05 B7 28 1D C5 D5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 D1 C1 13 18 DE DD 73 E6 DD 72 E7 DD 70 DB DD 46 F2 DD 5E E6 DD 56 E7 DD 6E D9 DD 66 DA 7E 23 66 6F 7E DD 77 DC B7 28 4A 68 05 AF 95 E2 DD 0C EE 80 F2 1E 0D C5 D5 DD 6E 06 DD 66 07 E5 DD 7E DC F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 D1 C1 13 DD 6E D9 DD 66 DA 7E 23 66 6F 23 DD 75 DE DD 74 DF DD 6E D9 DD 66 DA DD 7E DE 77 23 DD 7E DF 77 18 A5 DD 73 E6 DD 72 E7 DD CB FC 46 CA 4F 0E 79 DD 96 DB D2 4F 0E DD 7E DB 91 4F 79 0D B7 CA 46 0E C5 D5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 D1 C1 13 18 DD 21 06 00 39 EB DD 6E 0A DD 66 0B 23 23 DD 75 0A DD 74 0B 2B 2B 4E 23 46 79 12 13 78 12 DD 6E 06 DD 66 07 E5 3E 30 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 4E E6 DD 46 E7 03 C5 DD 6E 06 DD 66 07 E5 3E 78 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 C1 03 21 07 00 39 56 C5 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 D5 33 CD ED 08 21 06 00 39 F9 C1 03 03 DD 6E E8 DD 66 E9 56 C5 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 D5 33 CD ED 08 21 06 00 39 F9 C1 03 03 DD 71 E6 DD 70 E7 18 4C DD 36 FF 01 DD 36 F3 0A 18 42 DD 36 F3 08 18 3C DD 36 F3 0A 18 36 DD 36 F3 10 18 30 DD 36 FB 01 18 2A DD 6E 06 DD 66 07 E5 DD 7E DD F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 20 0E DD 34 E7 18 09 DD 73 E6 DD 72 E7 DD 71 DB DD CB FB 46 CA 0B 0F 21 06 00 39 DD 75 DE DD 74 DF DD 7E 0A C6 04 DD 77 D9 DD 7E 0B CE 00 DD 77 DA DD 7E D9 DD 77 0A DD 7E DA DD 77 0B DD 7E D9 C6 FC DD 77 D9 DD 7E DA CE FF DD 77 DA DD 5E D9 DD 56 DA 21 1B 00 39 EB 01 04 00 ED B0 DD 5E DE DD 56 DF 21 1B 00 39 01 04 00 ED B0 21 06 00 39 DD 75 E0 DD 74 E1 36 2C 23 36 14 DD 7E E6 DD 77 DE DD 7E E7 DD 77 DF DD 6E E0 DD 66 E1 4E 23 46 59 50 13 DD 6E E0 DD 66 E1 73 23 72 0A 47 B7 CA 2D 0A DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 DE 20 03 DD 34 DF DD 7E DE DD 77 E6 DD 7E DF DD 77 E7 18 BB DD 7E F3 B7 CA 2D 0A DD 7E E4 DD 77 E0 DD 7E E5 DD 77 E1 DD CB FE 46 CA AF 0F 21 06 00 39 DD 75 DE DD 74 DF DD 7E 0A C6 01 DD 77 D9 DD 7E 0B CE 00 DD 77 DA DD 7E D9 DD 77 0A DD 7E DA DD 77 0B DD 6E D9 DD 66 DA 2B 7E DD 77 DC DD 77 EA DD 36 EB 00 DD 36 EC 00 DD 36 ED 00 DD 5E DE DD 56 DF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 C2 BA 10 DD 5E DE DD 56 DF 21 25 00 39 EB 01 04 00 ED B0 DD 7E EA DD 77 EA DD 36 EB 00 DD 36 EC 00 DD 36 ED 00 DD 5E DE DD 56 DF 21 25 00 39 01 04 00 ED B0 C3 BA 10 DD CB FD 46 28 58 21 06 00 39 DD 75 EA DD 74 EB DD 7E 0A C6 04 DD 77 DE DD 7E 0B CE 00 DD 77 DF DD 7E DE DD 77 0A DD 7E DF DD 77 0B DD 7E DE C6 FC DD 77 DE DD 7E DF CE FF DD 77 DF DD 5E DE DD 56 DF 21 29 00 39 EB 01 04 00 ED B0 DD 5E EA DD 56 EB 21 29 00 39 01 04 00 ED B0 C3 BA 10 21 06 00 39 DD 75 EE DD 74 EF DD 7E 0A C6 02 DD 77 EA DD 7E 0B CE 00 DD 77 EB DD 7E EA DD 77 0A DD 7E EB DD 77 0B DD 7E EA C6 FE DD 77 EA DD 7E EB CE FF DD 77 EB DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 6E EA DD 66 EB 7E DD 77 EA 23 7E DD 77 EB DD 7E EA DD 77 EA DD 7E EB DD 77 EB 17 9F DD 77 EC DD 77 ED DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 20 33 DD 5E EE DD 56 EF 21 25 00 39 EB 01 04 00 ED B0 DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 36 EC 00 DD 36 ED 00 DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 DD CB FF 46 28 5F 21 06 00 39 DD 75 EE DD 74 EF EB 21 25 00 39 EB 01 04 00 ED B0 DD CB ED 7E 28 40 DD 5E EE DD 56 EF 21 25 00 39 EB 01 04 00 ED B0 AF DD 96 EA DD 77 EA 3E 00 DD 9E EB DD 77 EB 3E 00 DD 9E EC DD 77 EC 3E 00 DD 9E ED DD 77 ED DD 5E EE DD 56 EF 21 25 00 39 01 04 00 ED B0 18 04 DD 36 FF 00 DD 36 F4 01 DD 4E E0 DD 46 E1 DD 36 EE 00 21 0A 00 39 36 00 DD 5E D0 DD 56 D1 C5 DD 7E F3 F5 33 D5 CD 42 09 F1 33 C1 DD CB F4 46 20 23 DD 6E D2 DD 66 D3 7E 07 07 07 07 E6 F0 5F DD 6E D2 DD 66 D3 7E 07 07 07 07 E6 0F B3 5F 0A B3 02 0B 18 08 DD 6E D4 DD 66 D5 7E 02 DD 34 EE DD 7E F4 EE 01 DD 77 F4 DD 6E D0 DD 66 D1 5E 23 56 23 23 7E 2B 6E B5 B2 B3 20 98 DD 71 EA DD 70 EB DD 7E EE DD 77 EE DD 7E DB B7 20 04 DD 36 DB 01 DD CB F9 46 20 5E DD CB FC 46 20 58 DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E DB DD 77 DE DD 7E EE DD 77 DC DD 34 DC DD 7E DC DD 96 DE 30 23 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E0 20 03 DD 34 E1 DD 35 DE 18 CC DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD 7E DE DD 77 DB DD CB FF 46 28 23 DD 6E 06 DD 66 07 E5 3E 2D F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB 18 56 DD 7E EE B7 28 50 DD CB F8 46 28 23 DD 6E 06 DD 66 07 E5 3E 2B F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB 18 27 DD CB F7 46 28 21 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 20 03 DD 34 E7 DD 35 DB DD CB FC 46 20 57 DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E DB DD 77 DE DD 4E DE DD 35 DE DD 7E EE 91 30 52 DD CB F9 46 28 0A DD 36 D9 30 DD 36 DA 00 18 08 DD 36 D9 20 DD 36 DA 00 DD 46 D9 DD 6E 06 DD 66 07 E5 C5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E0 20 C0 DD 34 E1 18 BB DD 7E EE DD 96 DB 30 0B DD 7E DB DD 96 EE DD 77 DC 18 18 DD 36 DC 00 18 12 DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD 7E DE DD 77 DC DD 7E EA DD 77 EA DD 7E EB DD 77 EB DD 7E E6 DD 77 E0 DD 7E E7 DD 77 E1 DD 7E EE DD 77 EE DD 4E EE DD 35 EE 79 B7 28 6A DD 7E F4 EE 01 DD 77 F4 DD CB F4 46 20 1E DD 34 EA 20 03 DD 34 EB DD 6E EA DD 66 EB 7E 07 07 07 07 E6 0F DD 6E D4 DD 66 D5 77 18 10 DD 6E EA DD 66 EB 7E E6 0F DD 6E D4 DD 66 D5 77 DD 6E D7 DD 66 D8 46 DD 6E 06 DD 66 07 E5 DD 6E 04 DD 66 05 E5 DD 7E FA F5 33 C5 33 CD B7 08 21 06 00 39 F9 DD 34 E0 20 91 DD 34 E1 18 8C DD 7E E0 DD 77 E6 DD 7E E1 DD 77 E7 DD CB FC 46 CA 2D 0A DD 7E E0 DD 77 F5 DD 7E E1 DD 77 F6 DD 4E DC 79 0D B7 CA 2D 0A C5 DD 6E 06 DD 66 07 E5 3E 20 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 C1 DD 34 F5 20 03 DD 34 F6 DD 7E F5 DD 77 E6 DD 7E F6 DD 77 E7 18 CC DD 6E 06 DD 66 07 E5 DD 7E D6 F5 33 DD 6E 04 DD 66 05 CD 37 14 F1 33 DD 34 E6 C2 2D 0A DD 34 E7 C3 2D 0A DD 6E E6 DD 66 E7 DD F9 DD E1 C9 3C 4E 4F 20 46 4C 4F 41 54 3E 00 E9 30 31 01 02 00 78 B1 28 08 11 06 C0 21 38 14 ED B0 C9
diff --git a/rtl/JTFRAME/jtframe_cen24.v b/rtl/JTFRAME/jtframe_cen24.v
index fbce6c1..f7f594e 100644
--- a/rtl/JTFRAME/jtframe_cen24.v
+++ b/rtl/JTFRAME/jtframe_cen24.v
@@ -37,7 +37,7 @@ module jtframe_cen24(
);
reg [3:0] cencnt =4'd0;
-reg [2:0] cencnt3=2'd0;
+reg [2:0] cencnt3=3'd0;
reg [2:0] cencnt8=3'd1;
assign cen8 = cencnt8[2];
diff --git a/rtl/pll.qip b/rtl/pll.qip
index 72c6b1f..d20d201 100644
--- a/rtl/pll.qip
+++ b/rtl/pll.qip
@@ -41,11 +41,11 @@ set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAM
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2ZyYWNfbXVsdGlwbHlfZmFjdG9y::MQ==::RnJhY3Rpb25hbCBNdWx0aXBseSBGYWN0b3IgKEsp"
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2RpdmlkZV9mYWN0b3Jfbg==::MQ==::RGl2aWRlIEZhY3RvciAoTi1Db3VudGVyKQ=="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2Nhc2NhZGVfY291bnRlcjA=::ZmFsc2U=::TWFrZSB0aGlzIGEgY2FzY2FkZSBjb3VudGVy"
-set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX291dHB1dF9jbG9ja19mcmVxdWVuY3kw::NC41::RGVzaXJlZCBGcmVxdWVuY3k="
+set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX291dHB1dF9jbG9ja19mcmVxdWVuY3kw::MjQuMA==::RGVzaXJlZCBGcmVxdWVuY3k="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2RpdmlkZV9mYWN0b3JfYzA=::MQ==::RGl2aWRlIEZhY3RvciAoQy1Db3VudGVyKQ=="
-set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9tdWx0aXBseV9mYWN0b3Iw::Mjc=::QWN0dWFsIE11bHRpcGx5IEZhY3Rvcg=="
+set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9tdWx0aXBseV9mYWN0b3Iw::MzY=::QWN0dWFsIE11bHRpcGx5IEZhY3Rvcg=="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9mcmFjX211bHRpcGx5X2ZhY3RvcjA=::MQ==::QWN0dWFsIEZyYWN0aW9uYWwgTXVsdGlwbHkgRmFjdG9yIChLKQ=="
-set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9kaXZpZGVfZmFjdG9yMA==::MzAw::QWN0dWFsIERpdmlkZSBGYWN0b3I="
+set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9kaXZpZGVfZmFjdG9yMA==::NzU=::QWN0dWFsIERpdmlkZSBGYWN0b3I="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9vdXRwdXRfY2xvY2tfZnJlcXVlbmN5MA==::MCBNSHo=::QWN0dWFsIEZyZXF1ZW5jeQ=="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BzX3VuaXRzMA==::cHM=::UGhhc2UgU2hpZnQgdW5pdHM="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BoYXNlX3NoaWZ0MA==::MA==::UGhhc2UgU2hpZnQ="
@@ -256,7 +256,7 @@ set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAM
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BoYXNlX3NoaWZ0X2RlZzE3::MC4w::UGhhc2UgU2hpZnQ="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2FjdHVhbF9waGFzZV9zaGlmdDE3::MA==::QWN0dWFsIFBoYXNlIFNoaWZ0"
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2R1dHlfY3ljbGUxNw==::NTA=::RHV0eSBDeWNsZQ=="
-set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTA=::NC41MDAwMDAgTUh6::b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTA="
+set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTA=::MjQuMDAwMDAwIE1Ieg==::b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTA="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "cGhhc2Vfc2hpZnQw::MCBwcw==::cGhhc2Vfc2hpZnQw"
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "ZHV0eV9jeWNsZTA=::NTA=::ZHV0eV9jeWNsZTA="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTE=::MCBNSHo=::b3V0cHV0X2Nsb2NrX2ZyZXF1ZW5jeTE="
@@ -318,7 +318,7 @@ set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAM
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "cGxsX3R5cGU=::R2VuZXJhbA==::UExMIFRZUEU="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "cGxsX3N1YnR5cGU=::R2VuZXJhbA==::UExMIFNVQlRZUEU="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BhcmFtZXRlcl9saXN0::TS1Db3VudGVyIEhpIERpdmlkZSxNLUNvdW50ZXIgTG93IERpdmlkZSxOLUNvdW50ZXIgSGkgRGl2aWRlLE4tQ291bnRlciBMb3cgRGl2aWRlLE0tQ291bnRlciBCeXBhc3MgRW5hYmxlLE4tQ291bnRlciBCeXBhc3MgRW5hYmxlLE0tQ291bnRlciBPZGQgRGl2aWRlIEVuYWJsZSxOLUNvdW50ZXIgT2RkIERpdmlkZSBFbmFibGUsQy1Db3VudGVyLTAgSGkgRGl2aWRlLEMtQ291bnRlci0wIExvdyBEaXZpZGUsQy1Db3VudGVyLTAgQ29hcnNlIFBoYXNlIFNoaWZ0LEMtQ291bnRlci0wIFZDTyBQaGFzZSBUYXAsQy1Db3VudGVyLTAgSW5wdXQgU291cmNlLEMtQ291bnRlci0wIEJ5cGFzcyBFbmFibGUsQy1Db3VudGVyLTAgT2RkIERpdmlkZSBFbmFibGUsVkNPIFBvc3QgRGl2aWRlIENvdW50ZXIgRW5hYmxlLENoYXJnZSBQdW1wIGN1cnJlbnQgKHVBKSxMb29wIEZpbHRlciBCYW5kd2lkdGggUmVzaXN0b3IgKE9obXMpICxQTEwgT3V0cHV0IFZDTyBGcmVxdWVuY3ksSy1GcmFjdGlvbmFsIERpdmlzaW9uIFZhbHVlIChEU00pLEZlZWRiYWNrIENsb2NrIFR5cGUsRmVlZGJhY2sgQ2xvY2sgTVVYIDEsRmVlZGJhY2sgQ2xvY2sgTVVYIDIsTSBDb3VudGVyIFNvdXJjZSBNVVgsUExMIEF1dG8gUmVzZXQ=::UGFyYW1ldGVyIE5hbWVz"
-set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BhcmFtZXRlcl92YWx1ZXM=::MTQsMTMsMiwyLGZhbHNlLGZhbHNlLHRydWUsZmFsc2UsMzgsMzcsMSwwLHBoX211eF9jbGssZmFsc2UsdHJ1ZSwyLDIwLDYwMDAsMzM3LjUgTUh6LDEsbm9uZSxnbGIsbV9jbnQscGhfbXV4X2Nsayx0cnVl::UGFyYW1ldGVyIFZhbHVlcw=="
+set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX3BhcmFtZXRlcl92YWx1ZXM=::MTgsMTgsMywyLGZhbHNlLGZhbHNlLGZhbHNlLHRydWUsOCw3LDEsMCxwaF9tdXhfY2xrLGZhbHNlLHRydWUsMiwyMCwxMDAwMCwzNjAuMCBNSHosMSxub25lLGdsYixtX2NudCxwaF9tdXhfY2xrLHRydWU=::UGFyYW1ldGVyIFZhbHVlcw=="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX21pZl9nZW5lcmF0ZQ==::ZmFsc2U=::R2VuZXJhdGUgTUlGIGZpbGU="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2VuYWJsZV9taWZfZHBz::ZmFsc2U=::RW5hYmxlIER5bmFtaWMgUGhhc2UgU2hpZnQgZm9yIE1JRiBzdHJlYW1pbmc="
set_global_assignment -entity "pll_0002" -library "pll" -name IP_COMPONENT_PARAMETER "Z3VpX2Rwc19jbnRy::QzA=::RFBTIENvdW50ZXIgU2VsZWN0aW9u"
diff --git a/rtl/pll.v b/rtl/pll.v
index 99a6b6e..aa53ca4 100644
--- a/rtl/pll.v
+++ b/rtl/pll.v
@@ -66,7 +66,7 @@ endmodule
// Retrieval info:
// Retrieval info:
// Retrieval info:
-// Retrieval info:
+// Retrieval info:
// Retrieval info:
// Retrieval info:
// Retrieval info:
diff --git a/rtl/pll/pll_0002.v b/rtl/pll/pll_0002.v
index fb60770..9566fae 100644
--- a/rtl/pll/pll_0002.v
+++ b/rtl/pll/pll_0002.v
@@ -19,7 +19,7 @@ module pll_0002(
.reference_clock_frequency("50.0 MHz"),
.operation_mode("direct"),
.number_of_clocks(1),
- .output_clock_frequency0("4.500000 MHz"),
+ .output_clock_frequency0("24.000000 MHz"),
.phase_shift0("0 ps"),
.duty_cycle0(50),
.output_clock_frequency1("0 MHz"),
diff --git a/rtl/system.v b/rtl/system.v
index 03c8768..4f46412 100644
--- a/rtl/system.v
+++ b/rtl/system.v
@@ -17,8 +17,8 @@ module system (
// 6 devices, 8 bits each - paddle 0..255
input [47:0] paddle,
- // 6 devices, 9 bits eachspinner [7:0] -128..+127, [8] - toggle with every update
- input [53:0] spinner,
+ // 6 devices, 16 bits eachspinner [7:0] -128..+127, [8] - toggle with every update, [9-15] padding
+ input [95:0] spinner,
output VGA_HS,
output VGA_VS,
@@ -45,8 +45,8 @@ wire vinit;
// Display timing module from JTFRAME
jtframe_vtimer #(
- .HB_START(VGA_WIDTH),
- .VB_START(VGA_HEIGHT)
+ .HB_START(VGA_WIDTH - 1'b1),
+ .VB_START(VGA_HEIGHT- 1'b1)
) vtimer
(
.clk(clk_sys),
@@ -62,7 +62,7 @@ jtframe_vtimer #(
);
// Character map
-wire [3:0] chpos_x = 4'd9 - hcnt[2:0];
+wire [3:0] chpos_x = 4'd7 - hcnt[2:0];
wire [2:0] chpos_y = vcnt[2:0];
wire [5:0] chram_x = hcnt[8:3];
wire [5:0] chram_y = vcnt[8:3];
@@ -118,7 +118,7 @@ wire [7:0] in0_data_out = {VGA_HS, VGA_VS, 6'b101000};
wire [7:0] joystick_data_out = joystick[cpu_addr[7:0] +: 8];
wire [7:0] analog_data_out = analog[cpu_addr[6:0] +: 8];
wire [7:0] paddle_data_out = paddle[cpu_addr[5:0] +: 8];
-wire [7:0] spinner_data_out = spinner[cpu_addr[5:0] +: 8];
+wire [7:0] spinner_data_out = spinner[cpu_addr[6:0] +: 8];
// CPU address decodes
wire pgrom_cs = cpu_addr[15:14] == 2'b00;
@@ -140,6 +140,7 @@ always @(posedge clk_sys) begin
// if(in0_cs) $display("%x in0 i %x o %x", cpu_addr, cpu_dout, in0_data_out);
//if(joystick_cs) $display("joystick %b %b", joystick_bit, joystick_data_out);
//if(analog_cs) $display("analog %b %b", analog_bit, analog_data_out);
+ //if(paddle_cs) $display("paddle %b", paddle_data_out);
// $display("%x", cpu_addr);
end
diff --git a/src/boot_rom.asm b/src/boot_rom.asm
index 5f89a68..cb41f01 100644
--- a/src/boot_rom.asm
+++ b/src/boot_rom.asm
@@ -25,6 +25,8 @@
.globl _chram_size
.globl _colram
.globl _chram
+ .globl _spinner
+ .globl _paddle
.globl _analog
.globl _joystick
.globl _input0
@@ -40,6 +42,8 @@
_input0 = 0x6000
_joystick = 0x7000
_analog = 0x7100
+_paddle = 0x7200
+_spinner = 0x7300
_chram = 0x8000
_colram = 0x8800
_chram_size::
@@ -80,12 +84,12 @@ _asc_1::
; code
;--------------------------------------------------------
.area _CODE
-;boot_rom.c:22: void clear_chars()
+;boot_rom.c:24: void clear_chars()
; ---------------------------------
; Function clear_chars
; ---------------------------------
_clear_chars::
-;boot_rom.c:24: for (unsigned int p = 0; p < chram_size; p++)
+;boot_rom.c:26: for (unsigned int p = 0; p < chram_size; p++)
ld bc, #0x0000
00103$:
ld hl, #_chram_size
@@ -95,19 +99,19 @@ _clear_chars::
inc hl
sbc a, (hl)
ret NC
-;boot_rom.c:26: chram[p] = 0;
+;boot_rom.c:28: chram[p] = 0;
ld hl, #_chram+0
add hl, bc
ld (hl), #0x00
-;boot_rom.c:24: for (unsigned int p = 0; p < chram_size; p++)
+;boot_rom.c:26: for (unsigned int p = 0; p < chram_size; p++)
inc bc
-;boot_rom.c:28: }
+;boot_rom.c:30: }
jr 00103$
_chram_cols:
.db #0x40 ; 64
_chram_rows:
.db #0x20 ; 32
-;boot_rom.c:30: void write_string(const char *string, char color, unsigned int x, unsigned int y)
+;boot_rom.c:32: void write_string(const char *string, char color, unsigned int x, unsigned int y)
; ---------------------------------
; Function write_string
; ---------------------------------
@@ -116,7 +120,7 @@ _write_string::
ld ix,#0
add ix,sp
push af
-;boot_rom.c:32: unsigned int p = (y * chram_cols) + x;
+;boot_rom.c:34: unsigned int p = (y * chram_cols) + x;
ld hl,#_chram_cols + 0
ld c, (hl)
ld b, #0x00
@@ -133,20 +137,20 @@ _write_string::
ld h, 8 (ix)
add hl, bc
ex de,hl
-;boot_rom.c:33: unsigned char l = strlen(string);
+;boot_rom.c:35: unsigned char l = strlen(string);
ld l, 4 (ix)
ld h, 5 (ix)
push hl
call _strlen
pop af
ld c, l
-;boot_rom.c:34: for (char c = 0; c < l; c++)
+;boot_rom.c:36: for (char c = 0; c < l; c++)
ld b, #0x00
00103$:
ld a, b
sub a, c
jr NC,00105$
-;boot_rom.c:36: chram[p] = string[c];
+;boot_rom.c:38: chram[p] = string[c];
ld hl, #_chram
add hl, de
ex (sp), hl
@@ -160,22 +164,22 @@ _write_string::
pop hl
push hl
ld (hl), a
-;boot_rom.c:37: colram[p] = color;
+;boot_rom.c:39: colram[p] = color;
ld hl, #_colram
add hl, de
ld a, 6 (ix)
ld (hl), a
-;boot_rom.c:38: p++;
+;boot_rom.c:40: p++;
inc de
-;boot_rom.c:34: for (char c = 0; c < l; c++)
+;boot_rom.c:36: for (char c = 0; c < l; c++)
inc b
jr 00103$
00105$:
-;boot_rom.c:40: }
+;boot_rom.c:42: }
ld sp, ix
pop ix
ret
-;boot_rom.c:42: void write_char(unsigned char c, char color, unsigned int x, unsigned int y)
+;boot_rom.c:44: void write_char(unsigned char c, char color, unsigned int x, unsigned int y)
; ---------------------------------
; Function write_char
; ---------------------------------
@@ -183,7 +187,7 @@ _write_char::
push ix
ld ix,#0
add ix,sp
-;boot_rom.c:44: unsigned int p = (y * chram_cols) + x;
+;boot_rom.c:46: unsigned int p = (y * chram_cols) + x;
ld hl,#_chram_cols + 0
ld c, (hl)
ld b, #0x00
@@ -201,20 +205,20 @@ _write_char::
add hl, bc
ld c, l
ld b, h
-;boot_rom.c:45: chram[p] = c;
+;boot_rom.c:47: chram[p] = c;
ld hl, #_chram+0
add hl, bc
ld a, 4 (ix)
ld (hl), a
-;boot_rom.c:46: colram[p] = color;
+;boot_rom.c:48: colram[p] = color;
ld hl, #_colram+0
add hl, bc
ld a, 5 (ix)
ld (hl), a
-;boot_rom.c:47: }
+;boot_rom.c:49: }
pop ix
ret
-;boot_rom.c:49: void page_border(char color)
+;boot_rom.c:51: void page_border(char color)
; ---------------------------------
; Function page_border
; ---------------------------------
@@ -222,7 +226,7 @@ _page_border::
push ix
ld ix,#0
add ix,sp
-;boot_rom.c:51: write_char(128, color, 0, 0);
+;boot_rom.c:53: write_char(128, color, 0, 0);
ld hl, #0x0000
push hl
ld l, #0x00
@@ -234,7 +238,7 @@ _page_border::
ld hl, #6
add hl, sp
ld sp, hl
-;boot_rom.c:52: write_char(130, color, 39, 0);
+;boot_rom.c:54: write_char(130, color, 39, 0);
ld hl, #0x0000
push hl
ld l, #0x27
@@ -246,7 +250,7 @@ _page_border::
ld hl, #6
add hl, sp
ld sp, hl
-;boot_rom.c:53: write_char(133, color, 0, 29);
+;boot_rom.c:55: write_char(133, color, 0, 29);
ld hl, #0x001d
push hl
ld l, #0x00
@@ -258,7 +262,7 @@ _page_border::
ld hl, #6
add hl, sp
ld sp, hl
-;boot_rom.c:54: write_char(132, color, 39, 29);
+;boot_rom.c:56: write_char(132, color, 39, 29);
ld hl, #0x001d
push hl
ld l, #0x27
@@ -270,13 +274,13 @@ _page_border::
ld hl, #6
add hl, sp
ld sp, hl
-;boot_rom.c:55: for (char x = 1; x < 39; x++)
+;boot_rom.c:57: for (char x = 1; x < 39; x++)
ld c, #0x01
00104$:
ld a, c
sub a, #0x27
jr NC,00101$
-;boot_rom.c:57: write_char(129, color, x, 0);
+;boot_rom.c:59: write_char(129, color, x, 0);
ld e, c
ld d, #0x00
push bc
@@ -303,17 +307,17 @@ _page_border::
add hl, sp
ld sp, hl
pop bc
-;boot_rom.c:55: for (char x = 1; x < 39; x++)
+;boot_rom.c:57: for (char x = 1; x < 39; x++)
inc c
jr 00104$
00101$:
-;boot_rom.c:60: for (char y = 1; y < 29; y++)
+;boot_rom.c:62: for (char y = 1; y < 29; y++)
ld c, #0x01
00107$:
ld a, c
sub a, #0x1d
jr NC,00109$
-;boot_rom.c:62: write_char(131, color, 0, y);
+;boot_rom.c:64: write_char(131, color, 0, y);
ld e, c
ld d, #0x00
push bc
@@ -338,14 +342,14 @@ _page_border::
add hl, sp
ld sp, hl
pop bc
-;boot_rom.c:60: for (char y = 1; y < 29; y++)
+;boot_rom.c:62: for (char y = 1; y < 29; y++)
inc c
jr 00107$
00109$:
-;boot_rom.c:65: }
+;boot_rom.c:67: }
pop ix
ret
-;boot_rom.c:67: void page_inputs()
+;boot_rom.c:69: void page_inputs()
; ---------------------------------
; Function page_inputs
; ---------------------------------
@@ -353,18 +357,18 @@ _page_inputs::
push ix
ld ix,#0
add ix,sp
- ld hl, #-10
+ ld hl, #-21
add hl, sp
ld sp, hl
-;boot_rom.c:69: clear_chars();
+;boot_rom.c:71: clear_chars();
call _clear_chars
-;boot_rom.c:70: page_border(0b00000111);
+;boot_rom.c:72: page_border(0b00000111);
ld a, #0x07
push af
inc sp
call _page_border
inc sp
-;boot_rom.c:71: write_string("UDLRABCXYZLRSs", 0xFF, 7, 3);
+;boot_rom.c:73: write_string("UDLRABCXYZLRSs", 0xFF, 7, 3);
ld hl, #0x0003
push hl
ld l, #0x07
@@ -378,10 +382,10 @@ _page_inputs::
ld hl, #7
add hl, sp
ld sp, hl
-;boot_rom.c:72: write_string("AX AY", 0xFF, 25, 3);
+;boot_rom.c:74: write_string("AX", 0xFF, 26, 3);
ld hl, #0x0003
push hl
- ld l, #0x19
+ ld l, #0x1a
push hl
ld a, #0xff
push af
@@ -392,66 +396,170 @@ _page_inputs::
ld hl, #7
add hl, sp
ld sp, hl
-;boot_rom.c:75: for (unsigned char j = 0; j < 6; j++)
- ld hl, #0x0000
- add hl, sp
- ld -3 (ix), l
- ld -2 (ix), h
- ld a, -3 (ix)
- ld -5 (ix), a
- ld a, -2 (ix)
- ld -4 (ix), a
- ld -1 (ix), #0x00
-00103$:
- ld a, -1 (ix)
- sub a, #0x06
- jr NC,00105$
-;boot_rom.c:77: sprintf(label, "JOY%d", j + 1);
- ld c, -1 (ix)
- ld b, #0x00
- ld e, c
- ld d, b
- inc de
- ld l, -3 (ix)
- ld h, -2 (ix)
- push bc
- push de
- ld de, #___str_2
- push de
+;boot_rom.c:75: write_string("AY", 0xFF, 31, 3);
+ ld hl, #0x0003
+ push hl
+ ld l, #0x1f
push hl
- call _sprintf
- ld hl, #6
- add hl, sp
- ld sp, hl
- pop bc
-;boot_rom.c:78: write_string(label, 0xFF - (j*2), 2, 4 + j);
- inc bc
- inc bc
- inc bc
- inc bc
- ld a, -1 (ix)
- add a, a
- ld e, a
ld a, #0xff
- sub a, e
- ld h, a
- ld e, -5 (ix)
- ld d, -4 (ix)
- push bc
- ld bc, #0x0002
- push bc
- push hl
+ push af
inc sp
- push de
+ ld hl, #___str_2
+ push hl
call _write_string
ld hl, #7
add hl, sp
ld sp, hl
-;boot_rom.c:75: for (unsigned char j = 0; j < 6; j++)
+;boot_rom.c:78: for (unsigned char j = 0; j < 6; j++)
+ ld hl, #0x0000
+ add hl, sp
+ ex de, hl
+ ld -6 (ix), e
+ ld -5 (ix), d
+ ld -4 (ix), e
+ ld -3 (ix), d
+ ld -12 (ix), e
+ ld -11 (ix), d
+ ld -14 (ix), e
+ ld -13 (ix), d
+ ld -16 (ix), e
+ ld -15 (ix), d
+ ld -1 (ix), #0x00
+00103$:
+ ld a, -1 (ix)
+ sub a, #0x06
+ jp NC, 00105$
+;boot_rom.c:80: sprintf(label, "JOY%d", j + 1);
+ ld a, -1 (ix)
+ ld -8 (ix), a
+ ld -7 (ix), #0x00
+ ld a, -8 (ix)
+ add a, #0x01
+ ld -10 (ix), a
+ ld a, -7 (ix)
+ adc a, #0x00
+ ld -9 (ix), a
+ ld c, e
+ ld b, d
+ push de
+ ld l, -10 (ix)
+ ld h, -9 (ix)
+ push hl
+ ld hl, #___str_3
+ push hl
+ push bc
+ call _sprintf
+ ld hl, #6
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:81: write_string(label, 0xFF - (j * 2), 2, 4 + j);
+ ld a, -8 (ix)
+ add a, #0x04
+ ld l, a
+ ld a, -7 (ix)
+ adc a, #0x00
+ ld h, a
+ ld a, -1 (ix)
+ add a, a
+ ld c, a
+ ld a, #0xff
+ sub a, c
+ ld -2 (ix), a
+ ld c, -6 (ix)
+ ld b, -5 (ix)
+ push de
+ push hl
+ ld hl, #0x0002
+ push hl
+ ld a, -2 (ix)
+ push af
+ inc sp
+ push bc
+ call _write_string
+ ld hl, #7
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:83: sprintf(label, "PAD%d", j + 1);
+ ld c, -4 (ix)
+ ld b, -3 (ix)
+ push de
+ ld l, -10 (ix)
+ ld h, -9 (ix)
+ push hl
+ ld hl, #___str_4
+ push hl
+ push bc
+ call _sprintf
+ ld hl, #6
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:84: write_string(label, 0xFF - (j * 2), 2, 11 + j);
+ ld a, -8 (ix)
+ add a, #0x0b
+ ld l, a
+ ld a, -7 (ix)
+ adc a, #0x00
+ ld h, a
+ ld c, -12 (ix)
+ ld b, -11 (ix)
+ push de
+ push hl
+ ld hl, #0x0002
+ push hl
+ ld a, -2 (ix)
+ push af
+ inc sp
+ push bc
+ call _write_string
+ ld hl, #7
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:86: sprintf(label, "SPN%d", j + 1);
+ ld c, -14 (ix)
+ ld b, -13 (ix)
+ push de
+ ld l, -10 (ix)
+ ld h, -9 (ix)
+ push hl
+ ld hl, #___str_5
+ push hl
+ push bc
+ call _sprintf
+ ld hl, #6
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:87: write_string(label, 0xFF - (j * 2), 2, 18 + j);
+ ld a, -8 (ix)
+ add a, #0x12
+ ld l, a
+ ld a, -7 (ix)
+ adc a, #0x00
+ ld h, a
+ ld c, -16 (ix)
+ ld b, -15 (ix)
+ push de
+ push hl
+ ld hl, #0x0002
+ push hl
+ ld a, -2 (ix)
+ push af
+ inc sp
+ push bc
+ call _write_string
+ ld hl, #7
+ add hl, sp
+ ld sp, hl
+ pop de
+;boot_rom.c:78: for (unsigned char j = 0; j < 6; j++)
inc -1 (ix)
- jr 00103$
+ jp 00103$
00105$:
-;boot_rom.c:80: }
+;boot_rom.c:89: }
ld sp, ix
pop ix
ret
@@ -459,12 +567,21 @@ ___str_0:
.ascii "UDLRABCXYZLRSs"
.db 0x00
___str_1:
- .ascii "AX AY"
+ .ascii "AX"
.db 0x00
___str_2:
+ .ascii "AY"
+ .db 0x00
+___str_3:
.ascii "JOY%d"
.db 0x00
-;boot_rom.c:85: void main()
+___str_4:
+ .ascii "PAD%d"
+ .db 0x00
+___str_5:
+ .ascii "SPN%d"
+ .db 0x00
+;boot_rom.c:94: void main()
; ---------------------------------
; Function main
; ---------------------------------
@@ -472,10 +589,10 @@ _main::
push ix
ld ix,#0
add ix,sp
- ld hl, #-24
+ ld hl, #-27
add hl, sp
ld sp, hl
-;boot_rom.c:87: chram_size = chram_cols * chram_rows;
+;boot_rom.c:96: chram_size = chram_cols * chram_rows;
ld hl,#_chram_rows + 0
ld e, (hl)
ld hl,#_chram_cols + 0
@@ -483,130 +600,131 @@ _main::
ld l, #0x00
ld d, l
ld b, #0x08
-00191$:
+00212$:
add hl, hl
- jr NC,00192$
+ jr NC,00213$
add hl, de
-00192$:
- djnz 00191$
+00213$:
+ djnz 00212$
ld (_chram_size), hl
-;boot_rom.c:89: page_inputs();
+;boot_rom.c:98: page_inputs();
call _page_inputs
-;boot_rom.c:91: while (1)
- ld -5 (ix), #0xab
-00109$:
-;boot_rom.c:93: hsync = input0 & 0x80;
+;boot_rom.c:100: while (1)
+ ld c, #0xab
+00111$:
+;boot_rom.c:102: hsync = input0 & 0x80;
ld a,(#_input0 + 0)
and a, #0x80
ld (#_hsync + 0),a
-;boot_rom.c:94: vsync = input0 & 0x40;
+;boot_rom.c:103: vsync = input0 & 0x40;
ld a,(#_input0 + 0)
and a, #0x40
ld iy, #_vsync
ld 0 (iy), a
-;boot_rom.c:99: if (vsync && !vsync_last)
+;boot_rom.c:110: if (vsync && !vsync_last)
ld a, 0 (iy)
or a, a
- jp Z, 00106$
+ jp Z, 00108$
ld a,(#_vsync_last + 0)
or a, a
- jp NZ, 00106$
-;boot_rom.c:101: color++;
- inc -5 (ix)
-;boot_rom.c:102: write_string("--- MiSTer Input Tester ---", color, 6, 1);
+ jp NZ, 00108$
+;boot_rom.c:112: color++;
+ inc c
+;boot_rom.c:113: write_string("--- MiSTer Input Tester ---", color, 6, 1);
+ push bc
ld hl, #0x0001
push hl
ld l, #0x06
push hl
- ld a, -5 (ix)
+ ld a, c
push af
inc sp
- ld hl, #___str_3
+ ld hl, #___str_6
push hl
call _write_string
ld hl, #7
add hl, sp
ld sp, hl
-;boot_rom.c:104: for (char b = 0; b < 2; b++)
- ld c, #0x00
-00118$:
- ld a, c
+ pop bc
+;boot_rom.c:115: for (char b = 0; b < 2; b++)
+ ld e, #0x00
+00119$:
+ ld a, e
sub a, #0x02
jp NC, 00103$
-;boot_rom.c:106: char m = 0b00000001;
- ld b, #0x01
-;boot_rom.c:107: for (char i = 0; i < 8; i++)
- ld e, #0x00
-00115$:
-;boot_rom.c:109: char x = 7 + i + (b * 8);
- ld a,e
- cp a,#0x08
- jp NC,00119$
+;boot_rom.c:117: char m = 0b00000001;
+ ld -2 (ix), #0x01
+;boot_rom.c:118: for (char i = 0; i < 8; i++)
+ ld -3 (ix), #0x00
+00116$:
+ ld a, -3 (ix)
+ sub a, #0x08
+ jp NC, 00120$
+;boot_rom.c:120: char x = 7 + i + (b * 8);
+ ld a, -3 (ix)
add a, #0x07
- ld d, a
- ld a, c
+ ld b, a
+ ld a, e
add a, a
add a, a
add a, a
+ ld -7 (ix), a
+ ld a, b
+ add a, -7 (ix)
ld -6 (ix), a
- ld a, d
- add a, -6 (ix)
- ld -1 (ix), a
-;boot_rom.c:110: for (char j = 0; j < 6; j++)
- ld -4 (ix), #0x00
-00112$:
- ld a, -4 (ix)
- sub a, #0x06
- jr NC,00101$
-;boot_rom.c:112: write_char((joystick[(b * 8) + (j * 32)] & m) ? asc_1 : asc_0, 0xFF, x, 4 + j);
- ld a, -4 (ix)
- ld l, #0x00
- add a, #0x04
- ld -14 (ix), a
- ld a, l
- adc a, #0x00
- ld -13 (ix), a
+;boot_rom.c:121: for (j = 0; j < 6; j++)
+ ld -1 (ix), #0x00
+00113$:
+;boot_rom.c:123: write_char((joystick[(b * 8) + (j * 32)] & m) ? asc_1 : asc_0, 0xFF, x, 4 + j);
+ ld a, -1 (ix)
+ ld d, #0x00
+ add a, #0x04
+ ld -11 (ix), a
+ ld a, d
+ adc a, #0x00
+ ld -10 (ix), a
+ ld a, -6 (ix)
+ ld -9 (ix), a
+ ld -8 (ix), #0x00
ld a, -1 (ix)
- ld -16 (ix), a
- ld -15 (ix), #0x00
- ld a, -4 (ix)
rrca
rrca
rrca
and a, #0xe0
- add a, -6 (ix)
- ld d, a
+ add a, -7 (ix)
+ ld b, a
rla
sbc a, a
- ld h, a
+ ld d, a
ld a, #<(_joystick)
- add a, d
+ add a, b
ld l, a
ld a, #>(_joystick)
- adc a, h
+ adc a, d
ld h, a
ld a, (hl)
- and a,b
- jr Z,00125$
+ and a, -2 (ix)
+ or a, a
+ jr Z,00129$
ld hl,#_asc_1 + 0
- ld d, (hl)
- jr 00126$
-00125$:
+ ld b, (hl)
+ jr 00130$
+00129$:
ld hl,#_asc_0 + 0
- ld d, (hl)
-00126$:
+ ld b, (hl)
+00130$:
push bc
push de
- ld l, -14 (ix)
- ld h, -13 (ix)
+ ld l, -11 (ix)
+ ld h, -10 (ix)
push hl
- ld l, -16 (ix)
- ld h, -15 (ix)
+ ld l, -9 (ix)
+ ld h, -8 (ix)
push hl
ld a, #0xff
push af
inc sp
- push de
+ push bc
inc sp
call _write_char
ld hl, #6
@@ -614,130 +732,103 @@ _main::
ld sp, hl
pop de
pop bc
-;boot_rom.c:110: for (char j = 0; j < 6; j++)
- inc -4 (ix)
- jr 00112$
-00101$:
-;boot_rom.c:114: m <<= 1;
- sla b
-;boot_rom.c:107: for (char i = 0; i < 8; i++)
+;boot_rom.c:121: for (j = 0; j < 6; j++)
+ inc -1 (ix)
+ ld a, -1 (ix)
+ sub a, #0x06
+ jr C,00113$
+;boot_rom.c:125: m <<= 1;
+ ld a, -2 (ix)
+ add a, a
+ ld -2 (ix), a
+;boot_rom.c:118: for (char i = 0; i < 8; i++)
+ inc -3 (ix)
+ jp 00116$
+00120$:
+;boot_rom.c:115: for (char b = 0; b < 2; b++)
inc e
- jp 00115$
-00119$:
-;boot_rom.c:104: for (char b = 0; b < 2; b++)
- inc c
- jp 00118$
+ jp 00119$
00103$:
-;boot_rom.c:120: char m = 0b00000001;
- ld -16 (ix), #0x01
-;boot_rom.c:123: for (char j = 0; j < 6; j++)
- ld hl, #0x0004
+;boot_rom.c:129: y = 4;
+ ld -5 (ix), #0x04
+ ld -4 (ix), #0x00
+;boot_rom.c:131: char m = 0b00000001;
+ ld b, #0x01
+;boot_rom.c:134: for (j = 0; j < 6; j++)
+ ld hl, #0x0006
add hl, sp
- ld -14 (ix), l
- ld -13 (ix), h
- ld a, -14 (ix)
- ld -8 (ix), a
- ld a, -13 (ix)
- ld -7 (ix), a
- ld hl, #0x0000
- add hl, sp
- ld -10 (ix), l
- ld -9 (ix), h
- ld a, -10 (ix)
- ld -12 (ix), a
+ ld -9 (ix), l
+ ld -8 (ix), h
ld a, -9 (ix)
ld -11 (ix), a
- ld -2 (ix), #0x00
+ ld a, -8 (ix)
+ ld -10 (ix), a
+ ld -1 (ix), #0x00
00121$:
- ld a, -2 (ix)
- sub a, #0x06
- jp NC, 00106$
-;boot_rom.c:125: signed char jx = analog[(j * 16)];
- ld l, -2 (ix)
+;boot_rom.c:136: signed char jx = analog[(j * 16)];
+ ld de, #_analog+0
+ ld l, -1 (ix)
ld h, #0x00
add hl, hl
add hl, hl
add hl, hl
add hl, hl
- ld de, #_analog
add hl, de
- ld c, (hl)
-;boot_rom.c:126: signed char jy = analog[(j * 16) + 8];
- ld a, -2 (ix)
+ ld e, (hl)
+;boot_rom.c:137: signed char jy = analog[(j * 16) + 8];
+ ld a, -1 (ix)
rlca
rlca
rlca
rlca
and a, #0xf0
add a, #0x08
- ld e, a
+ ld l, a
rla
sbc a, a
- ld d, a
- ld hl, #_analog
+ ld h, a
+ push de
+ ld de, #_analog
add hl, de
+ pop de
ld a, (hl)
- ld -3 (ix), a
-;boot_rom.c:128: sprintf(str1, "%4d", jx);
- ld a, c
+;boot_rom.c:139: sprintf(stra, "%4d %4d", jx, jy);
+ ld l, a
rla
sbc a, a
- ld b, a
- ld e, -14 (ix)
- ld d, -13 (ix)
- push bc
- ld hl, #___str_4
- push hl
- push de
- call _sprintf
- ld hl, #6
- add hl, sp
- ld sp, hl
-;boot_rom.c:129: write_string(str1, 0xFF, 23, y + j);
- ld c, -2 (ix)
- ld b, #0x00
- inc bc
- inc bc
- inc bc
- inc bc
- ld e, -8 (ix)
- ld d, -7 (ix)
- push bc
- push bc
- ld hl, #0x0017
- push hl
- ld a, #0xff
- push af
- inc sp
- push de
- call _write_string
- ld hl, #7
- add hl, sp
- ld sp, hl
- pop bc
-;boot_rom.c:130: sprintf(str2, "%-4d", jy);
- ld a, -3 (ix)
- ld e, a
+ ld h, a
+ ld a, e
rla
sbc a, a
ld d, a
- ld l, -10 (ix)
- ld h, -9 (ix)
- push bc
- push de
- ld de, #___str_5
- push de
push hl
+ ld l, -9 (ix)
+ ld h, -8 (ix)
+ push hl
+ pop iy
+ pop hl
+ push bc
+ push hl
+ push de
+ ld hl, #___str_7
+ push hl
+ push iy
call _sprintf
- ld hl, #6
+ ld hl, #8
add hl, sp
ld sp, hl
pop bc
-;boot_rom.c:131: write_string(str2, 0xFF, 28, y + j);
- ld e, -12 (ix)
- ld d, -11 (ix)
+;boot_rom.c:140: write_string(stra, 0xFF, 24, y + j);
+ ld e, -1 (ix)
+ ld d, #0x00
+ ld l, -5 (ix)
+ ld h, -4 (ix)
+ add hl, de
+ ld e, -11 (ix)
+ ld d, -10 (ix)
push bc
- ld hl, #0x001c
+ push hl
+ ld hl, #0x0018
push hl
ld a, #0xff
push af
@@ -747,30 +838,181 @@ _main::
ld hl, #7
add hl, sp
ld sp, hl
-;boot_rom.c:132: m <<= 1;
- ld a, -16 (ix)
- add a, a
- ld -16 (ix), a
-;boot_rom.c:123: for (char j = 0; j < 6; j++)
- inc -2 (ix)
- jp 00121$
-00106$:
-;boot_rom.c:135: hsync_last = hsync;
+ pop bc
+;boot_rom.c:143: m <<= 1;
+ sla b
+;boot_rom.c:134: for (j = 0; j < 6; j++)
+ inc -1 (ix)
+ ld a, -1 (ix)
+ sub a, #0x06
+ jr C,00121$
+;boot_rom.c:148: m = 0b00000001;
+ ld b, #0x01
+;boot_rom.c:150: for (j = 0; j < 6; j++)
+ ld hl, #0x0003
+ add hl, sp
+ ld -9 (ix), l
+ ld -8 (ix), h
+ ld a, -9 (ix)
+ ld -11 (ix), a
+ ld a, -8 (ix)
+ ld -10 (ix), a
+ ld -1 (ix), #0x00
+00123$:
+;boot_rom.c:152: char px = paddle[(j * 8)];
+ ld e, -1 (ix)
+ ld d, #0x00
+ ld l, e
+ ld h, d
+ add hl, hl
+ add hl, hl
+ add hl, hl
+ ld a, #<(_paddle)
+ add a, l
+ ld l, a
+ ld a, #>(_paddle)
+ adc a, h
+ ld h, a
+ ld l, (hl)
+;boot_rom.c:153: sprintf(strp, "%4d", px);
+ ld h, #0x00
+ push hl
+ ld l, -9 (ix)
+ ld h, -8 (ix)
+ push hl
+ pop iy
+ pop hl
+ push bc
+ push de
+ push hl
+ ld hl, #___str_8
+ push hl
+ push iy
+ call _sprintf
+ ld hl, #6
+ add hl, sp
+ ld sp, hl
+ pop de
+ pop bc
+;boot_rom.c:154: write_string(strp, 0xFF, 6, y + j);
+ ld hl, #0x000b
+ add hl, de
+ ld e, -11 (ix)
+ ld d, -10 (ix)
+ push bc
+ push hl
+ ld hl, #0x0006
+ push hl
+ ld a, #0xff
+ push af
+ inc sp
+ push de
+ call _write_string
+ ld hl, #7
+ add hl, sp
+ ld sp, hl
+ pop bc
+;boot_rom.c:155: m <<= 1;
+ sla b
+;boot_rom.c:150: for (j = 0; j < 6; j++)
+ inc -1 (ix)
+ ld a, -1 (ix)
+ sub a, #0x06
+ jr C,00123$
+;boot_rom.c:160: m = 0b00000001;
+ ld b, #0x01
+;boot_rom.c:162: for (j = 0; j < 6; j++)
+ ld hl, #0x0000
+ add hl, sp
+ ld -9 (ix), l
+ ld -8 (ix), h
+ ld a, -9 (ix)
+ ld -11 (ix), a
+ ld a, -8 (ix)
+ ld -10 (ix), a
+ ld -1 (ix), #0x00
+00125$:
+;boot_rom.c:164: signed char sx = spinner[(j * 16)];
+ ld e, -1 (ix)
+ ld d, #0x00
+ ld l, e
+ ld h, d
+ add hl, hl
+ add hl, hl
+ add hl, hl
+ add hl, hl
+ ld a, #<(_spinner)
+ add a, l
+ ld l, a
+ ld a, #>(_spinner)
+ adc a, h
+ ld h, a
+ ld a, (hl)
+;boot_rom.c:165: sprintf(strs, "%4d", sx);
+ ld l, a
+ rla
+ sbc a, a
+ ld h, a
+ push hl
+ ld l, -9 (ix)
+ ld h, -8 (ix)
+ push hl
+ pop iy
+ pop hl
+ push bc
+ push de
+ push hl
+ ld hl, #___str_8
+ push hl
+ push iy
+ call _sprintf
+ ld hl, #6
+ add hl, sp
+ ld sp, hl
+ pop de
+ pop bc
+;boot_rom.c:166: write_string(strs, 0xFF, 7, y + j);
+ ld hl, #0x0012
+ add hl, de
+ ld e, -11 (ix)
+ ld d, -10 (ix)
+ push bc
+ push hl
+ ld hl, #0x0007
+ push hl
+ ld a, #0xff
+ push af
+ inc sp
+ push de
+ call _write_string
+ ld hl, #7
+ add hl, sp
+ ld sp, hl
+ pop bc
+;boot_rom.c:167: m <<= 1;
+ sla b
+;boot_rom.c:162: for (j = 0; j < 6; j++)
+ inc -1 (ix)
+ ld a, -1 (ix)
+ sub a, #0x06
+ jr C,00125$
+00108$:
+;boot_rom.c:171: hsync_last = hsync;
ld a,(#_hsync + 0)
ld (#_hsync_last + 0),a
-;boot_rom.c:136: vsync_last = vsync;
+;boot_rom.c:172: vsync_last = vsync;
ld a,(#_vsync + 0)
ld (#_vsync_last + 0),a
-;boot_rom.c:138: }
- jp 00109$
-___str_3:
+;boot_rom.c:174: }
+ jp 00111$
+___str_6:
.ascii "--- MiSTer Input Tester ---"
.db 0x00
-___str_4:
- .ascii "%4d"
+___str_7:
+ .ascii "%4d %4d"
.db 0x00
-___str_5:
- .ascii "%-4d"
+___str_8:
+ .ascii "%4d"
.db 0x00
.area _CODE
.area _INITIALIZER
diff --git a/src/boot_rom.bin b/src/boot_rom.bin
index 254038d..e3a13f5 100644
Binary files a/src/boot_rom.bin and b/src/boot_rom.bin differ
diff --git a/src/boot_rom.c b/src/boot_rom.c
index acf5d51..ee3a986 100644
--- a/src/boot_rom.c
+++ b/src/boot_rom.c
@@ -5,7 +5,9 @@
// Memory maps
unsigned char __at(0x6000) input0;
unsigned char __at(0x7000) joystick[24];
-unsigned char __at(0x7100) analog[24];
+unsigned char __at(0x7100) analog[12];
+unsigned char __at(0x7200) paddle[6];
+unsigned char __at(0x7300) spinner[12];
unsigned char __at(0x8000) chram[2048];
unsigned char __at(0x8800) colram[2048];
@@ -69,13 +71,20 @@ void page_inputs()
clear_chars();
page_border(0b00000111);
write_string("UDLRABCXYZLRSs", 0xFF, 7, 3);
- write_string("AX AY", 0xFF, 25, 3);
+ write_string("AX", 0xFF, 26, 3);
+ write_string("AY", 0xFF, 31, 3);
char label[5];
for (unsigned char j = 0; j < 6; j++)
{
sprintf(label, "JOY%d", j + 1);
- write_string(label, 0xFF - (j*2), 2, 4 + j);
+ write_string(label, 0xFF - (j * 2), 2, 4 + j);
+
+ sprintf(label, "PAD%d", j + 1);
+ write_string(label, 0xFF - (j * 2), 2, 11 + j);
+
+ sprintf(label, "SPN%d", j + 1);
+ write_string(label, 0xFF - (j * 2), 2, 18 + j);
}
}
@@ -96,6 +105,8 @@ void main()
// if(hsync && !hsync_last){
// }
+ char j = 0;
+
if (vsync && !vsync_last)
{
color++;
@@ -107,7 +118,7 @@ void main()
for (char i = 0; i < 8; i++)
{
char x = 7 + i + (b * 8);
- for (char j = 0; j < 6; j++)
+ for (j = 0; j < 6; j++)
{
write_char((joystick[(b * 8) + (j * 32)] & m) ? asc_1 : asc_0, 0xFF, x, 4 + j);
}
@@ -116,26 +127,47 @@ void main()
}
y = 4;
-
+ // ANALOG
char m = 0b00000001;
- char str1[4];
- char str2[4];
- for (char j = 0; j < 6; j++)
+ char stra[10];
+ // char stra2[5];
+ for (j = 0; j < 6; j++)
{
signed char jx = analog[(j * 16)];
signed char jy = analog[(j * 16) + 8];
-
- sprintf(str1, "%4d", jx);
- write_string(str1, 0xFF, 23, y + j);
- sprintf(str2, "%-4d", jy);
- write_string(str2, 0xFF, 28, y + j);
+
+ sprintf(stra, "%4d %4d", jx, jy);
+ write_string(stra, 0xFF, 24, y + j);
+ // sprintf(stra2, "%-4d", jy);
+ // write_string(stra2, 0xFF, 29, y + j);
m <<= 1;
}
+ // PADDLE
+ y = 11;
+ m = 0b00000001;
+ char strp[3];
+ for (j = 0; j < 6; j++)
+ {
+ char px = paddle[(j * 8)];
+ sprintf(strp, "%4d", px);
+ write_string(strp, 0xFF, 6, y + j);
+ m <<= 1;
+ }
-// ADD THE PADDLES AND SPINNERS HERE
-
+ // SPINNER
+ y = 18;
+ m = 0b00000001;
+ char strs[3];
+ for (j = 0; j < 6; j++)
+ {
+ signed char sx = spinner[(j * 16)];
+ sprintf(strs, "%4d", sx);
+ write_string(strs, 0xFF, 7, y + j);
+ m <<= 1;
+ }
}
+
hsync_last = hsync;
vsync_last = vsync;
}
diff --git a/src/boot_rom.lst b/src/boot_rom.lst
index dc32ba9..098d74c 100644
--- a/src/boot_rom.lst
+++ b/src/boot_rom.lst
@@ -25,763 +25,1006 @@
25 .globl _chram_size
26 .globl _colram
27 .globl _chram
- 28 .globl _analog
- 29 .globl _joystick
- 30 .globl _input0
- 31 .globl _chram_rows
- 32 .globl _chram_cols
- 33 ;--------------------------------------------------------
- 34 ; special function registers
+ 28 .globl _spinner
+ 29 .globl _paddle
+ 30 .globl _analog
+ 31 .globl _joystick
+ 32 .globl _input0
+ 33 .globl _chram_rows
+ 34 .globl _chram_cols
35 ;--------------------------------------------------------
- 36 ;--------------------------------------------------------
- 37 ; ram data
+ 36 ; special function registers
+ 37 ;--------------------------------------------------------
38 ;--------------------------------------------------------
- 39 .area _DATA
- 6000 40 _input0 = 0x6000
- 7000 41 _joystick = 0x7000
- 7100 42 _analog = 0x7100
- 8000 43 _chram = 0x8000
- 8800 44 _colram = 0x8800
- 0000 45 _chram_size::
- 0000 46 .ds 2
- 0002 47 _hsync::
- 0002 48 .ds 1
- 0003 49 _hsync_last::
- 0003 50 .ds 1
- 0004 51 _vsync::
- 0004 52 .ds 1
- 0005 53 _vsync_last::
- 0005 54 .ds 1
- 55 ;--------------------------------------------------------
- 56 ; ram data
- 57 ;--------------------------------------------------------
- 58 .area _INITIALIZED
- 0000 59 _asc_0::
- 0000 60 .ds 1
- 0001 61 _asc_1::
- 0001 62 .ds 1
- 63 ;--------------------------------------------------------
- 64 ; absolute external ram data
- 65 ;--------------------------------------------------------
- 66 .area _DABS (ABS)
+ 39 ; ram data
+ 40 ;--------------------------------------------------------
+ 41 .area _DATA
+ 6000 42 _input0 = 0x6000
+ 7000 43 _joystick = 0x7000
+ 7100 44 _analog = 0x7100
+ 7200 45 _paddle = 0x7200
+ 7300 46 _spinner = 0x7300
+ 8000 47 _chram = 0x8000
+ 8800 48 _colram = 0x8800
+ 0000 49 _chram_size::
+ 0000 50 .ds 2
+ 0002 51 _hsync::
+ 0002 52 .ds 1
+ 0003 53 _hsync_last::
+ 0003 54 .ds 1
+ 0004 55 _vsync::
+ 0004 56 .ds 1
+ 0005 57 _vsync_last::
+ 0005 58 .ds 1
+ 59 ;--------------------------------------------------------
+ 60 ; ram data
+ 61 ;--------------------------------------------------------
+ 62 .area _INITIALIZED
+ 0000 63 _asc_0::
+ 0000 64 .ds 1
+ 0001 65 _asc_1::
+ 0001 66 .ds 1
67 ;--------------------------------------------------------
- 68 ; global & static initialisations
+ 68 ; absolute external ram data
69 ;--------------------------------------------------------
- 70 .area _HOME
- 71 .area _GSINIT
- 72 .area _GSFINAL
- 73 .area _GSINIT
- 74 ;--------------------------------------------------------
- 75 ; Home
- 76 ;--------------------------------------------------------
- 77 .area _HOME
- 78 .area _HOME
- 79 ;--------------------------------------------------------
- 80 ; code
- 81 ;--------------------------------------------------------
- 82 .area _CODE
- 83 ;boot_rom.c:22: void clear_chars()
- 84 ; ---------------------------------
- 85 ; Function clear_chars
- 86 ; ---------------------------------
- 0000 87 _clear_chars::
- 88 ;boot_rom.c:24: for (unsigned int p = 0; p < chram_size; p++)
- 0000 01 00 00 [10] 89 ld bc, #0x0000
- 0003 90 00103$:
- 0003 21r00r00 [10] 91 ld hl, #_chram_size
- 0006 79 [ 4] 92 ld a, c
- 0007 96 [ 7] 93 sub a, (hl)
- 0008 78 [ 4] 94 ld a, b
- 0009 23 [ 6] 95 inc hl
- 000A 9E [ 7] 96 sbc a, (hl)
- 000B D0 [11] 97 ret NC
- 98 ;boot_rom.c:26: chram[p] = 0;
- 000C 21 00 80 [10] 99 ld hl, #_chram+0
- 000F 09 [11] 100 add hl, bc
- 0010 36 00 [10] 101 ld (hl), #0x00
- 102 ;boot_rom.c:24: for (unsigned int p = 0; p < chram_size; p++)
- 0012 03 [ 6] 103 inc bc
- 104 ;boot_rom.c:28: }
- 0013 18 EE [12] 105 jr 00103$
- 0015 106 _chram_cols:
- 0015 40 107 .db #0x40 ; 64
- 0016 108 _chram_rows:
- 0016 20 109 .db #0x20 ; 32
- 110 ;boot_rom.c:30: void write_string(const char *string, char color, unsigned int x, unsigned int y)
- 111 ; ---------------------------------
- 112 ; Function write_string
- 113 ; ---------------------------------
- 0017 114 _write_string::
- 0017 DD E5 [15] 115 push ix
- 0019 DD 21 00 00 [14] 116 ld ix,#0
- 001D DD 39 [15] 117 add ix,sp
- 001F F5 [11] 118 push af
- 119 ;boot_rom.c:32: unsigned int p = (y * chram_cols) + x;
- 0020 21r15r00 [10] 120 ld hl,#_chram_cols + 0
- 0023 4E [ 7] 121 ld c, (hl)
- 0024 06 00 [ 7] 122 ld b, #0x00
- 0026 C5 [11] 123 push bc
- 0027 DD 6E 09 [19] 124 ld l, 9 (ix)
- 002A DD 66 0A [19] 125 ld h, 10 (ix)
- 002D E5 [11] 126 push hl
- 002E CDr00r00 [17] 127 call __mulint
- 0031 F1 [10] 128 pop af
- 0032 F1 [10] 129 pop af
- 0033 4D [ 4] 130 ld c, l
- 0034 44 [ 4] 131 ld b, h
- 0035 DD 6E 07 [19] 132 ld l, 7 (ix)
- 0038 DD 66 08 [19] 133 ld h, 8 (ix)
- 003B 09 [11] 134 add hl, bc
- 003C EB [ 4] 135 ex de,hl
- 136 ;boot_rom.c:33: unsigned char l = strlen(string);
- 003D DD 6E 04 [19] 137 ld l, 4 (ix)
- 0040 DD 66 05 [19] 138 ld h, 5 (ix)
- 0043 E5 [11] 139 push hl
- 0044 CDr00r00 [17] 140 call _strlen
- 0047 F1 [10] 141 pop af
- 0048 4D [ 4] 142 ld c, l
- 143 ;boot_rom.c:34: for (char c = 0; c < l; c++)
- 0049 06 00 [ 7] 144 ld b, #0x00
- 004B 145 00103$:
- 004B 78 [ 4] 146 ld a, b
- 004C 91 [ 4] 147 sub a, c
- 004D 30 20 [12] 148 jr NC,00105$
- 149 ;boot_rom.c:36: chram[p] = string[c];
- 004F 21 00 80 [10] 150 ld hl, #_chram
- 0052 19 [11] 151 add hl, de
- 0053 E3 [19] 152 ex (sp), hl
- 0054 DD 7E 04 [19] 153 ld a, 4 (ix)
- 0057 80 [ 4] 154 add a, b
- 0058 6F [ 4] 155 ld l, a
- 0059 DD 7E 05 [19] 156 ld a, 5 (ix)
- 005C CE 00 [ 7] 157 adc a, #0x00
- 005E 67 [ 4] 158 ld h, a
- 005F 7E [ 7] 159 ld a, (hl)
- 0060 E1 [10] 160 pop hl
- 0061 E5 [11] 161 push hl
- 0062 77 [ 7] 162 ld (hl), a
- 163 ;boot_rom.c:37: colram[p] = color;
- 0063 21 00 88 [10] 164 ld hl, #_colram
- 0066 19 [11] 165 add hl, de
- 0067 DD 7E 06 [19] 166 ld a, 6 (ix)
- 006A 77 [ 7] 167 ld (hl), a
- 168 ;boot_rom.c:38: p++;
- 006B 13 [ 6] 169 inc de
- 170 ;boot_rom.c:34: for (char c = 0; c < l; c++)
- 006C 04 [ 4] 171 inc b
- 006D 18 DC [12] 172 jr 00103$
- 006F 173 00105$:
- 174 ;boot_rom.c:40: }
- 006F DD F9 [10] 175 ld sp, ix
- 0071 DD E1 [14] 176 pop ix
- 0073 C9 [10] 177 ret
- 178 ;boot_rom.c:42: void write_char(unsigned char c, char color, unsigned int x, unsigned int y)
- 179 ; ---------------------------------
- 180 ; Function write_char
- 181 ; ---------------------------------
- 0074 182 _write_char::
- 0074 DD E5 [15] 183 push ix
- 0076 DD 21 00 00 [14] 184 ld ix,#0
- 007A DD 39 [15] 185 add ix,sp
- 186 ;boot_rom.c:44: unsigned int p = (y * chram_cols) + x;
- 007C 21r15r00 [10] 187 ld hl,#_chram_cols + 0
- 007F 4E [ 7] 188 ld c, (hl)
- 0080 06 00 [ 7] 189 ld b, #0x00
- 0082 C5 [11] 190 push bc
- 0083 DD 6E 08 [19] 191 ld l, 8 (ix)
- 0086 DD 66 09 [19] 192 ld h, 9 (ix)
- 0089 E5 [11] 193 push hl
- 008A CDr00r00 [17] 194 call __mulint
- 008D F1 [10] 195 pop af
- 008E F1 [10] 196 pop af
- 008F 4D [ 4] 197 ld c, l
- 0090 44 [ 4] 198 ld b, h
- 0091 DD 6E 06 [19] 199 ld l, 6 (ix)
- 0094 DD 66 07 [19] 200 ld h, 7 (ix)
- 0097 09 [11] 201 add hl, bc
- 0098 4D [ 4] 202 ld c, l
- 0099 44 [ 4] 203 ld b, h
- 204 ;boot_rom.c:45: chram[p] = c;
- 009A 21 00 80 [10] 205 ld hl, #_chram+0
- 009D 09 [11] 206 add hl, bc
- 009E DD 7E 04 [19] 207 ld a, 4 (ix)
- 00A1 77 [ 7] 208 ld (hl), a
- 209 ;boot_rom.c:46: colram[p] = color;
- 00A2 21 00 88 [10] 210 ld hl, #_colram+0
- 00A5 09 [11] 211 add hl, bc
- 00A6 DD 7E 05 [19] 212 ld a, 5 (ix)
- 00A9 77 [ 7] 213 ld (hl), a
- 214 ;boot_rom.c:47: }
- 00AA DD E1 [14] 215 pop ix
- 00AC C9 [10] 216 ret
- 217 ;boot_rom.c:49: void page_border(char color)
- 218 ; ---------------------------------
- 219 ; Function page_border
- 220 ; ---------------------------------
- 00AD 221 _page_border::
- 00AD DD E5 [15] 222 push ix
- 00AF DD 21 00 00 [14] 223 ld ix,#0
- 00B3 DD 39 [15] 224 add ix,sp
- 225 ;boot_rom.c:51: write_char(128, color, 0, 0);
- 00B5 21 00 00 [10] 226 ld hl, #0x0000
- 00B8 E5 [11] 227 push hl
- 00B9 2E 00 [ 7] 228 ld l, #0x00
- 00BB E5 [11] 229 push hl
- 00BC DD 56 04 [19] 230 ld d, 4 (ix)
- 00BF 1E 80 [ 7] 231 ld e,#0x80
- 00C1 D5 [11] 232 push de
- 00C2 CDr74r00 [17] 233 call _write_char
- 00C5 21 06 00 [10] 234 ld hl, #6
- 00C8 39 [11] 235 add hl, sp
- 00C9 F9 [ 6] 236 ld sp, hl
- 237 ;boot_rom.c:52: write_char(130, color, 39, 0);
- 00CA 21 00 00 [10] 238 ld hl, #0x0000
- 00CD E5 [11] 239 push hl
- 00CE 2E 27 [ 7] 240 ld l, #0x27
- 00D0 E5 [11] 241 push hl
- 00D1 DD 56 04 [19] 242 ld d, 4 (ix)
- 00D4 1E 82 [ 7] 243 ld e,#0x82
- 00D6 D5 [11] 244 push de
- 00D7 CDr74r00 [17] 245 call _write_char
- 00DA 21 06 00 [10] 246 ld hl, #6
- 00DD 39 [11] 247 add hl, sp
- 00DE F9 [ 6] 248 ld sp, hl
- 249 ;boot_rom.c:53: write_char(133, color, 0, 29);
- 00DF 21 1D 00 [10] 250 ld hl, #0x001d
- 00E2 E5 [11] 251 push hl
- 00E3 2E 00 [ 7] 252 ld l, #0x00
- 00E5 E5 [11] 253 push hl
- 00E6 DD 56 04 [19] 254 ld d, 4 (ix)
- 00E9 1E 85 [ 7] 255 ld e,#0x85
- 00EB D5 [11] 256 push de
- 00EC CDr74r00 [17] 257 call _write_char
- 00EF 21 06 00 [10] 258 ld hl, #6
- 00F2 39 [11] 259 add hl, sp
- 00F3 F9 [ 6] 260 ld sp, hl
- 261 ;boot_rom.c:54: write_char(132, color, 39, 29);
- 00F4 21 1D 00 [10] 262 ld hl, #0x001d
- 00F7 E5 [11] 263 push hl
- 00F8 2E 27 [ 7] 264 ld l, #0x27
- 00FA E5 [11] 265 push hl
- 00FB DD 56 04 [19] 266 ld d, 4 (ix)
- 00FE 1E 84 [ 7] 267 ld e,#0x84
- 0100 D5 [11] 268 push de
- 0101 CDr74r00 [17] 269 call _write_char
- 0104 21 06 00 [10] 270 ld hl, #6
- 0107 39 [11] 271 add hl, sp
- 0108 F9 [ 6] 272 ld sp, hl
- 273 ;boot_rom.c:55: for (char x = 1; x < 39; x++)
- 0109 0E 01 [ 7] 274 ld c, #0x01
- 010B 275 00104$:
- 010B 79 [ 4] 276 ld a, c
- 010C D6 27 [ 7] 277 sub a, #0x27
- 010E 30 30 [12] 278 jr NC,00101$
- 279 ;boot_rom.c:57: write_char(129, color, x, 0);
- 0110 59 [ 4] 280 ld e, c
- 0111 16 00 [ 7] 281 ld d, #0x00
- 0113 C5 [11] 282 push bc
- 0114 D5 [11] 283 push de
- 0115 21 00 00 [10] 284 ld hl, #0x0000
- 0118 E5 [11] 285 push hl
- 0119 D5 [11] 286 push de
- 011A DD 56 04 [19] 287 ld d, 4 (ix)
- 011D 1E 81 [ 7] 288 ld e,#0x81
- 011F D5 [11] 289 push de
- 0120 CDr74r00 [17] 290 call _write_char
- 0123 21 06 00 [10] 291 ld hl, #6
- 0126 39 [11] 292 add hl, sp
- 0127 F9 [ 6] 293 ld sp, hl
- 0128 D1 [10] 294 pop de
- 0129 21 1D 00 [10] 295 ld hl, #0x001d
- 012C E5 [11] 296 push hl
- 012D D5 [11] 297 push de
- 012E DD 56 04 [19] 298 ld d, 4 (ix)
- 0131 1E 81 [ 7] 299 ld e,#0x81
- 0133 D5 [11] 300 push de
- 0134 CDr74r00 [17] 301 call _write_char
- 0137 21 06 00 [10] 302 ld hl, #6
- 013A 39 [11] 303 add hl, sp
- 013B F9 [ 6] 304 ld sp, hl
- 013C C1 [10] 305 pop bc
- 306 ;boot_rom.c:55: for (char x = 1; x < 39; x++)
- 013D 0C [ 4] 307 inc c
- 013E 18 CB [12] 308 jr 00104$
- 0140 309 00101$:
- 310 ;boot_rom.c:60: for (char y = 1; y < 29; y++)
- 0140 0E 01 [ 7] 311 ld c, #0x01
- 0142 312 00107$:
- 0142 79 [ 4] 313 ld a, c
- 0143 D6 1D [ 7] 314 sub a, #0x1d
- 0145 30 2E [12] 315 jr NC,00109$
- 316 ;boot_rom.c:62: write_char(131, color, 0, y);
- 0147 59 [ 4] 317 ld e, c
- 0148 16 00 [ 7] 318 ld d, #0x00
- 014A C5 [11] 319 push bc
- 014B D5 [11] 320 push de
- 014C D5 [11] 321 push de
- 014D 21 00 00 [10] 322 ld hl, #0x0000
- 0150 E5 [11] 323 push hl
- 0151 DD 56 04 [19] 324 ld d, 4 (ix)
- 0154 1E 83 [ 7] 325 ld e,#0x83
- 0156 D5 [11] 326 push de
- 0157 CDr74r00 [17] 327 call _write_char
- 015A 21 06 00 [10] 328 ld hl, #6
- 015D 39 [11] 329 add hl, sp
- 015E F9 [ 6] 330 ld sp, hl
- 015F 21 27 00 [10] 331 ld hl, #0x0027
- 0162 E5 [11] 332 push hl
- 0163 DD 56 04 [19] 333 ld d, 4 (ix)
- 0166 1E 83 [ 7] 334 ld e,#0x83
- 0168 D5 [11] 335 push de
- 0169 CDr74r00 [17] 336 call _write_char
- 016C 21 06 00 [10] 337 ld hl, #6
- 016F 39 [11] 338 add hl, sp
- 0170 F9 [ 6] 339 ld sp, hl
- 0171 C1 [10] 340 pop bc
- 341 ;boot_rom.c:60: for (char y = 1; y < 29; y++)
- 0172 0C [ 4] 342 inc c
- 0173 18 CD [12] 343 jr 00107$
- 0175 344 00109$:
- 345 ;boot_rom.c:65: }
- 0175 DD E1 [14] 346 pop ix
- 0177 C9 [10] 347 ret
- 348 ;boot_rom.c:67: void page_inputs()
- 349 ; ---------------------------------
- 350 ; Function page_inputs
- 351 ; ---------------------------------
- 0178 352 _page_inputs::
- 0178 DD E5 [15] 353 push ix
- 017A DD 21 00 00 [14] 354 ld ix,#0
- 017E DD 39 [15] 355 add ix,sp
- 0180 21 F6 FF [10] 356 ld hl, #-10
- 0183 39 [11] 357 add hl, sp
- 0184 F9 [ 6] 358 ld sp, hl
- 359 ;boot_rom.c:69: clear_chars();
- 0185 CDr00r00 [17] 360 call _clear_chars
- 361 ;boot_rom.c:70: page_border(0b00000111);
- 0188 3E 07 [ 7] 362 ld a, #0x07
- 018A F5 [11] 363 push af
- 018B 33 [ 6] 364 inc sp
- 018C CDrADr00 [17] 365 call _page_border
- 018F 33 [ 6] 366 inc sp
- 367 ;boot_rom.c:71: write_string("UDLRABCXYZLRSs", 0xFF, 7, 3);
- 0190 21 03 00 [10] 368 ld hl, #0x0003
- 0193 E5 [11] 369 push hl
- 0194 2E 07 [ 7] 370 ld l, #0x07
- 0196 E5 [11] 371 push hl
- 0197 3E FF [ 7] 372 ld a, #0xff
- 0199 F5 [11] 373 push af
- 019A 33 [ 6] 374 inc sp
- 019B 21r2Ar02 [10] 375 ld hl, #___str_0
- 019E E5 [11] 376 push hl
- 019F CDr17r00 [17] 377 call _write_string
- 01A2 21 07 00 [10] 378 ld hl, #7
- 01A5 39 [11] 379 add hl, sp
- 01A6 F9 [ 6] 380 ld sp, hl
- 381 ;boot_rom.c:72: write_string("AX AY", 0xFF, 25, 3);
- 01A7 21 03 00 [10] 382 ld hl, #0x0003
- 01AA E5 [11] 383 push hl
- 01AB 2E 19 [ 7] 384 ld l, #0x19
- 01AD E5 [11] 385 push hl
- 01AE 3E FF [ 7] 386 ld a, #0xff
- 01B0 F5 [11] 387 push af
- 01B1 33 [ 6] 388 inc sp
- 01B2 21r39r02 [10] 389 ld hl, #___str_1
- 01B5 E5 [11] 390 push hl
- 01B6 CDr17r00 [17] 391 call _write_string
- 01B9 21 07 00 [10] 392 ld hl, #7
- 01BC 39 [11] 393 add hl, sp
- 01BD F9 [ 6] 394 ld sp, hl
- 395 ;boot_rom.c:75: for (unsigned char j = 0; j < 6; j++)
- 01BE 21 00 00 [10] 396 ld hl, #0x0000
- 01C1 39 [11] 397 add hl, sp
- 01C2 DD 75 FD [19] 398 ld -3 (ix), l
- 01C5 DD 74 FE [19] 399 ld -2 (ix), h
- 01C8 DD 7E FD [19] 400 ld a, -3 (ix)
- 01CB DD 77 FB [19] 401 ld -5 (ix), a
- 01CE DD 7E FE [19] 402 ld a, -2 (ix)
- 01D1 DD 77 FC [19] 403 ld -4 (ix), a
- 01D4 DD 36 FF 00 [19] 404 ld -1 (ix), #0x00
- 01D8 405 00103$:
- 01D8 DD 7E FF [19] 406 ld a, -1 (ix)
- 01DB D6 06 [ 7] 407 sub a, #0x06
- 01DD 30 46 [12] 408 jr NC,00105$
- 409 ;boot_rom.c:77: sprintf(label, "JOY%d", j + 1);
- 01DF DD 4E FF [19] 410 ld c, -1 (ix)
- 01E2 06 00 [ 7] 411 ld b, #0x00
- 01E4 59 [ 4] 412 ld e, c
- 01E5 50 [ 4] 413 ld d, b
- 01E6 13 [ 6] 414 inc de
- 01E7 DD 6E FD [19] 415 ld l, -3 (ix)
- 01EA DD 66 FE [19] 416 ld h, -2 (ix)
- 01ED C5 [11] 417 push bc
- 01EE D5 [11] 418 push de
- 01EF 11r40r02 [10] 419 ld de, #___str_2
- 01F2 D5 [11] 420 push de
- 01F3 E5 [11] 421 push hl
- 01F4 CDr00r00 [17] 422 call _sprintf
- 01F7 21 06 00 [10] 423 ld hl, #6
- 01FA 39 [11] 424 add hl, sp
- 01FB F9 [ 6] 425 ld sp, hl
- 01FC C1 [10] 426 pop bc
- 427 ;boot_rom.c:78: write_string(label, 0xFF - (j*2), 2, 4 + j);
- 01FD 03 [ 6] 428 inc bc
- 01FE 03 [ 6] 429 inc bc
- 01FF 03 [ 6] 430 inc bc
- 0200 03 [ 6] 431 inc bc
- 0201 DD 7E FF [19] 432 ld a, -1 (ix)
- 0204 87 [ 4] 433 add a, a
- 0205 5F [ 4] 434 ld e, a
- 0206 3E FF [ 7] 435 ld a, #0xff
- 0208 93 [ 4] 436 sub a, e
- 0209 67 [ 4] 437 ld h, a
- 020A DD 5E FB [19] 438 ld e, -5 (ix)
- 020D DD 56 FC [19] 439 ld d, -4 (ix)
- 0210 C5 [11] 440 push bc
- 0211 01 02 00 [10] 441 ld bc, #0x0002
- 0214 C5 [11] 442 push bc
- 0215 E5 [11] 443 push hl
- 0216 33 [ 6] 444 inc sp
- 0217 D5 [11] 445 push de
- 0218 CDr17r00 [17] 446 call _write_string
- 021B 21 07 00 [10] 447 ld hl, #7
- 021E 39 [11] 448 add hl, sp
- 021F F9 [ 6] 449 ld sp, hl
- 450 ;boot_rom.c:75: for (unsigned char j = 0; j < 6; j++)
- 0220 DD 34 FF [23] 451 inc -1 (ix)
- 0223 18 B3 [12] 452 jr 00103$
- 0225 453 00105$:
- 454 ;boot_rom.c:80: }
- 0225 DD F9 [10] 455 ld sp, ix
- 0227 DD E1 [14] 456 pop ix
- 0229 C9 [10] 457 ret
- 022A 458 ___str_0:
- 022A 55 44 4C 52 41 42 459 .ascii "UDLRABCXYZLRSs"
+ 70 .area _DABS (ABS)
+ 71 ;--------------------------------------------------------
+ 72 ; global & static initialisations
+ 73 ;--------------------------------------------------------
+ 74 .area _HOME
+ 75 .area _GSINIT
+ 76 .area _GSFINAL
+ 77 .area _GSINIT
+ 78 ;--------------------------------------------------------
+ 79 ; Home
+ 80 ;--------------------------------------------------------
+ 81 .area _HOME
+ 82 .area _HOME
+ 83 ;--------------------------------------------------------
+ 84 ; code
+ 85 ;--------------------------------------------------------
+ 86 .area _CODE
+ 87 ;boot_rom.c:24: void clear_chars()
+ 88 ; ---------------------------------
+ 89 ; Function clear_chars
+ 90 ; ---------------------------------
+ 0000 91 _clear_chars::
+ 92 ;boot_rom.c:26: for (unsigned int p = 0; p < chram_size; p++)
+ 0000 01 00 00 [10] 93 ld bc, #0x0000
+ 0003 94 00103$:
+ 0003 21r00r00 [10] 95 ld hl, #_chram_size
+ 0006 79 [ 4] 96 ld a, c
+ 0007 96 [ 7] 97 sub a, (hl)
+ 0008 78 [ 4] 98 ld a, b
+ 0009 23 [ 6] 99 inc hl
+ 000A 9E [ 7] 100 sbc a, (hl)
+ 000B D0 [11] 101 ret NC
+ 102 ;boot_rom.c:28: chram[p] = 0;
+ 000C 21 00 80 [10] 103 ld hl, #_chram+0
+ 000F 09 [11] 104 add hl, bc
+ 0010 36 00 [10] 105 ld (hl), #0x00
+ 106 ;boot_rom.c:26: for (unsigned int p = 0; p < chram_size; p++)
+ 0012 03 [ 6] 107 inc bc
+ 108 ;boot_rom.c:30: }
+ 0013 18 EE [12] 109 jr 00103$
+ 0015 110 _chram_cols:
+ 0015 40 111 .db #0x40 ; 64
+ 0016 112 _chram_rows:
+ 0016 20 113 .db #0x20 ; 32
+ 114 ;boot_rom.c:32: void write_string(const char *string, char color, unsigned int x, unsigned int y)
+ 115 ; ---------------------------------
+ 116 ; Function write_string
+ 117 ; ---------------------------------
+ 0017 118 _write_string::
+ 0017 DD E5 [15] 119 push ix
+ 0019 DD 21 00 00 [14] 120 ld ix,#0
+ 001D DD 39 [15] 121 add ix,sp
+ 001F F5 [11] 122 push af
+ 123 ;boot_rom.c:34: unsigned int p = (y * chram_cols) + x;
+ 0020 21r15r00 [10] 124 ld hl,#_chram_cols + 0
+ 0023 4E [ 7] 125 ld c, (hl)
+ 0024 06 00 [ 7] 126 ld b, #0x00
+ 0026 C5 [11] 127 push bc
+ 0027 DD 6E 09 [19] 128 ld l, 9 (ix)
+ 002A DD 66 0A [19] 129 ld h, 10 (ix)
+ 002D E5 [11] 130 push hl
+ 002E CDr00r00 [17] 131 call __mulint
+ 0031 F1 [10] 132 pop af
+ 0032 F1 [10] 133 pop af
+ 0033 4D [ 4] 134 ld c, l
+ 0034 44 [ 4] 135 ld b, h
+ 0035 DD 6E 07 [19] 136 ld l, 7 (ix)
+ 0038 DD 66 08 [19] 137 ld h, 8 (ix)
+ 003B 09 [11] 138 add hl, bc
+ 003C EB [ 4] 139 ex de,hl
+ 140 ;boot_rom.c:35: unsigned char l = strlen(string);
+ 003D DD 6E 04 [19] 141 ld l, 4 (ix)
+ 0040 DD 66 05 [19] 142 ld h, 5 (ix)
+ 0043 E5 [11] 143 push hl
+ 0044 CDr00r00 [17] 144 call _strlen
+ 0047 F1 [10] 145 pop af
+ 0048 4D [ 4] 146 ld c, l
+ 147 ;boot_rom.c:36: for (char c = 0; c < l; c++)
+ 0049 06 00 [ 7] 148 ld b, #0x00
+ 004B 149 00103$:
+ 004B 78 [ 4] 150 ld a, b
+ 004C 91 [ 4] 151 sub a, c
+ 004D 30 20 [12] 152 jr NC,00105$
+ 153 ;boot_rom.c:38: chram[p] = string[c];
+ 004F 21 00 80 [10] 154 ld hl, #_chram
+ 0052 19 [11] 155 add hl, de
+ 0053 E3 [19] 156 ex (sp), hl
+ 0054 DD 7E 04 [19] 157 ld a, 4 (ix)
+ 0057 80 [ 4] 158 add a, b
+ 0058 6F [ 4] 159 ld l, a
+ 0059 DD 7E 05 [19] 160 ld a, 5 (ix)
+ 005C CE 00 [ 7] 161 adc a, #0x00
+ 005E 67 [ 4] 162 ld h, a
+ 005F 7E [ 7] 163 ld a, (hl)
+ 0060 E1 [10] 164 pop hl
+ 0061 E5 [11] 165 push hl
+ 0062 77 [ 7] 166 ld (hl), a
+ 167 ;boot_rom.c:39: colram[p] = color;
+ 0063 21 00 88 [10] 168 ld hl, #_colram
+ 0066 19 [11] 169 add hl, de
+ 0067 DD 7E 06 [19] 170 ld a, 6 (ix)
+ 006A 77 [ 7] 171 ld (hl), a
+ 172 ;boot_rom.c:40: p++;
+ 006B 13 [ 6] 173 inc de
+ 174 ;boot_rom.c:36: for (char c = 0; c < l; c++)
+ 006C 04 [ 4] 175 inc b
+ 006D 18 DC [12] 176 jr 00103$
+ 006F 177 00105$:
+ 178 ;boot_rom.c:42: }
+ 006F DD F9 [10] 179 ld sp, ix
+ 0071 DD E1 [14] 180 pop ix
+ 0073 C9 [10] 181 ret
+ 182 ;boot_rom.c:44: void write_char(unsigned char c, char color, unsigned int x, unsigned int y)
+ 183 ; ---------------------------------
+ 184 ; Function write_char
+ 185 ; ---------------------------------
+ 0074 186 _write_char::
+ 0074 DD E5 [15] 187 push ix
+ 0076 DD 21 00 00 [14] 188 ld ix,#0
+ 007A DD 39 [15] 189 add ix,sp
+ 190 ;boot_rom.c:46: unsigned int p = (y * chram_cols) + x;
+ 007C 21r15r00 [10] 191 ld hl,#_chram_cols + 0
+ 007F 4E [ 7] 192 ld c, (hl)
+ 0080 06 00 [ 7] 193 ld b, #0x00
+ 0082 C5 [11] 194 push bc
+ 0083 DD 6E 08 [19] 195 ld l, 8 (ix)
+ 0086 DD 66 09 [19] 196 ld h, 9 (ix)
+ 0089 E5 [11] 197 push hl
+ 008A CDr00r00 [17] 198 call __mulint
+ 008D F1 [10] 199 pop af
+ 008E F1 [10] 200 pop af
+ 008F 4D [ 4] 201 ld c, l
+ 0090 44 [ 4] 202 ld b, h
+ 0091 DD 6E 06 [19] 203 ld l, 6 (ix)
+ 0094 DD 66 07 [19] 204 ld h, 7 (ix)
+ 0097 09 [11] 205 add hl, bc
+ 0098 4D [ 4] 206 ld c, l
+ 0099 44 [ 4] 207 ld b, h
+ 208 ;boot_rom.c:47: chram[p] = c;
+ 009A 21 00 80 [10] 209 ld hl, #_chram+0
+ 009D 09 [11] 210 add hl, bc
+ 009E DD 7E 04 [19] 211 ld a, 4 (ix)
+ 00A1 77 [ 7] 212 ld (hl), a
+ 213 ;boot_rom.c:48: colram[p] = color;
+ 00A2 21 00 88 [10] 214 ld hl, #_colram+0
+ 00A5 09 [11] 215 add hl, bc
+ 00A6 DD 7E 05 [19] 216 ld a, 5 (ix)
+ 00A9 77 [ 7] 217 ld (hl), a
+ 218 ;boot_rom.c:49: }
+ 00AA DD E1 [14] 219 pop ix
+ 00AC C9 [10] 220 ret
+ 221 ;boot_rom.c:51: void page_border(char color)
+ 222 ; ---------------------------------
+ 223 ; Function page_border
+ 224 ; ---------------------------------
+ 00AD 225 _page_border::
+ 00AD DD E5 [15] 226 push ix
+ 00AF DD 21 00 00 [14] 227 ld ix,#0
+ 00B3 DD 39 [15] 228 add ix,sp
+ 229 ;boot_rom.c:53: write_char(128, color, 0, 0);
+ 00B5 21 00 00 [10] 230 ld hl, #0x0000
+ 00B8 E5 [11] 231 push hl
+ 00B9 2E 00 [ 7] 232 ld l, #0x00
+ 00BB E5 [11] 233 push hl
+ 00BC DD 56 04 [19] 234 ld d, 4 (ix)
+ 00BF 1E 80 [ 7] 235 ld e,#0x80
+ 00C1 D5 [11] 236 push de
+ 00C2 CDr74r00 [17] 237 call _write_char
+ 00C5 21 06 00 [10] 238 ld hl, #6
+ 00C8 39 [11] 239 add hl, sp
+ 00C9 F9 [ 6] 240 ld sp, hl
+ 241 ;boot_rom.c:54: write_char(130, color, 39, 0);
+ 00CA 21 00 00 [10] 242 ld hl, #0x0000
+ 00CD E5 [11] 243 push hl
+ 00CE 2E 27 [ 7] 244 ld l, #0x27
+ 00D0 E5 [11] 245 push hl
+ 00D1 DD 56 04 [19] 246 ld d, 4 (ix)
+ 00D4 1E 82 [ 7] 247 ld e,#0x82
+ 00D6 D5 [11] 248 push de
+ 00D7 CDr74r00 [17] 249 call _write_char
+ 00DA 21 06 00 [10] 250 ld hl, #6
+ 00DD 39 [11] 251 add hl, sp
+ 00DE F9 [ 6] 252 ld sp, hl
+ 253 ;boot_rom.c:55: write_char(133, color, 0, 29);
+ 00DF 21 1D 00 [10] 254 ld hl, #0x001d
+ 00E2 E5 [11] 255 push hl
+ 00E3 2E 00 [ 7] 256 ld l, #0x00
+ 00E5 E5 [11] 257 push hl
+ 00E6 DD 56 04 [19] 258 ld d, 4 (ix)
+ 00E9 1E 85 [ 7] 259 ld e,#0x85
+ 00EB D5 [11] 260 push de
+ 00EC CDr74r00 [17] 261 call _write_char
+ 00EF 21 06 00 [10] 262 ld hl, #6
+ 00F2 39 [11] 263 add hl, sp
+ 00F3 F9 [ 6] 264 ld sp, hl
+ 265 ;boot_rom.c:56: write_char(132, color, 39, 29);
+ 00F4 21 1D 00 [10] 266 ld hl, #0x001d
+ 00F7 E5 [11] 267 push hl
+ 00F8 2E 27 [ 7] 268 ld l, #0x27
+ 00FA E5 [11] 269 push hl
+ 00FB DD 56 04 [19] 270 ld d, 4 (ix)
+ 00FE 1E 84 [ 7] 271 ld e,#0x84
+ 0100 D5 [11] 272 push de
+ 0101 CDr74r00 [17] 273 call _write_char
+ 0104 21 06 00 [10] 274 ld hl, #6
+ 0107 39 [11] 275 add hl, sp
+ 0108 F9 [ 6] 276 ld sp, hl
+ 277 ;boot_rom.c:57: for (char x = 1; x < 39; x++)
+ 0109 0E 01 [ 7] 278 ld c, #0x01
+ 010B 279 00104$:
+ 010B 79 [ 4] 280 ld a, c
+ 010C D6 27 [ 7] 281 sub a, #0x27
+ 010E 30 30 [12] 282 jr NC,00101$
+ 283 ;boot_rom.c:59: write_char(129, color, x, 0);
+ 0110 59 [ 4] 284 ld e, c
+ 0111 16 00 [ 7] 285 ld d, #0x00
+ 0113 C5 [11] 286 push bc
+ 0114 D5 [11] 287 push de
+ 0115 21 00 00 [10] 288 ld hl, #0x0000
+ 0118 E5 [11] 289 push hl
+ 0119 D5 [11] 290 push de
+ 011A DD 56 04 [19] 291 ld d, 4 (ix)
+ 011D 1E 81 [ 7] 292 ld e,#0x81
+ 011F D5 [11] 293 push de
+ 0120 CDr74r00 [17] 294 call _write_char
+ 0123 21 06 00 [10] 295 ld hl, #6
+ 0126 39 [11] 296 add hl, sp
+ 0127 F9 [ 6] 297 ld sp, hl
+ 0128 D1 [10] 298 pop de
+ 0129 21 1D 00 [10] 299 ld hl, #0x001d
+ 012C E5 [11] 300 push hl
+ 012D D5 [11] 301 push de
+ 012E DD 56 04 [19] 302 ld d, 4 (ix)
+ 0131 1E 81 [ 7] 303 ld e,#0x81
+ 0133 D5 [11] 304 push de
+ 0134 CDr74r00 [17] 305 call _write_char
+ 0137 21 06 00 [10] 306 ld hl, #6
+ 013A 39 [11] 307 add hl, sp
+ 013B F9 [ 6] 308 ld sp, hl
+ 013C C1 [10] 309 pop bc
+ 310 ;boot_rom.c:57: for (char x = 1; x < 39; x++)
+ 013D 0C [ 4] 311 inc c
+ 013E 18 CB [12] 312 jr 00104$
+ 0140 313 00101$:
+ 314 ;boot_rom.c:62: for (char y = 1; y < 29; y++)
+ 0140 0E 01 [ 7] 315 ld c, #0x01
+ 0142 316 00107$:
+ 0142 79 [ 4] 317 ld a, c
+ 0143 D6 1D [ 7] 318 sub a, #0x1d
+ 0145 30 2E [12] 319 jr NC,00109$
+ 320 ;boot_rom.c:64: write_char(131, color, 0, y);
+ 0147 59 [ 4] 321 ld e, c
+ 0148 16 00 [ 7] 322 ld d, #0x00
+ 014A C5 [11] 323 push bc
+ 014B D5 [11] 324 push de
+ 014C D5 [11] 325 push de
+ 014D 21 00 00 [10] 326 ld hl, #0x0000
+ 0150 E5 [11] 327 push hl
+ 0151 DD 56 04 [19] 328 ld d, 4 (ix)
+ 0154 1E 83 [ 7] 329 ld e,#0x83
+ 0156 D5 [11] 330 push de
+ 0157 CDr74r00 [17] 331 call _write_char
+ 015A 21 06 00 [10] 332 ld hl, #6
+ 015D 39 [11] 333 add hl, sp
+ 015E F9 [ 6] 334 ld sp, hl
+ 015F 21 27 00 [10] 335 ld hl, #0x0027
+ 0162 E5 [11] 336 push hl
+ 0163 DD 56 04 [19] 337 ld d, 4 (ix)
+ 0166 1E 83 [ 7] 338 ld e,#0x83
+ 0168 D5 [11] 339 push de
+ 0169 CDr74r00 [17] 340 call _write_char
+ 016C 21 06 00 [10] 341 ld hl, #6
+ 016F 39 [11] 342 add hl, sp
+ 0170 F9 [ 6] 343 ld sp, hl
+ 0171 C1 [10] 344 pop bc
+ 345 ;boot_rom.c:62: for (char y = 1; y < 29; y++)
+ 0172 0C [ 4] 346 inc c
+ 0173 18 CD [12] 347 jr 00107$
+ 0175 348 00109$:
+ 349 ;boot_rom.c:67: }
+ 0175 DD E1 [14] 350 pop ix
+ 0177 C9 [10] 351 ret
+ 352 ;boot_rom.c:69: void page_inputs()
+ 353 ; ---------------------------------
+ 354 ; Function page_inputs
+ 355 ; ---------------------------------
+ 0178 356 _page_inputs::
+ 0178 DD E5 [15] 357 push ix
+ 017A DD 21 00 00 [14] 358 ld ix,#0
+ 017E DD 39 [15] 359 add ix,sp
+ 0180 21 EB FF [10] 360 ld hl, #-21
+ 0183 39 [11] 361 add hl, sp
+ 0184 F9 [ 6] 362 ld sp, hl
+ 363 ;boot_rom.c:71: clear_chars();
+ 0185 CDr00r00 [17] 364 call _clear_chars
+ 365 ;boot_rom.c:72: page_border(0b00000111);
+ 0188 3E 07 [ 7] 366 ld a, #0x07
+ 018A F5 [11] 367 push af
+ 018B 33 [ 6] 368 inc sp
+ 018C CDrADr00 [17] 369 call _page_border
+ 018F 33 [ 6] 370 inc sp
+ 371 ;boot_rom.c:73: write_string("UDLRABCXYZLRSs", 0xFF, 7, 3);
+ 0190 21 03 00 [10] 372 ld hl, #0x0003
+ 0193 E5 [11] 373 push hl
+ 0194 2E 07 [ 7] 374 ld l, #0x07
+ 0196 E5 [11] 375 push hl
+ 0197 3E FF [ 7] 376 ld a, #0xff
+ 0199 F5 [11] 377 push af
+ 019A 33 [ 6] 378 inc sp
+ 019B 21rF9r02 [10] 379 ld hl, #___str_0
+ 019E E5 [11] 380 push hl
+ 019F CDr17r00 [17] 381 call _write_string
+ 01A2 21 07 00 [10] 382 ld hl, #7
+ 01A5 39 [11] 383 add hl, sp
+ 01A6 F9 [ 6] 384 ld sp, hl
+ 385 ;boot_rom.c:74: write_string("AX", 0xFF, 26, 3);
+ 01A7 21 03 00 [10] 386 ld hl, #0x0003
+ 01AA E5 [11] 387 push hl
+ 01AB 2E 1A [ 7] 388 ld l, #0x1a
+ 01AD E5 [11] 389 push hl
+ 01AE 3E FF [ 7] 390 ld a, #0xff
+ 01B0 F5 [11] 391 push af
+ 01B1 33 [ 6] 392 inc sp
+ 01B2 21r08r03 [10] 393 ld hl, #___str_1
+ 01B5 E5 [11] 394 push hl
+ 01B6 CDr17r00 [17] 395 call _write_string
+ 01B9 21 07 00 [10] 396 ld hl, #7
+ 01BC 39 [11] 397 add hl, sp
+ 01BD F9 [ 6] 398 ld sp, hl
+ 399 ;boot_rom.c:75: write_string("AY", 0xFF, 31, 3);
+ 01BE 21 03 00 [10] 400 ld hl, #0x0003
+ 01C1 E5 [11] 401 push hl
+ 01C2 2E 1F [ 7] 402 ld l, #0x1f
+ 01C4 E5 [11] 403 push hl
+ 01C5 3E FF [ 7] 404 ld a, #0xff
+ 01C7 F5 [11] 405 push af
+ 01C8 33 [ 6] 406 inc sp
+ 01C9 21r0Br03 [10] 407 ld hl, #___str_2
+ 01CC E5 [11] 408 push hl
+ 01CD CDr17r00 [17] 409 call _write_string
+ 01D0 21 07 00 [10] 410 ld hl, #7
+ 01D3 39 [11] 411 add hl, sp
+ 01D4 F9 [ 6] 412 ld sp, hl
+ 413 ;boot_rom.c:78: for (unsigned char j = 0; j < 6; j++)
+ 01D5 21 00 00 [10] 414 ld hl, #0x0000
+ 01D8 39 [11] 415 add hl, sp
+ 01D9 EB [ 4] 416 ex de, hl
+ 01DA DD 73 FA [19] 417 ld -6 (ix), e
+ 01DD DD 72 FB [19] 418 ld -5 (ix), d
+ 01E0 DD 73 FC [19] 419 ld -4 (ix), e
+ 01E3 DD 72 FD [19] 420 ld -3 (ix), d
+ 01E6 DD 73 F4 [19] 421 ld -12 (ix), e
+ 01E9 DD 72 F5 [19] 422 ld -11 (ix), d
+ 01EC DD 73 F2 [19] 423 ld -14 (ix), e
+ 01EF DD 72 F3 [19] 424 ld -13 (ix), d
+ 01F2 DD 73 F0 [19] 425 ld -16 (ix), e
+ 01F5 DD 72 F1 [19] 426 ld -15 (ix), d
+ 01F8 DD 36 FF 00 [19] 427 ld -1 (ix), #0x00
+ 01FC 428 00103$:
+ 01FC DD 7E FF [19] 429 ld a, -1 (ix)
+ 01FF D6 06 [ 7] 430 sub a, #0x06
+ 0201 D2rF4r02 [10] 431 jp NC, 00105$
+ 432 ;boot_rom.c:80: sprintf(label, "JOY%d", j + 1);
+ 0204 DD 7E FF [19] 433 ld a, -1 (ix)
+ 0207 DD 77 F8 [19] 434 ld -8 (ix), a
+ 020A DD 36 F9 00 [19] 435 ld -7 (ix), #0x00
+ 020E DD 7E F8 [19] 436 ld a, -8 (ix)
+ 0211 C6 01 [ 7] 437 add a, #0x01
+ 0213 DD 77 F6 [19] 438 ld -10 (ix), a
+ 0216 DD 7E F9 [19] 439 ld a, -7 (ix)
+ 0219 CE 00 [ 7] 440 adc a, #0x00
+ 021B DD 77 F7 [19] 441 ld -9 (ix), a
+ 021E 4B [ 4] 442 ld c, e
+ 021F 42 [ 4] 443 ld b, d
+ 0220 D5 [11] 444 push de
+ 0221 DD 6E F6 [19] 445 ld l, -10 (ix)
+ 0224 DD 66 F7 [19] 446 ld h, -9 (ix)
+ 0227 E5 [11] 447 push hl
+ 0228 21r0Er03 [10] 448 ld hl, #___str_3
+ 022B E5 [11] 449 push hl
+ 022C C5 [11] 450 push bc
+ 022D CDr00r00 [17] 451 call _sprintf
+ 0230 21 06 00 [10] 452 ld hl, #6
+ 0233 39 [11] 453 add hl, sp
+ 0234 F9 [ 6] 454 ld sp, hl
+ 0235 D1 [10] 455 pop de
+ 456 ;boot_rom.c:81: write_string(label, 0xFF - (j * 2), 2, 4 + j);
+ 0236 DD 7E F8 [19] 457 ld a, -8 (ix)
+ 0239 C6 04 [ 7] 458 add a, #0x04
+ 023B 6F [ 4] 459 ld l, a
+ 023C DD 7E F9 [19] 460 ld a, -7 (ix)
+ 023F CE 00 [ 7] 461 adc a, #0x00
+ 0241 67 [ 4] 462 ld h, a
+ 0242 DD 7E FF [19] 463 ld a, -1 (ix)
+ 0245 87 [ 4] 464 add a, a
+ 0246 4F [ 4] 465 ld c, a
+ 0247 3E FF [ 7] 466 ld a, #0xff
+ 0249 91 [ 4] 467 sub a, c
+ 024A DD 77 FE [19] 468 ld -2 (ix), a
+ 024D DD 4E FA [19] 469 ld c, -6 (ix)
+ 0250 DD 46 FB [19] 470 ld b, -5 (ix)
+ 0253 D5 [11] 471 push de
+ 0254 E5 [11] 472 push hl
+ 0255 21 02 00 [10] 473 ld hl, #0x0002
+ 0258 E5 [11] 474 push hl
+ 0259 DD 7E FE [19] 475 ld a, -2 (ix)
+ 025C F5 [11] 476 push af
+ 025D 33 [ 6] 477 inc sp
+ 025E C5 [11] 478 push bc
+ 025F CDr17r00 [17] 479 call _write_string
+ 0262 21 07 00 [10] 480 ld hl, #7
+ 0265 39 [11] 481 add hl, sp
+ 0266 F9 [ 6] 482 ld sp, hl
+ 0267 D1 [10] 483 pop de
+ 484 ;boot_rom.c:83: sprintf(label, "PAD%d", j + 1);
+ 0268 DD 4E FC [19] 485 ld c, -4 (ix)
+ 026B DD 46 FD [19] 486 ld b, -3 (ix)
+ 026E D5 [11] 487 push de
+ 026F DD 6E F6 [19] 488 ld l, -10 (ix)
+ 0272 DD 66 F7 [19] 489 ld h, -9 (ix)
+ 0275 E5 [11] 490 push hl
+ 0276 21r14r03 [10] 491 ld hl, #___str_4
+ 0279 E5 [11] 492 push hl
+ 027A C5 [11] 493 push bc
+ 027B CDr00r00 [17] 494 call _sprintf
+ 027E 21 06 00 [10] 495 ld hl, #6
+ 0281 39 [11] 496 add hl, sp
+ 0282 F9 [ 6] 497 ld sp, hl
+ 0283 D1 [10] 498 pop de
+ 499 ;boot_rom.c:84: write_string(label, 0xFF - (j * 2), 2, 11 + j);
+ 0284 DD 7E F8 [19] 500 ld a, -8 (ix)
+ 0287 C6 0B [ 7] 501 add a, #0x0b
+ 0289 6F [ 4] 502 ld l, a
+ 028A DD 7E F9 [19] 503 ld a, -7 (ix)
+ 028D CE 00 [ 7] 504 adc a, #0x00
+ 028F 67 [ 4] 505 ld h, a
+ 0290 DD 4E F4 [19] 506 ld c, -12 (ix)
+ 0293 DD 46 F5 [19] 507 ld b, -11 (ix)
+ 0296 D5 [11] 508 push de
+ 0297 E5 [11] 509 push hl
+ 0298 21 02 00 [10] 510 ld hl, #0x0002
+ 029B E5 [11] 511 push hl
+ 029C DD 7E FE [19] 512 ld a, -2 (ix)
+ 029F F5 [11] 513 push af
+ 02A0 33 [ 6] 514 inc sp
+ 02A1 C5 [11] 515 push bc
+ 02A2 CDr17r00 [17] 516 call _write_string
+ 02A5 21 07 00 [10] 517 ld hl, #7
+ 02A8 39 [11] 518 add hl, sp
+ 02A9 F9 [ 6] 519 ld sp, hl
+ 02AA D1 [10] 520 pop de
+ 521 ;boot_rom.c:86: sprintf(label, "SPN%d", j + 1);
+ 02AB DD 4E F2 [19] 522 ld c, -14 (ix)
+ 02AE DD 46 F3 [19] 523 ld b, -13 (ix)
+ 02B1 D5 [11] 524 push de
+ 02B2 DD 6E F6 [19] 525 ld l, -10 (ix)
+ 02B5 DD 66 F7 [19] 526 ld h, -9 (ix)
+ 02B8 E5 [11] 527 push hl
+ 02B9 21r1Ar03 [10] 528 ld hl, #___str_5
+ 02BC E5 [11] 529 push hl
+ 02BD C5 [11] 530 push bc
+ 02BE CDr00r00 [17] 531 call _sprintf
+ 02C1 21 06 00 [10] 532 ld hl, #6
+ 02C4 39 [11] 533 add hl, sp
+ 02C5 F9 [ 6] 534 ld sp, hl
+ 02C6 D1 [10] 535 pop de
+ 536 ;boot_rom.c:87: write_string(label, 0xFF - (j * 2), 2, 18 + j);
+ 02C7 DD 7E F8 [19] 537 ld a, -8 (ix)
+ 02CA C6 12 [ 7] 538 add a, #0x12
+ 02CC 6F [ 4] 539 ld l, a
+ 02CD DD 7E F9 [19] 540 ld a, -7 (ix)
+ 02D0 CE 00 [ 7] 541 adc a, #0x00
+ 02D2 67 [ 4] 542 ld h, a
+ 02D3 DD 4E F0 [19] 543 ld c, -16 (ix)
+ 02D6 DD 46 F1 [19] 544 ld b, -15 (ix)
+ 02D9 D5 [11] 545 push de
+ 02DA E5 [11] 546 push hl
+ 02DB 21 02 00 [10] 547 ld hl, #0x0002
+ 02DE E5 [11] 548 push hl
+ 02DF DD 7E FE [19] 549 ld a, -2 (ix)
+ 02E2 F5 [11] 550 push af
+ 02E3 33 [ 6] 551 inc sp
+ 02E4 C5 [11] 552 push bc
+ 02E5 CDr17r00 [17] 553 call _write_string
+ 02E8 21 07 00 [10] 554 ld hl, #7
+ 02EB 39 [11] 555 add hl, sp
+ 02EC F9 [ 6] 556 ld sp, hl
+ 02ED D1 [10] 557 pop de
+ 558 ;boot_rom.c:78: for (unsigned char j = 0; j < 6; j++)
+ 02EE DD 34 FF [23] 559 inc -1 (ix)
+ 02F1 C3rFCr01 [10] 560 jp 00103$
+ 02F4 561 00105$:
+ 562 ;boot_rom.c:89: }
+ 02F4 DD F9 [10] 563 ld sp, ix
+ 02F6 DD E1 [14] 564 pop ix
+ 02F8 C9 [10] 565 ret
+ 02F9 566 ___str_0:
+ 02F9 55 44 4C 52 41 42 567 .ascii "UDLRABCXYZLRSs"
43 58 59 5A 4C 52
53 73
- 0238 00 460 .db 0x00
- 0239 461 ___str_1:
- 0239 41 58 20 20 41 59 462 .ascii "AX AY"
- 023F 00 463 .db 0x00
- 0240 464 ___str_2:
- 0240 4A 4F 59 25 64 465 .ascii "JOY%d"
- 0245 00 466 .db 0x00
- 467 ;boot_rom.c:85: void main()
- 468 ; ---------------------------------
- 469 ; Function main
- 470 ; ---------------------------------
- 0246 471 _main::
- 0246 DD E5 [15] 472 push ix
- 0248 DD 21 00 00 [14] 473 ld ix,#0
- 024C DD 39 [15] 474 add ix,sp
- 024E 21 E8 FF [10] 475 ld hl, #-24
- 0251 39 [11] 476 add hl, sp
- 0252 F9 [ 6] 477 ld sp, hl
- 478 ;boot_rom.c:87: chram_size = chram_cols * chram_rows;
- 0253 21r16r00 [10] 479 ld hl,#_chram_rows + 0
- 0256 5E [ 7] 480 ld e, (hl)
- 0257 21r15r00 [10] 481 ld hl,#_chram_cols + 0
- 025A 66 [ 7] 482 ld h, (hl)
- 025B 2E 00 [ 7] 483 ld l, #0x00
- 025D 55 [ 4] 484 ld d, l
- 025E 06 08 [ 7] 485 ld b, #0x08
- 0260 486 00191$:
- 0260 29 [11] 487 add hl, hl
- 0261 30 01 [12] 488 jr NC,00192$
- 0263 19 [11] 489 add hl, de
- 0264 490 00192$:
- 0264 10 FA [13] 491 djnz 00191$
- 0266 22r00r00 [16] 492 ld (_chram_size), hl
- 493 ;boot_rom.c:89: page_inputs();
- 0269 CDr78r01 [17] 494 call _page_inputs
- 495 ;boot_rom.c:91: while (1)
- 026C DD 36 FB AB [19] 496 ld -5 (ix), #0xab
- 0270 497 00109$:
- 498 ;boot_rom.c:93: hsync = input0 & 0x80;
- 0270 3A 00 60 [13] 499 ld a,(#_input0 + 0)
- 0273 E6 80 [ 7] 500 and a, #0x80
- 0275 32r02r00 [13] 501 ld (#_hsync + 0),a
- 502 ;boot_rom.c:94: vsync = input0 & 0x40;
- 0278 3A 00 60 [13] 503 ld a,(#_input0 + 0)
- 027B E6 40 [ 7] 504 and a, #0x40
- 027D FD 21r04r00 [14] 505 ld iy, #_vsync
- 0281 FD 77 00 [19] 506 ld 0 (iy), a
- 507 ;boot_rom.c:99: if (vsync && !vsync_last)
- 0284 FD 7E 00 [19] 508 ld a, 0 (iy)
- 0287 B7 [ 4] 509 or a, a
- 0288 CAr27r04 [10] 510 jp Z, 00106$
- 028B 3Ar05r00 [13] 511 ld a,(#_vsync_last + 0)
- 028E B7 [ 4] 512 or a, a
- 028F C2r27r04 [10] 513 jp NZ, 00106$
- 514 ;boot_rom.c:101: color++;
- 0292 DD 34 FB [23] 515 inc -5 (ix)
- 516 ;boot_rom.c:102: write_string("--- MiSTer Input Tester ---", color, 6, 1);
- 0295 21 01 00 [10] 517 ld hl, #0x0001
- 0298 E5 [11] 518 push hl
- 0299 2E 06 [ 7] 519 ld l, #0x06
- 029B E5 [11] 520 push hl
- 029C DD 7E FB [19] 521 ld a, -5 (ix)
- 029F F5 [11] 522 push af
- 02A0 33 [ 6] 523 inc sp
- 02A1 21r36r04 [10] 524 ld hl, #___str_3
- 02A4 E5 [11] 525 push hl
- 02A5 CDr17r00 [17] 526 call _write_string
- 02A8 21 07 00 [10] 527 ld hl, #7
- 02AB 39 [11] 528 add hl, sp
- 02AC F9 [ 6] 529 ld sp, hl
- 530 ;boot_rom.c:104: for (char b = 0; b < 2; b++)
- 02AD 0E 00 [ 7] 531 ld c, #0x00
- 02AF 532 00118$:
- 02AF 79 [ 4] 533 ld a, c
- 02B0 D6 02 [ 7] 534 sub a, #0x02
- 02B2 D2r49r03 [10] 535 jp NC, 00103$
- 536 ;boot_rom.c:106: char m = 0b00000001;
- 02B5 06 01 [ 7] 537 ld b, #0x01
- 538 ;boot_rom.c:107: for (char i = 0; i < 8; i++)
- 02B7 1E 00 [ 7] 539 ld e, #0x00
- 02B9 540 00115$:
- 541 ;boot_rom.c:109: char x = 7 + i + (b * 8);
- 02B9 7B [ 4] 542 ld a,e
- 02BA FE 08 [ 7] 543 cp a,#0x08
- 02BC D2r45r03 [10] 544 jp NC,00119$
- 02BF C6 07 [ 7] 545 add a, #0x07
- 02C1 57 [ 4] 546 ld d, a
- 02C2 79 [ 4] 547 ld a, c
- 02C3 87 [ 4] 548 add a, a
- 02C4 87 [ 4] 549 add a, a
- 02C5 87 [ 4] 550 add a, a
- 02C6 DD 77 FA [19] 551 ld -6 (ix), a
- 02C9 7A [ 4] 552 ld a, d
- 02CA DD 86 FA [19] 553 add a, -6 (ix)
- 02CD DD 77 FF [19] 554 ld -1 (ix), a
- 555 ;boot_rom.c:110: for (char j = 0; j < 6; j++)
- 02D0 DD 36 FC 00 [19] 556 ld -4 (ix), #0x00
- 02D4 557 00112$:
- 02D4 DD 7E FC [19] 558 ld a, -4 (ix)
- 02D7 D6 06 [ 7] 559 sub a, #0x06
- 02D9 30 64 [12] 560 jr NC,00101$
- 561 ;boot_rom.c:112: write_char((joystick[(b * 8) + (j * 32)] & m) ? asc_1 : asc_0, 0xFF, x, 4 + j);
- 02DB DD 7E FC [19] 562 ld a, -4 (ix)
- 02DE 2E 00 [ 7] 563 ld l, #0x00
- 02E0 C6 04 [ 7] 564 add a, #0x04
- 02E2 DD 77 F2 [19] 565 ld -14 (ix), a
- 02E5 7D [ 4] 566 ld a, l
- 02E6 CE 00 [ 7] 567 adc a, #0x00
- 02E8 DD 77 F3 [19] 568 ld -13 (ix), a
- 02EB DD 7E FF [19] 569 ld a, -1 (ix)
- 02EE DD 77 F0 [19] 570 ld -16 (ix), a
- 02F1 DD 36 F1 00 [19] 571 ld -15 (ix), #0x00
- 02F5 DD 7E FC [19] 572 ld a, -4 (ix)
- 02F8 0F [ 4] 573 rrca
- 02F9 0F [ 4] 574 rrca
- 02FA 0F [ 4] 575 rrca
- 02FB E6 E0 [ 7] 576 and a, #0xe0
- 02FD DD 86 FA [19] 577 add a, -6 (ix)
- 0300 57 [ 4] 578 ld d, a
- 0301 17 [ 4] 579 rla
- 0302 9F [ 4] 580 sbc a, a
- 0303 67 [ 4] 581 ld h, a
- 0304 3E 00 [ 7] 582 ld a, #<(_joystick)
- 0306 82 [ 4] 583 add a, d
- 0307 6F [ 4] 584 ld l, a
- 0308 3E 70 [ 7] 585 ld a, #>(_joystick)
- 030A 8C [ 4] 586 adc a, h
- 030B 67 [ 4] 587 ld h, a
- 030C 7E [ 7] 588 ld a, (hl)
- 030D A0 [ 4] 589 and a,b
- 030E 28 06 [12] 590 jr Z,00125$
- 0310 21r01r00 [10] 591 ld hl,#_asc_1 + 0
- 0313 56 [ 7] 592 ld d, (hl)
- 0314 18 04 [12] 593 jr 00126$
- 0316 594 00125$:
- 0316 21r00r00 [10] 595 ld hl,#_asc_0 + 0
- 0319 56 [ 7] 596 ld d, (hl)
- 031A 597 00126$:
- 031A C5 [11] 598 push bc
- 031B D5 [11] 599 push de
- 031C DD 6E F2 [19] 600 ld l, -14 (ix)
- 031F DD 66 F3 [19] 601 ld h, -13 (ix)
- 0322 E5 [11] 602 push hl
- 0323 DD 6E F0 [19] 603 ld l, -16 (ix)
- 0326 DD 66 F1 [19] 604 ld h, -15 (ix)
- 0329 E5 [11] 605 push hl
- 032A 3E FF [ 7] 606 ld a, #0xff
- 032C F5 [11] 607 push af
- 032D 33 [ 6] 608 inc sp
- 032E D5 [11] 609 push de
- 032F 33 [ 6] 610 inc sp
- 0330 CDr74r00 [17] 611 call _write_char
- 0333 21 06 00 [10] 612 ld hl, #6
- 0336 39 [11] 613 add hl, sp
- 0337 F9 [ 6] 614 ld sp, hl
- 0338 D1 [10] 615 pop de
- 0339 C1 [10] 616 pop bc
- 617 ;boot_rom.c:110: for (char j = 0; j < 6; j++)
- 033A DD 34 FC [23] 618 inc -4 (ix)
- 033D 18 95 [12] 619 jr 00112$
- 033F 620 00101$:
- 621 ;boot_rom.c:114: m <<= 1;
- 033F CB 20 [ 8] 622 sla b
- 623 ;boot_rom.c:107: for (char i = 0; i < 8; i++)
- 0341 1C [ 4] 624 inc e
- 0342 C3rB9r02 [10] 625 jp 00115$
- 0345 626 00119$:
- 627 ;boot_rom.c:104: for (char b = 0; b < 2; b++)
- 0345 0C [ 4] 628 inc c
- 0346 C3rAFr02 [10] 629 jp 00118$
- 0349 630 00103$:
- 631 ;boot_rom.c:120: char m = 0b00000001;
- 0349 DD 36 F0 01 [19] 632 ld -16 (ix), #0x01
- 633 ;boot_rom.c:123: for (char j = 0; j < 6; j++)
- 034D 21 04 00 [10] 634 ld hl, #0x0004
- 0350 39 [11] 635 add hl, sp
- 0351 DD 75 F2 [19] 636 ld -14 (ix), l
- 0354 DD 74 F3 [19] 637 ld -13 (ix), h
- 0357 DD 7E F2 [19] 638 ld a, -14 (ix)
- 035A DD 77 F8 [19] 639 ld -8 (ix), a
- 035D DD 7E F3 [19] 640 ld a, -13 (ix)
- 0360 DD 77 F9 [19] 641 ld -7 (ix), a
- 0363 21 00 00 [10] 642 ld hl, #0x0000
- 0366 39 [11] 643 add hl, sp
- 0367 DD 75 F6 [19] 644 ld -10 (ix), l
- 036A DD 74 F7 [19] 645 ld -9 (ix), h
- 036D DD 7E F6 [19] 646 ld a, -10 (ix)
- 0370 DD 77 F4 [19] 647 ld -12 (ix), a
- 0373 DD 7E F7 [19] 648 ld a, -9 (ix)
- 0376 DD 77 F5 [19] 649 ld -11 (ix), a
- 0379 DD 36 FE 00 [19] 650 ld -2 (ix), #0x00
- 037D 651 00121$:
- 037D DD 7E FE [19] 652 ld a, -2 (ix)
- 0380 D6 06 [ 7] 653 sub a, #0x06
- 0382 D2r27r04 [10] 654 jp NC, 00106$
- 655 ;boot_rom.c:125: signed char jx = analog[(j * 16)];
- 0385 DD 6E FE [19] 656 ld l, -2 (ix)
- 0388 26 00 [ 7] 657 ld h, #0x00
- 038A 29 [11] 658 add hl, hl
- 038B 29 [11] 659 add hl, hl
- 038C 29 [11] 660 add hl, hl
- 038D 29 [11] 661 add hl, hl
- 038E 11 00 71 [10] 662 ld de, #_analog
- 0391 19 [11] 663 add hl, de
- 0392 4E [ 7] 664 ld c, (hl)
- 665 ;boot_rom.c:126: signed char jy = analog[(j * 16) + 8];
- 0393 DD 7E FE [19] 666 ld a, -2 (ix)
- 0396 07 [ 4] 667 rlca
- 0397 07 [ 4] 668 rlca
- 0398 07 [ 4] 669 rlca
- 0399 07 [ 4] 670 rlca
- 039A E6 F0 [ 7] 671 and a, #0xf0
- 039C C6 08 [ 7] 672 add a, #0x08
- 039E 5F [ 4] 673 ld e, a
- 039F 17 [ 4] 674 rla
- 03A0 9F [ 4] 675 sbc a, a
- 03A1 57 [ 4] 676 ld d, a
- 03A2 21 00 71 [10] 677 ld hl, #_analog
- 03A5 19 [11] 678 add hl, de
- 03A6 7E [ 7] 679 ld a, (hl)
- 03A7 DD 77 FD [19] 680 ld -3 (ix), a
- 681 ;boot_rom.c:128: sprintf(str1, "%4d", jx);
- 03AA 79 [ 4] 682 ld a, c
- 03AB 17 [ 4] 683 rla
- 03AC 9F [ 4] 684 sbc a, a
- 03AD 47 [ 4] 685 ld b, a
- 03AE DD 5E F2 [19] 686 ld e, -14 (ix)
- 03B1 DD 56 F3 [19] 687 ld d, -13 (ix)
- 03B4 C5 [11] 688 push bc
- 03B5 21r52r04 [10] 689 ld hl, #___str_4
- 03B8 E5 [11] 690 push hl
- 03B9 D5 [11] 691 push de
- 03BA CDr00r00 [17] 692 call _sprintf
- 03BD 21 06 00 [10] 693 ld hl, #6
- 03C0 39 [11] 694 add hl, sp
- 03C1 F9 [ 6] 695 ld sp, hl
- 696 ;boot_rom.c:129: write_string(str1, 0xFF, 23, y + j);
- 03C2 DD 4E FE [19] 697 ld c, -2 (ix)
- 03C5 06 00 [ 7] 698 ld b, #0x00
- 03C7 03 [ 6] 699 inc bc
- 03C8 03 [ 6] 700 inc bc
- 03C9 03 [ 6] 701 inc bc
- 03CA 03 [ 6] 702 inc bc
- 03CB DD 5E F8 [19] 703 ld e, -8 (ix)
- 03CE DD 56 F9 [19] 704 ld d, -7 (ix)
- 03D1 C5 [11] 705 push bc
- 03D2 C5 [11] 706 push bc
- 03D3 21 17 00 [10] 707 ld hl, #0x0017
- 03D6 E5 [11] 708 push hl
- 03D7 3E FF [ 7] 709 ld a, #0xff
- 03D9 F5 [11] 710 push af
- 03DA 33 [ 6] 711 inc sp
- 03DB D5 [11] 712 push de
- 03DC CDr17r00 [17] 713 call _write_string
- 03DF 21 07 00 [10] 714 ld hl, #7
- 03E2 39 [11] 715 add hl, sp
- 03E3 F9 [ 6] 716 ld sp, hl
- 03E4 C1 [10] 717 pop bc
- 718 ;boot_rom.c:130: sprintf(str2, "%-4d", jy);
- 03E5 DD 7E FD [19] 719 ld a, -3 (ix)
- 03E8 5F [ 4] 720 ld e, a
- 03E9 17 [ 4] 721 rla
- 03EA 9F [ 4] 722 sbc a, a
- 03EB 57 [ 4] 723 ld d, a
- 03EC DD 6E F6 [19] 724 ld l, -10 (ix)
- 03EF DD 66 F7 [19] 725 ld h, -9 (ix)
- 03F2 C5 [11] 726 push bc
- 03F3 D5 [11] 727 push de
- 03F4 11r56r04 [10] 728 ld de, #___str_5
- 03F7 D5 [11] 729 push de
- 03F8 E5 [11] 730 push hl
- 03F9 CDr00r00 [17] 731 call _sprintf
- 03FC 21 06 00 [10] 732 ld hl, #6
- 03FF 39 [11] 733 add hl, sp
- 0400 F9 [ 6] 734 ld sp, hl
- 0401 C1 [10] 735 pop bc
- 736 ;boot_rom.c:131: write_string(str2, 0xFF, 28, y + j);
- 0402 DD 5E F4 [19] 737 ld e, -12 (ix)
- 0405 DD 56 F5 [19] 738 ld d, -11 (ix)
- 0408 C5 [11] 739 push bc
- 0409 21 1C 00 [10] 740 ld hl, #0x001c
- 040C E5 [11] 741 push hl
- 040D 3E FF [ 7] 742 ld a, #0xff
- 040F F5 [11] 743 push af
- 0410 33 [ 6] 744 inc sp
- 0411 D5 [11] 745 push de
- 0412 CDr17r00 [17] 746 call _write_string
- 0415 21 07 00 [10] 747 ld hl, #7
- 0418 39 [11] 748 add hl, sp
- 0419 F9 [ 6] 749 ld sp, hl
- 750 ;boot_rom.c:132: m <<= 1;
- 041A DD 7E F0 [19] 751 ld a, -16 (ix)
- 041D 87 [ 4] 752 add a, a
- 041E DD 77 F0 [19] 753 ld -16 (ix), a
- 754 ;boot_rom.c:123: for (char j = 0; j < 6; j++)
- 0421 DD 34 FE [23] 755 inc -2 (ix)
- 0424 C3r7Dr03 [10] 756 jp 00121$
- 0427 757 00106$:
- 758 ;boot_rom.c:135: hsync_last = hsync;
- 0427 3Ar02r00 [13] 759 ld a,(#_hsync + 0)
- 042A 32r03r00 [13] 760 ld (#_hsync_last + 0),a
- 761 ;boot_rom.c:136: vsync_last = vsync;
- 042D 3Ar04r00 [13] 762 ld a,(#_vsync + 0)
- 0430 32r05r00 [13] 763 ld (#_vsync_last + 0),a
- 764 ;boot_rom.c:138: }
- 0433 C3r70r02 [10] 765 jp 00109$
- 0436 766 ___str_3:
- 0436 2D 2D 2D 20 4D 69 767 .ascii "--- MiSTer Input Tester ---"
+ 0307 00 568 .db 0x00
+ 0308 569 ___str_1:
+ 0308 41 58 570 .ascii "AX"
+ 030A 00 571 .db 0x00
+ 030B 572 ___str_2:
+ 030B 41 59 573 .ascii "AY"
+ 030D 00 574 .db 0x00
+ 030E 575 ___str_3:
+ 030E 4A 4F 59 25 64 576 .ascii "JOY%d"
+ 0313 00 577 .db 0x00
+ 0314 578 ___str_4:
+ 0314 50 41 44 25 64 579 .ascii "PAD%d"
+ 0319 00 580 .db 0x00
+ 031A 581 ___str_5:
+ 031A 53 50 4E 25 64 582 .ascii "SPN%d"
+ 031F 00 583 .db 0x00
+ 584 ;boot_rom.c:94: void main()
+ 585 ; ---------------------------------
+ 586 ; Function main
+ 587 ; ---------------------------------
+ 0320 588 _main::
+ 0320 DD E5 [15] 589 push ix
+ 0322 DD 21 00 00 [14] 590 ld ix,#0
+ 0326 DD 39 [15] 591 add ix,sp
+ 0328 21 E5 FF [10] 592 ld hl, #-27
+ 032B 39 [11] 593 add hl, sp
+ 032C F9 [ 6] 594 ld sp, hl
+ 595 ;boot_rom.c:96: chram_size = chram_cols * chram_rows;
+ 032D 21r16r00 [10] 596 ld hl,#_chram_rows + 0
+ 0330 5E [ 7] 597 ld e, (hl)
+ 0331 21r15r00 [10] 598 ld hl,#_chram_cols + 0
+ 0334 66 [ 7] 599 ld h, (hl)
+ 0335 2E 00 [ 7] 600 ld l, #0x00
+ 0337 55 [ 4] 601 ld d, l
+ 0338 06 08 [ 7] 602 ld b, #0x08
+ 033A 603 00212$:
+ 033A 29 [11] 604 add hl, hl
+ 033B 30 01 [12] 605 jr NC,00213$
+ 033D 19 [11] 606 add hl, de
+ 033E 607 00213$:
+ 033E 10 FA [13] 608 djnz 00212$
+ 0340 22r00r00 [16] 609 ld (_chram_size), hl
+ 610 ;boot_rom.c:98: page_inputs();
+ 0343 CDr78r01 [17] 611 call _page_inputs
+ 612 ;boot_rom.c:100: while (1)
+ 0346 0E AB [ 7] 613 ld c, #0xab
+ 0348 614 00111$:
+ 615 ;boot_rom.c:102: hsync = input0 & 0x80;
+ 0348 3A 00 60 [13] 616 ld a,(#_input0 + 0)
+ 034B E6 80 [ 7] 617 and a, #0x80
+ 034D 32r02r00 [13] 618 ld (#_hsync + 0),a
+ 619 ;boot_rom.c:103: vsync = input0 & 0x40;
+ 0350 3A 00 60 [13] 620 ld a,(#_input0 + 0)
+ 0353 E6 40 [ 7] 621 and a, #0x40
+ 0355 FD 21r04r00 [14] 622 ld iy, #_vsync
+ 0359 FD 77 00 [19] 623 ld 0 (iy), a
+ 624 ;boot_rom.c:110: if (vsync && !vsync_last)
+ 035C FD 7E 00 [19] 625 ld a, 0 (iy)
+ 035F B7 [ 4] 626 or a, a
+ 0360 CArC4r05 [10] 627 jp Z, 00108$
+ 0363 3Ar05r00 [13] 628 ld a,(#_vsync_last + 0)
+ 0366 B7 [ 4] 629 or a, a
+ 0367 C2rC4r05 [10] 630 jp NZ, 00108$
+ 631 ;boot_rom.c:112: color++;
+ 036A 0C [ 4] 632 inc c
+ 633 ;boot_rom.c:113: write_string("--- MiSTer Input Tester ---", color, 6, 1);
+ 036B C5 [11] 634 push bc
+ 036C 21 01 00 [10] 635 ld hl, #0x0001
+ 036F E5 [11] 636 push hl
+ 0370 2E 06 [ 7] 637 ld l, #0x06
+ 0372 E5 [11] 638 push hl
+ 0373 79 [ 4] 639 ld a, c
+ 0374 F5 [11] 640 push af
+ 0375 33 [ 6] 641 inc sp
+ 0376 21rD3r05 [10] 642 ld hl, #___str_6
+ 0379 E5 [11] 643 push hl
+ 037A CDr17r00 [17] 644 call _write_string
+ 037D 21 07 00 [10] 645 ld hl, #7
+ 0380 39 [11] 646 add hl, sp
+ 0381 F9 [ 6] 647 ld sp, hl
+ 0382 C1 [10] 648 pop bc
+ 649 ;boot_rom.c:115: for (char b = 0; b < 2; b++)
+ 0383 1E 00 [ 7] 650 ld e, #0x00
+ 0385 651 00119$:
+ 0385 7B [ 4] 652 ld a, e
+ 0386 D6 02 [ 7] 653 sub a, #0x02
+ 0388 D2r30r04 [10] 654 jp NC, 00103$
+ 655 ;boot_rom.c:117: char m = 0b00000001;
+ 038B DD 36 FE 01 [19] 656 ld -2 (ix), #0x01
+ 657 ;boot_rom.c:118: for (char i = 0; i < 8; i++)
+ 038F DD 36 FD 00 [19] 658 ld -3 (ix), #0x00
+ 0393 659 00116$:
+ 0393 DD 7E FD [19] 660 ld a, -3 (ix)
+ 0396 D6 08 [ 7] 661 sub a, #0x08
+ 0398 D2r2Cr04 [10] 662 jp NC, 00120$
+ 663 ;boot_rom.c:120: char x = 7 + i + (b * 8);
+ 039B DD 7E FD [19] 664 ld a, -3 (ix)
+ 039E C6 07 [ 7] 665 add a, #0x07
+ 03A0 47 [ 4] 666 ld b, a
+ 03A1 7B [ 4] 667 ld a, e
+ 03A2 87 [ 4] 668 add a, a
+ 03A3 87 [ 4] 669 add a, a
+ 03A4 87 [ 4] 670 add a, a
+ 03A5 DD 77 F9 [19] 671 ld -7 (ix), a
+ 03A8 78 [ 4] 672 ld a, b
+ 03A9 DD 86 F9 [19] 673 add a, -7 (ix)
+ 03AC DD 77 FA [19] 674 ld -6 (ix), a
+ 675 ;boot_rom.c:121: for (j = 0; j < 6; j++)
+ 03AF DD 36 FF 00 [19] 676 ld -1 (ix), #0x00
+ 03B3 677 00113$:
+ 678 ;boot_rom.c:123: write_char((joystick[(b * 8) + (j * 32)] & m) ? asc_1 : asc_0, 0xFF, x, 4 + j);
+ 03B3 DD 7E FF [19] 679 ld a, -1 (ix)
+ 03B6 16 00 [ 7] 680 ld d, #0x00
+ 03B8 C6 04 [ 7] 681 add a, #0x04
+ 03BA DD 77 F5 [19] 682 ld -11 (ix), a
+ 03BD 7A [ 4] 683 ld a, d
+ 03BE CE 00 [ 7] 684 adc a, #0x00
+ 03C0 DD 77 F6 [19] 685 ld -10 (ix), a
+ 03C3 DD 7E FA [19] 686 ld a, -6 (ix)
+ 03C6 DD 77 F7 [19] 687 ld -9 (ix), a
+ 03C9 DD 36 F8 00 [19] 688 ld -8 (ix), #0x00
+ 03CD DD 7E FF [19] 689 ld a, -1 (ix)
+ 03D0 0F [ 4] 690 rrca
+ 03D1 0F [ 4] 691 rrca
+ 03D2 0F [ 4] 692 rrca
+ 03D3 E6 E0 [ 7] 693 and a, #0xe0
+ 03D5 DD 86 F9 [19] 694 add a, -7 (ix)
+ 03D8 47 [ 4] 695 ld b, a
+ 03D9 17 [ 4] 696 rla
+ 03DA 9F [ 4] 697 sbc a, a
+ 03DB 57 [ 4] 698 ld d, a
+ 03DC 3E 00 [ 7] 699 ld a, #<(_joystick)
+ 03DE 80 [ 4] 700 add a, b
+ 03DF 6F [ 4] 701 ld l, a
+ 03E0 3E 70 [ 7] 702 ld a, #>(_joystick)
+ 03E2 8A [ 4] 703 adc a, d
+ 03E3 67 [ 4] 704 ld h, a
+ 03E4 7E [ 7] 705 ld a, (hl)
+ 03E5 DD A6 FE [19] 706 and a, -2 (ix)
+ 03E8 B7 [ 4] 707 or a, a
+ 03E9 28 06 [12] 708 jr Z,00129$
+ 03EB 21r01r00 [10] 709 ld hl,#_asc_1 + 0
+ 03EE 46 [ 7] 710 ld b, (hl)
+ 03EF 18 04 [12] 711 jr 00130$
+ 03F1 712 00129$:
+ 03F1 21r00r00 [10] 713 ld hl,#_asc_0 + 0
+ 03F4 46 [ 7] 714 ld b, (hl)
+ 03F5 715 00130$:
+ 03F5 C5 [11] 716 push bc
+ 03F6 D5 [11] 717 push de
+ 03F7 DD 6E F5 [19] 718 ld l, -11 (ix)
+ 03FA DD 66 F6 [19] 719 ld h, -10 (ix)
+ 03FD E5 [11] 720 push hl
+ 03FE DD 6E F7 [19] 721 ld l, -9 (ix)
+ 0401 DD 66 F8 [19] 722 ld h, -8 (ix)
+ 0404 E5 [11] 723 push hl
+ 0405 3E FF [ 7] 724 ld a, #0xff
+ 0407 F5 [11] 725 push af
+ 0408 33 [ 6] 726 inc sp
+ 0409 C5 [11] 727 push bc
+ 040A 33 [ 6] 728 inc sp
+ 040B CDr74r00 [17] 729 call _write_char
+ 040E 21 06 00 [10] 730 ld hl, #6
+ 0411 39 [11] 731 add hl, sp
+ 0412 F9 [ 6] 732 ld sp, hl
+ 0413 D1 [10] 733 pop de
+ 0414 C1 [10] 734 pop bc
+ 735 ;boot_rom.c:121: for (j = 0; j < 6; j++)
+ 0415 DD 34 FF [23] 736 inc -1 (ix)
+ 0418 DD 7E FF [19] 737 ld a, -1 (ix)
+ 041B D6 06 [ 7] 738 sub a, #0x06
+ 041D 38 94 [12] 739 jr C,00113$
+ 740 ;boot_rom.c:125: m <<= 1;
+ 041F DD 7E FE [19] 741 ld a, -2 (ix)
+ 0422 87 [ 4] 742 add a, a
+ 0423 DD 77 FE [19] 743 ld -2 (ix), a
+ 744 ;boot_rom.c:118: for (char i = 0; i < 8; i++)
+ 0426 DD 34 FD [23] 745 inc -3 (ix)
+ 0429 C3r93r03 [10] 746 jp 00116$
+ 042C 747 00120$:
+ 748 ;boot_rom.c:115: for (char b = 0; b < 2; b++)
+ 042C 1C [ 4] 749 inc e
+ 042D C3r85r03 [10] 750 jp 00119$
+ 0430 751 00103$:
+ 752 ;boot_rom.c:129: y = 4;
+ 0430 DD 36 FB 04 [19] 753 ld -5 (ix), #0x04
+ 0434 DD 36 FC 00 [19] 754 ld -4 (ix), #0x00
+ 755 ;boot_rom.c:131: char m = 0b00000001;
+ 0438 06 01 [ 7] 756 ld b, #0x01
+ 757 ;boot_rom.c:134: for (j = 0; j < 6; j++)
+ 043A 21 06 00 [10] 758 ld hl, #0x0006
+ 043D 39 [11] 759 add hl, sp
+ 043E DD 75 F7 [19] 760 ld -9 (ix), l
+ 0441 DD 74 F8 [19] 761 ld -8 (ix), h
+ 0444 DD 7E F7 [19] 762 ld a, -9 (ix)
+ 0447 DD 77 F5 [19] 763 ld -11 (ix), a
+ 044A DD 7E F8 [19] 764 ld a, -8 (ix)
+ 044D DD 77 F6 [19] 765 ld -10 (ix), a
+ 0450 DD 36 FF 00 [19] 766 ld -1 (ix), #0x00
+ 0454 767 00121$:
+ 768 ;boot_rom.c:136: signed char jx = analog[(j * 16)];
+ 0454 11 00 71 [10] 769 ld de, #_analog+0
+ 0457 DD 6E FF [19] 770 ld l, -1 (ix)
+ 045A 26 00 [ 7] 771 ld h, #0x00
+ 045C 29 [11] 772 add hl, hl
+ 045D 29 [11] 773 add hl, hl
+ 045E 29 [11] 774 add hl, hl
+ 045F 29 [11] 775 add hl, hl
+ 0460 19 [11] 776 add hl, de
+ 0461 5E [ 7] 777 ld e, (hl)
+ 778 ;boot_rom.c:137: signed char jy = analog[(j * 16) + 8];
+ 0462 DD 7E FF [19] 779 ld a, -1 (ix)
+ 0465 07 [ 4] 780 rlca
+ 0466 07 [ 4] 781 rlca
+ 0467 07 [ 4] 782 rlca
+ 0468 07 [ 4] 783 rlca
+ 0469 E6 F0 [ 7] 784 and a, #0xf0
+ 046B C6 08 [ 7] 785 add a, #0x08
+ 046D 6F [ 4] 786 ld l, a
+ 046E 17 [ 4] 787 rla
+ 046F 9F [ 4] 788 sbc a, a
+ 0470 67 [ 4] 789 ld h, a
+ 0471 D5 [11] 790 push de
+ 0472 11 00 71 [10] 791 ld de, #_analog
+ 0475 19 [11] 792 add hl, de
+ 0476 D1 [10] 793 pop de
+ 0477 7E [ 7] 794 ld a, (hl)
+ 795 ;boot_rom.c:139: sprintf(stra, "%4d %4d", jx, jy);
+ 0478 6F [ 4] 796 ld l, a
+ 0479 17 [ 4] 797 rla
+ 047A 9F [ 4] 798 sbc a, a
+ 047B 67 [ 4] 799 ld h, a
+ 047C 7B [ 4] 800 ld a, e
+ 047D 17 [ 4] 801 rla
+ 047E 9F [ 4] 802 sbc a, a
+ 047F 57 [ 4] 803 ld d, a
+ 0480 E5 [11] 804 push hl
+ 0481 DD 6E F7 [19] 805 ld l, -9 (ix)
+ 0484 DD 66 F8 [19] 806 ld h, -8 (ix)
+ 0487 E5 [11] 807 push hl
+ 0488 FD E1 [14] 808 pop iy
+ 048A E1 [10] 809 pop hl
+ 048B C5 [11] 810 push bc
+ 048C E5 [11] 811 push hl
+ 048D D5 [11] 812 push de
+ 048E 21rEFr05 [10] 813 ld hl, #___str_7
+ 0491 E5 [11] 814 push hl
+ 0492 FD E5 [15] 815 push iy
+ 0494 CDr00r00 [17] 816 call _sprintf
+ 0497 21 08 00 [10] 817 ld hl, #8
+ 049A 39 [11] 818 add hl, sp
+ 049B F9 [ 6] 819 ld sp, hl
+ 049C C1 [10] 820 pop bc
+ 821 ;boot_rom.c:140: write_string(stra, 0xFF, 24, y + j);
+ 049D DD 5E FF [19] 822 ld e, -1 (ix)
+ 04A0 16 00 [ 7] 823 ld d, #0x00
+ 04A2 DD 6E FB [19] 824 ld l, -5 (ix)
+ 04A5 DD 66 FC [19] 825 ld h, -4 (ix)
+ 04A8 19 [11] 826 add hl, de
+ 04A9 DD 5E F5 [19] 827 ld e, -11 (ix)
+ 04AC DD 56 F6 [19] 828 ld d, -10 (ix)
+ 04AF C5 [11] 829 push bc
+ 04B0 E5 [11] 830 push hl
+ 04B1 21 18 00 [10] 831 ld hl, #0x0018
+ 04B4 E5 [11] 832 push hl
+ 04B5 3E FF [ 7] 833 ld a, #0xff
+ 04B7 F5 [11] 834 push af
+ 04B8 33 [ 6] 835 inc sp
+ 04B9 D5 [11] 836 push de
+ 04BA CDr17r00 [17] 837 call _write_string
+ 04BD 21 07 00 [10] 838 ld hl, #7
+ 04C0 39 [11] 839 add hl, sp
+ 04C1 F9 [ 6] 840 ld sp, hl
+ 04C2 C1 [10] 841 pop bc
+ 842 ;boot_rom.c:143: m <<= 1;
+ 04C3 CB 20 [ 8] 843 sla b
+ 844 ;boot_rom.c:134: for (j = 0; j < 6; j++)
+ 04C5 DD 34 FF [23] 845 inc -1 (ix)
+ 04C8 DD 7E FF [19] 846 ld a, -1 (ix)
+ 04CB D6 06 [ 7] 847 sub a, #0x06
+ 04CD 38 85 [12] 848 jr C,00121$
+ 849 ;boot_rom.c:148: m = 0b00000001;
+ 04CF 06 01 [ 7] 850 ld b, #0x01
+ 851 ;boot_rom.c:150: for (j = 0; j < 6; j++)
+ 04D1 21 03 00 [10] 852 ld hl, #0x0003
+ 04D4 39 [11] 853 add hl, sp
+ 04D5 DD 75 F7 [19] 854 ld -9 (ix), l
+ 04D8 DD 74 F8 [19] 855 ld -8 (ix), h
+ 04DB DD 7E F7 [19] 856 ld a, -9 (ix)
+ 04DE DD 77 F5 [19] 857 ld -11 (ix), a
+ 04E1 DD 7E F8 [19] 858 ld a, -8 (ix)
+ 04E4 DD 77 F6 [19] 859 ld -10 (ix), a
+ 04E7 DD 36 FF 00 [19] 860 ld -1 (ix), #0x00
+ 04EB 861 00123$:
+ 862 ;boot_rom.c:152: char px = paddle[(j * 8)];
+ 04EB DD 5E FF [19] 863 ld e, -1 (ix)
+ 04EE 16 00 [ 7] 864 ld d, #0x00
+ 04F0 6B [ 4] 865 ld l, e
+ 04F1 62 [ 4] 866 ld h, d
+ 04F2 29 [11] 867 add hl, hl
+ 04F3 29 [11] 868 add hl, hl
+ 04F4 29 [11] 869 add hl, hl
+ 04F5 3E 00 [ 7] 870 ld a, #<(_paddle)
+ 04F7 85 [ 4] 871 add a, l
+ 04F8 6F [ 4] 872 ld l, a
+ 04F9 3E 72 [ 7] 873 ld a, #>(_paddle)
+ 04FB 8C [ 4] 874 adc a, h
+ 04FC 67 [ 4] 875 ld h, a
+ 04FD 6E [ 7] 876 ld l, (hl)
+ 877 ;boot_rom.c:153: sprintf(strp, "%4d", px);
+ 04FE 26 00 [ 7] 878 ld h, #0x00
+ 0500 E5 [11] 879 push hl
+ 0501 DD 6E F7 [19] 880 ld l, -9 (ix)
+ 0504 DD 66 F8 [19] 881 ld h, -8 (ix)
+ 0507 E5 [11] 882 push hl
+ 0508 FD E1 [14] 883 pop iy
+ 050A E1 [10] 884 pop hl
+ 050B C5 [11] 885 push bc
+ 050C D5 [11] 886 push de
+ 050D E5 [11] 887 push hl
+ 050E 21rF7r05 [10] 888 ld hl, #___str_8
+ 0511 E5 [11] 889 push hl
+ 0512 FD E5 [15] 890 push iy
+ 0514 CDr00r00 [17] 891 call _sprintf
+ 0517 21 06 00 [10] 892 ld hl, #6
+ 051A 39 [11] 893 add hl, sp
+ 051B F9 [ 6] 894 ld sp, hl
+ 051C D1 [10] 895 pop de
+ 051D C1 [10] 896 pop bc
+ 897 ;boot_rom.c:154: write_string(strp, 0xFF, 6, y + j);
+ 051E 21 0B 00 [10] 898 ld hl, #0x000b
+ 0521 19 [11] 899 add hl, de
+ 0522 DD 5E F5 [19] 900 ld e, -11 (ix)
+ 0525 DD 56 F6 [19] 901 ld d, -10 (ix)
+ 0528 C5 [11] 902 push bc
+ 0529 E5 [11] 903 push hl
+ 052A 21 06 00 [10] 904 ld hl, #0x0006
+ 052D E5 [11] 905 push hl
+ 052E 3E FF [ 7] 906 ld a, #0xff
+ 0530 F5 [11] 907 push af
+ 0531 33 [ 6] 908 inc sp
+ 0532 D5 [11] 909 push de
+ 0533 CDr17r00 [17] 910 call _write_string
+ 0536 21 07 00 [10] 911 ld hl, #7
+ 0539 39 [11] 912 add hl, sp
+ 053A F9 [ 6] 913 ld sp, hl
+ 053B C1 [10] 914 pop bc
+ 915 ;boot_rom.c:155: m <<= 1;
+ 053C CB 20 [ 8] 916 sla b
+ 917 ;boot_rom.c:150: for (j = 0; j < 6; j++)
+ 053E DD 34 FF [23] 918 inc -1 (ix)
+ 0541 DD 7E FF [19] 919 ld a, -1 (ix)
+ 0544 D6 06 [ 7] 920 sub a, #0x06
+ 0546 38 A3 [12] 921 jr C,00123$
+ 922 ;boot_rom.c:160: m = 0b00000001;
+ 0548 06 01 [ 7] 923 ld b, #0x01
+ 924 ;boot_rom.c:162: for (j = 0; j < 6; j++)
+ 054A 21 00 00 [10] 925 ld hl, #0x0000
+ 054D 39 [11] 926 add hl, sp
+ 054E DD 75 F7 [19] 927 ld -9 (ix), l
+ 0551 DD 74 F8 [19] 928 ld -8 (ix), h
+ 0554 DD 7E F7 [19] 929 ld a, -9 (ix)
+ 0557 DD 77 F5 [19] 930 ld -11 (ix), a
+ 055A DD 7E F8 [19] 931 ld a, -8 (ix)
+ 055D DD 77 F6 [19] 932 ld -10 (ix), a
+ 0560 DD 36 FF 00 [19] 933 ld -1 (ix), #0x00
+ 0564 934 00125$:
+ 935 ;boot_rom.c:164: signed char sx = spinner[(j * 16)];
+ 0564 DD 5E FF [19] 936 ld e, -1 (ix)
+ 0567 16 00 [ 7] 937 ld d, #0x00
+ 0569 6B [ 4] 938 ld l, e
+ 056A 62 [ 4] 939 ld h, d
+ 056B 29 [11] 940 add hl, hl
+ 056C 29 [11] 941 add hl, hl
+ 056D 29 [11] 942 add hl, hl
+ 056E 29 [11] 943 add hl, hl
+ 056F 3E 00 [ 7] 944 ld a, #<(_spinner)
+ 0571 85 [ 4] 945 add a, l
+ 0572 6F [ 4] 946 ld l, a
+ 0573 3E 73 [ 7] 947 ld a, #>(_spinner)
+ 0575 8C [ 4] 948 adc a, h
+ 0576 67 [ 4] 949 ld h, a
+ 0577 7E [ 7] 950 ld a, (hl)
+ 951 ;boot_rom.c:165: sprintf(strs, "%4d", sx);
+ 0578 6F [ 4] 952 ld l, a
+ 0579 17 [ 4] 953 rla
+ 057A 9F [ 4] 954 sbc a, a
+ 057B 67 [ 4] 955 ld h, a
+ 057C E5 [11] 956 push hl
+ 057D DD 6E F7 [19] 957 ld l, -9 (ix)
+ 0580 DD 66 F8 [19] 958 ld h, -8 (ix)
+ 0583 E5 [11] 959 push hl
+ 0584 FD E1 [14] 960 pop iy
+ 0586 E1 [10] 961 pop hl
+ 0587 C5 [11] 962 push bc
+ 0588 D5 [11] 963 push de
+ 0589 E5 [11] 964 push hl
+ 058A 21rF7r05 [10] 965 ld hl, #___str_8
+ 058D E5 [11] 966 push hl
+ 058E FD E5 [15] 967 push iy
+ 0590 CDr00r00 [17] 968 call _sprintf
+ 0593 21 06 00 [10] 969 ld hl, #6
+ 0596 39 [11] 970 add hl, sp
+ 0597 F9 [ 6] 971 ld sp, hl
+ 0598 D1 [10] 972 pop de
+ 0599 C1 [10] 973 pop bc
+ 974 ;boot_rom.c:166: write_string(strs, 0xFF, 7, y + j);
+ 059A 21 12 00 [10] 975 ld hl, #0x0012
+ 059D 19 [11] 976 add hl, de
+ 059E DD 5E F5 [19] 977 ld e, -11 (ix)
+ 05A1 DD 56 F6 [19] 978 ld d, -10 (ix)
+ 05A4 C5 [11] 979 push bc
+ 05A5 E5 [11] 980 push hl
+ 05A6 21 07 00 [10] 981 ld hl, #0x0007
+ 05A9 E5 [11] 982 push hl
+ 05AA 3E FF [ 7] 983 ld a, #0xff
+ 05AC F5 [11] 984 push af
+ 05AD 33 [ 6] 985 inc sp
+ 05AE D5 [11] 986 push de
+ 05AF CDr17r00 [17] 987 call _write_string
+ 05B2 21 07 00 [10] 988 ld hl, #7
+ 05B5 39 [11] 989 add hl, sp
+ 05B6 F9 [ 6] 990 ld sp, hl
+ 05B7 C1 [10] 991 pop bc
+ 992 ;boot_rom.c:167: m <<= 1;
+ 05B8 CB 20 [ 8] 993 sla b
+ 994 ;boot_rom.c:162: for (j = 0; j < 6; j++)
+ 05BA DD 34 FF [23] 995 inc -1 (ix)
+ 05BD DD 7E FF [19] 996 ld a, -1 (ix)
+ 05C0 D6 06 [ 7] 997 sub a, #0x06
+ 05C2 38 A0 [12] 998 jr C,00125$
+ 05C4 999 00108$:
+ 1000 ;boot_rom.c:171: hsync_last = hsync;
+ 05C4 3Ar02r00 [13] 1001 ld a,(#_hsync + 0)
+ 05C7 32r03r00 [13] 1002 ld (#_hsync_last + 0),a
+ 1003 ;boot_rom.c:172: vsync_last = vsync;
+ 05CA 3Ar04r00 [13] 1004 ld a,(#_vsync + 0)
+ 05CD 32r05r00 [13] 1005 ld (#_vsync_last + 0),a
+ 1006 ;boot_rom.c:174: }
+ 05D0 C3r48r03 [10] 1007 jp 00111$
+ 05D3 1008 ___str_6:
+ 05D3 2D 2D 2D 20 4D 69 1009 .ascii "--- MiSTer Input Tester ---"
53 54 65 72 20 49
6E 70 75 74 20 54
65 73 74 65 72 20
2D 2D 2D
- 0451 00 768 .db 0x00
- 0452 769 ___str_4:
- 0452 25 34 64 770 .ascii "%4d"
- 0455 00 771 .db 0x00
- 0456 772 ___str_5:
- 0456 25 2D 34 64 773 .ascii "%-4d"
- 045A 00 774 .db 0x00
- 775 .area _CODE
- 776 .area _INITIALIZER
- 0000 777 __xinit__asc_0:
- 0000 30 778 .db #0x30 ; 48 '0'
- 0001 779 __xinit__asc_1:
- 0001 31 780 .db #0x31 ; 49 '1'
- 781 .area _CABS (ABS)
+ 05EE 00 1010 .db 0x00
+ 05EF 1011 ___str_7:
+ 05EF 25 34 64 20 25 34 1012 .ascii "%4d %4d"
+ 64
+ 05F6 00 1013 .db 0x00
+ 05F7 1014 ___str_8:
+ 05F7 25 34 64 1015 .ascii "%4d"
+ 05FA 00 1016 .db 0x00
+ 1017 .area _CODE
+ 1018 .area _INITIALIZER
+ 0000 1019 __xinit__asc_0:
+ 0000 30 1020 .db #0x30 ; 48 '0'
+ 0001 1021 __xinit__asc_1:
+ 0001 31 1022 .db #0x31 ; 49 '1'
+ 1023 .area _CABS (ABS)
diff --git a/src/boot_rom.map b/src/boot_rom.map
index 749e860..1a23bb5 100644
--- a/src/boot_rom.map
+++ b/src/boot_rom.map
@@ -42,28 +42,39 @@ Area Addr Size Decimal Bytes (A
0000000C l__HEADER8
0000000F l__GSINIT
00000200 s__CODE
- 00001098 l__CODE
- 00001298 s__HOME
- 00001298 s__INITIALIZER
- 0000129A s__GSINIT
- 000012A9 s__GSFINAL
+ 00001238 l__CODE
+ 00001438 s__HOME
+ 00001438 s__INITIALIZER
+ 0000143A s__GSINIT
+ 00001449 s__GSFINAL
00006000 _input0 boot_rom
00007000 _joystick boot_rom
00007100 _analog boot_rom
+ 00007200 _paddle boot_rom
+ 00007300 _spinner boot_rom
00008000 _chram boot_rom
00008800 _colram boot_rom
0000C000 s__DATA
0000C006 s__INITIALIZED
0000C008 s__BSEG
- 0000C008 s__BSS
- 0000C008 s__HEAP
-
ASxxxx Linker V03.00 + NoICE + sdld, page 2.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
-------------------------------- ---- ---- ------- ----- ------------
-_CODE 00000200 00001098 = 4248. bytes (REL,CON)
+. .ABS. 00000000 00000000 = 0. bytes (ABS,CON)
+
+ Value Global Global Defined In Module
+ ----- -------------------------------- ------------------------
+ 0000C008 s__BSS
+ 0000C008 s__HEAP
+
+ASxxxx Linker V03.00 + NoICE + sdld, page 3.
+Hexadecimal [32-Bits]
+
+Area Addr Size Decimal Bytes (Attributes)
+-------------------------------- ---- ---- ------- ----- ------------
+_CODE 00000200 00001238 = 4664. bytes (REL,CON)
Value Global Global Defined In Module
----- -------------------------------- ------------------------
@@ -76,16 +87,16 @@ _CODE 00000200 00001098 = 4248. bytes (R
0000027E _write_char boot_rom
000002B7 _page_border boot_rom
00000382 _page_inputs boot_rom
- 00000450 _main boot_rom
- 00000665 __mulint
- 0000066B __mul16
- 0000069F _vsprintf sprintf
- 000006D4 _sprintf sprintf
- 00000708 _strlen
- 00000832 __print_format printf_large
- 00001297 ___sdcc_call_hl
+ 0000052A _main boot_rom
+ 00000805 __mulint
+ 0000080B __mul16
+ 0000083F _vsprintf sprintf
+ 00000874 _sprintf sprintf
+ 000008A8 _strlen
+ 000009D2 __print_format printf_large
+ 00001437 ___sdcc_call_hl
-ASxxxx Linker V03.00 + NoICE + sdld, page 3.
+ASxxxx Linker V03.00 + NoICE + sdld, page 4.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -94,7 +105,7 @@ _HEADER0 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 4.
+ASxxxx Linker V03.00 + NoICE + sdld, page 5.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -103,7 +114,7 @@ _HEADER1 00000000 00000004 = 4. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 5.
+ASxxxx Linker V03.00 + NoICE + sdld, page 6.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -112,7 +123,7 @@ _HEADER2 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 6.
+ASxxxx Linker V03.00 + NoICE + sdld, page 7.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -121,7 +132,7 @@ _HEADER3 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 7.
+ASxxxx Linker V03.00 + NoICE + sdld, page 8.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -130,7 +141,7 @@ _HEADER4 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 8.
+ASxxxx Linker V03.00 + NoICE + sdld, page 9.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -139,7 +150,7 @@ _HEADER5 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 9.
+ASxxxx Linker V03.00 + NoICE + sdld, page 10.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -148,7 +159,7 @@ _HEADER6 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 10.
+ASxxxx Linker V03.00 + NoICE + sdld, page 11.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -157,22 +168,13 @@ _HEADER7 00000000 00000003 = 3. bytes (A
Value Global Global Defined In Module
----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 11.
+ASxxxx Linker V03.00 + NoICE + sdld, page 12.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
-------------------------------- ---- ---- ------- ----- ------------
_HEADER8 00000000 0000000C = 12. bytes (ABS,CON)
- Value Global Global Defined In Module
- ----- -------------------------------- ------------------------
-ASxxxx Linker V03.00 + NoICE + sdld, page 12.
-Hexadecimal [32-Bits]
-
-Area Addr Size Decimal Bytes (Attributes)
--------------------------------- ---- ---- ------- ----- ------------
-_INITIALIZER 00001298 00000002 = 2. bytes (REL,CON)
-
Value Global Global Defined In Module
----- -------------------------------- ------------------------
ASxxxx Linker V03.00 + NoICE + sdld, page 13.
@@ -180,24 +182,33 @@ Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
-------------------------------- ---- ---- ------- ----- ------------
-_GSINIT 0000129A 0000000F = 15. bytes (REL,CON)
+_INITIALIZER 00001438 00000002 = 2. bytes (REL,CON)
Value Global Global Defined In Module
----- -------------------------------- ------------------------
- 0000129A gsinit crt0
-
ASxxxx Linker V03.00 + NoICE + sdld, page 14.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
-------------------------------- ---- ---- ------- ----- ------------
-_GSFINAL 000012A9 00000001 = 1. bytes (REL,CON)
+_GSINIT 0000143A 0000000F = 15. bytes (REL,CON)
Value Global Global Defined In Module
----- -------------------------------- ------------------------
+ 0000143A gsinit crt0
+
ASxxxx Linker V03.00 + NoICE + sdld, page 15.
Hexadecimal [32-Bits]
+Area Addr Size Decimal Bytes (Attributes)
+-------------------------------- ---- ---- ------- ----- ------------
+_GSFINAL 00001449 00000001 = 1. bytes (REL,CON)
+
+ Value Global Global Defined In Module
+ ----- -------------------------------- ------------------------
+ASxxxx Linker V03.00 + NoICE + sdld, page 16.
+Hexadecimal [32-Bits]
+
Area Addr Size Decimal Bytes (Attributes)
-------------------------------- ---- ---- ------- ----- ------------
_DATA 0000C000 00000006 = 6. bytes (REL,CON)
@@ -210,7 +221,7 @@ _DATA 0000C000 00000006 = 6. bytes (R
0000C004 _vsync boot_rom
0000C005 _vsync_last boot_rom
-ASxxxx Linker V03.00 + NoICE + sdld, page 16.
+ASxxxx Linker V03.00 + NoICE + sdld, page 17.
Hexadecimal [32-Bits]
Area Addr Size Decimal Bytes (Attributes)
@@ -222,7 +233,7 @@ _INITIALIZED 0000C006 00000002 = 2. bytes (R
0000C006 _asc_0 boot_rom
0000C007 _asc_1 boot_rom
-ASxxxx Linker V03.00 + NoICE + sdld, page 17.
+ASxxxx Linker V03.00 + NoICE + sdld, page 18.
Files Linked [ module(s) ]
@@ -238,7 +249,7 @@ Libraries Linked [ object file ]
/usr/bin/../share/sdcc/lib/z80/z80.lib [ printf_large.rel ]
/usr/bin/../share/sdcc/lib/z80/z80.lib [ __sdcc_call_hl.rel ]
-ASxxxx Linker V03.00 + NoICE + sdld, page 18.
+ASxxxx Linker V03.00 + NoICE + sdld, page 19.
User Base Address Definitions
diff --git a/src/boot_rom.noi b/src/boot_rom.noi
index 6b34903..29841bc 100644
--- a/src/boot_rom.noi
+++ b/src/boot_rom.noi
@@ -33,14 +33,16 @@ DEF l__DATA 0x6
DEF l__HEADER8 0xC
DEF l__GSINIT 0xF
DEF s__CODE 0x200
-DEF l__CODE 0x1098
-DEF s__HOME 0x1298
-DEF s__INITIALIZER 0x1298
-DEF s__GSINIT 0x129A
-DEF s__GSFINAL 0x12A9
+DEF l__CODE 0x1238
+DEF s__HOME 0x1438
+DEF s__INITIALIZER 0x1438
+DEF s__GSINIT 0x143A
+DEF s__GSFINAL 0x1449
DEF _input0 0x6000
DEF _joystick 0x7000
DEF _analog 0x7100
+DEF _paddle 0x7200
+DEF _spinner 0x7300
DEF _chram 0x8000
DEF _colram 0x8800
DEF s__DATA 0xC000
@@ -57,15 +59,15 @@ DEF _write_string 0x221
DEF _write_char 0x27E
DEF _page_border 0x2B7
DEF _page_inputs 0x382
-DEF _main 0x450
-DEF __mulint 0x665
-DEF __mul16 0x66B
-DEF _vsprintf 0x69F
-DEF _sprintf 0x6D4
-DEF _strlen 0x708
-DEF __print_format 0x832
-DEF ___sdcc_call_hl 0x1297
-DEF gsinit 0x129A
+DEF _main 0x52A
+DEF __mulint 0x805
+DEF __mul16 0x80B
+DEF _vsprintf 0x83F
+DEF _sprintf 0x874
+DEF _strlen 0x8A8
+DEF __print_format 0x9D2
+DEF ___sdcc_call_hl 0x1437
+DEF gsinit 0x143A
DEF _chram_size 0xC000
DEF _hsync 0xC002
DEF _hsync_last 0xC003
diff --git a/src/boot_rom.sym b/src/boot_rom.sym
index d14878f..2045bd6 100644
--- a/src/boot_rom.sym
+++ b/src/boot_rom.sym
@@ -7,12 +7,15 @@ Symbol Table
.__.ABS. = 0000 G
.__.CPU. = 0000 L
.__.H$L. = 0000 L
- 0 ___str_0 022A R
- 0 ___str_1 0239 R
- 0 ___str_2 0240 R
- 0 ___str_3 0436 R
- 0 ___str_4 0452 R
- 0 ___str_5 0456 R
+ 0 ___str_0 02F9 R
+ 0 ___str_1 0308 R
+ 0 ___str_2 030B R
+ 0 ___str_3 030E R
+ 0 ___str_4 0314 R
+ 0 ___str_5 031A R
+ 0 ___str_6 05D3 R
+ 0 ___str_7 05EF R
+ 0 ___str_8 05F7 R
__mulint **** GX
7 __xinit__asc_0 0000 R
7 __xinit__asc_1 0001 R
@@ -29,9 +32,11 @@ Symbol Table
1 _hsync_last 0003 GR
_input0 = 6000 G
_joystick = 7000 G
- 0 _main 0246 GR
+ 0 _main 0320 GR
+ _paddle = 7200 G
0 _page_border 00AD GR
0 _page_inputs 0178 GR
+ _spinner = 7300 G
_sprintf **** GX
_strlen **** GX
1 _vsync 0004 GR
@@ -45,7 +50,7 @@ Hexadecimal [16-Bits]
Area Table
- 0 _CODE size 45B flags 0
+ 0 _CODE size 5FB flags 0
1 _DATA size 6 flags 0
2 _INITIALIZED size 2 flags 0
3 _DABS size 0 flags 8
diff --git a/verilator/sim.v b/verilator/sim.v
index 8792ff3..0788661 100644
--- a/verilator/sim.v
+++ b/verilator/sim.v
@@ -10,7 +10,6 @@
module top(
input clk_sys/*verilator public_flat*/,
- input clk_vid/*verilator public_flat*/,
input reset/*verilator public_flat*/,
// 6 joysticks, 32 buttons each
@@ -60,9 +59,19 @@ module top(
output reg ioctl_wait=1'b0
);
+// Clock divider from JTFRAME
+wire ce_pix;
+/* verilator lint_off PINMISSING */
+jtframe_cen24 divider
+(
+ .clk(clk_sys),
+ .cen4(ce_pix)
+);
+/* verilator lint_on PINMISSING */
+
system system(
.clk_sys(clk_sys),
- .ce_pix(clk_sys),
+ .ce_pix(ce_pix),
.reset(reset | ioctl_download),
.VGA_HS(VGA_HS),
.VGA_VS(VGA_VS),
@@ -79,7 +88,7 @@ system system(
.joystick({joystick_5,joystick_4,joystick_3,joystick_2,joystick_1,joystick_0}),
.analog({joystick_analog_5,joystick_analog_4,joystick_analog_3,joystick_analog_2,joystick_analog_1,joystick_analog_0}),
.paddle({paddle_5,paddle_4,paddle_3,paddle_2,paddle_1,paddle_0}),
- .spinner({spinner_5,spinner_4,spinner_3,spinner_2,spinner_1,spinner_0})
+ .spinner({7'b0,spinner_5,7'b0,spinner_4,7'b0,spinner_3,7'b0,spinner_2,7'b0,spinner_1,7'b0,spinner_0})
);
endmodule
diff --git a/verilator/sim_main.cpp b/verilator/sim_main.cpp
index 9b9d2bc..374d076 100644
--- a/verilator/sim_main.cpp
+++ b/verilator/sim_main.cpp
@@ -73,15 +73,12 @@ double sc_time_stamp() { // Called by $time in Verilog.
return main_time;
}
-int clockSpeed = 24; // This is not used, just a reminder for the dividers below
-SimClock clk_sys(1); // 12mhz
-SimClock clk_pix(1); // 6mhz
+SimClock clk_sys(1);
void resetSim() {
main_time = 0;
top->reset = 1;
clk_sys.Reset();
- clk_pix.Reset();
}
int verilate() {
@@ -95,18 +92,10 @@ int verilate() {
// Clock dividers
clk_sys.Tick();
- clk_pix.Tick();
// Set system clock in core
top->clk_sys = clk_sys.clk;
- top->clk_vid = clk_pix.clk;
-
- // Output pixels on rising edge of pixel clock
- if (clk_pix.IsRising()) {
- uint32_t colour = 0xFF000000 | top->VGA_B << 16 | top->VGA_G << 8 | top->VGA_R;
- video.Clock(top->VGA_HB, top->VGA_VB, top->VGA_HS, top->VGA_VS, colour);
- }
-
+
// Simulate both edges of system clock
if (clk_sys.clk != clk_sys.old) {
if (clk_sys.clk) { bus.BeforeEval(); }
@@ -114,6 +103,12 @@ int verilate() {
if (clk_sys.clk) { bus.AfterEval(); }
}
+ // Output pixels on rising edge of pixel clock
+ if (clk_sys.IsRising() && top->top__DOT__system__DOT__ce_pix) {
+ uint32_t colour = 0xFF000000 | top->VGA_B << 16 | top->VGA_G << 8 | top->VGA_R;
+ video.Clock(top->VGA_HB, top->VGA_VB, top->VGA_HS, top->VGA_VS, colour);
+ }
+
main_time++;
return 1;
@@ -281,6 +276,11 @@ int main(int argc, char** argv, char** env) {
top->joystick_analog_1 -= 1;
top->joystick_analog_1 += 256;
+ top->paddle_0 += 1;
+ top->paddle_1 -= 1;
+
+ top->spinner_0 += 1;
+ top->spinner_1 -= 1;
// Run simulation
if (run_enable) {