Skip to content

Commit 8b1e02c

Browse files
committed
XuNet OS
1 parent 09fedba commit 8b1e02c

File tree

384 files changed

+33366
-0
lines changed

Some content is hidden

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

384 files changed

+33366
-0
lines changed

XuNet OS/Makefile

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
#######################
2+
# XuNet OS Makefile�ļ�
3+
# B Y : I N B O R A
4+
#######################
5+
6+
7+
TOOLPATH = ./z_tools/
8+
INCPATH = ./z_tools/XuNetInclude/
9+
10+
MAKE = $(TOOLPATH)make.exe -r
11+
EDIMG = $(TOOLPATH)edimg.exe
12+
COPY = copy
13+
DEL = del
14+
15+
default :
16+
$(MAKE) XuNet_OS.img
17+
18+
19+
XuNet_OS.img : kernel/ipl20.bin kernel/XuNet_OS.sys Makefile
20+
$(EDIMG) imgin:./z_tools/fdimg0at.tek \
21+
wbinimg src:kernel/ipl20.bin len:512 from:0 to:0 \
22+
copy from:kernel/XuNet_OS.sys to:@: \
23+
copy from:kernel/ipl20.nas to:@: \
24+
copy from:apps/type/type.hel to:@: \
25+
copy from:apps/date/date.hel to:@: \
26+
copy from:apps/tview/tview.hel to:@: \
27+
copy from:apps/gview/gview.hel to:@: \
28+
copy from:apps/about/about.hel to:@: \
29+
copy from:apps/music/music.hel to:@: \
30+
copy from:apps/invader/invader.hel to:@: \
31+
copy from:apps/calc/calc.hel to:@: \
32+
copy from:apps/pc/pc.hel to:@: \
33+
copy from:apps/pc/logo.IS to:@: \
34+
copy from:apps/2dball/2dball.hel to:@: \
35+
copy from:apps/hview/hview.hel to:@: \
36+
copy from:apps/note/note.hel to:@: \
37+
copy from:apps/csvv/csvv.hel to:@: \
38+
copy from:apps/cpuid/cpuid.hel to:@: \
39+
copy from:apps/cvtg/cvtg.hel to:@: \
40+
copy from:apps/csvv/csvv.hel to:@: \
41+
copy from:apps/csvv/csvv.hel to:@: \
42+
copy from:apps/video/video.hel to:@: \
43+
copy from:apps/mtorz/mtorz.hel to:@: \
44+
copy from:data/daigo.mld to:@: \
45+
copy from:data/daiku.mld to:@: \
46+
copy from:data/star.mld to:@: \
47+
copy from:data/a.htm to:@: \
48+
copy from:data/moon.txt to:@: \
49+
copy from:data/dog.jpg to:@: \
50+
copy from:data/XuNet.vdo to:@: \
51+
copy from:data/help.txt to:@: \
52+
copy from:data/chinese/HZK16.fnt to:@: \
53+
copy from:data/XuNetos.jpg to:@: \
54+
copy from:data/LOGO.bmp to:@: \
55+
copy from:data/1.csv to:@: \
56+
imgout:XuNet_OS.img
57+
58+
59+
run :
60+
$(MAKE) XuNet_OS.img
61+
$(COPY) XuNet_OS.img .\z_tools\qemu\fdimage0.bin
62+
$(MAKE) -C ./z_tools/qemu
63+
64+
65+
66+
full :
67+
$(MAKE) -C haribote
68+
$(MAKE) -C apilib
69+
$(MAKE) -C date
70+
$(MAKE) -C type
71+
$(MAKE) -C gview
72+
$(MAKE) -C tview
73+
$(MAKE) -C about
74+
$(MAKE) -C counter
75+
$(MAKE) -C mmlplay
76+
$(MAKE) -C invader
77+
$(MAKE) -C calc
78+
$(MAKE) XuNet_OS.img
79+
80+
run_full :
81+
$(MAKE) full
82+
$(COPY) XuNet_OS.img .\z_tools\qemu\fdimage0.bin
83+
$(MAKE) -C ./z_tools/qemu
84+
85+
run_os :
86+
$(MAKE) -C XuNet_OS
87+
$(MAKE) run
88+
89+
clean :

XuNet OS/apps/2dball/2dball.bim

467 Bytes
Binary file not shown.

XuNet OS/apps/2dball/2dball.c

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
#include "apilib.h"
2+
3+
int _main()
4+
{
5+
int win, i, j, k, dis;
6+
char buf[216 * 237];
7+
struct POINT {
8+
int x, y;
9+
};
10+
static struct POINT table[16] = { //绘制点,线
11+
{ 204, 129 }, { 195, 90 }, { 172, 58 }, { 137, 38 }, { 98, 34 },
12+
{ 61, 46 }, { 31, 73 }, { 15, 110 }, { 15, 148 }, { 31, 185 },
13+
{ 61, 212 }, { 98, 224 }, { 137, 220 }, { 172, 200 }, { 195, 168 },
14+
{ 204, 129 }
15+
};
16+
17+
win = api_openwin(buf, 216, 237, 255, "2dBall");//准备窗口
18+
api_boxfilwin(win, 8, 29, 207, 228, 0);
19+
20+
//循环计数(来回循环)
21+
for (;;) {
22+
k++;
23+
for (i = 0; i <= 14; i++) {
24+
for (j = i + 1; j <= 15; j++) {
25+
dis = j - i; // 两点间的距离
26+
if (dis >= 8)
27+
dis = 15 - dis; // 逆向计数
28+
if (dis != 0)
29+
api_linewin(win, table[i].x, table[i].y, table[j].x, table[j].y, k - dis);
30+
}
31+
}
32+
}
33+
34+
return 0;
35+
}

XuNet OS/apps/2dball/2dball.hel

316 Bytes
Binary file not shown.

XuNet OS/apps/2dball/2dball.lst

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
1 00000000 [FORMAT "WCOFF"]
2+
2 00000000 [INSTRSET "i486p"]
3+
3 00000000 [OPTIMIZE 1]
4+
4 00000000 [OPTION 1]
5+
5 00000000 [BITS 32]
6+
6 00000000 EXTERN __alloca
7+
7 00000000 EXTERN _api_openwin
8+
8 00000000 EXTERN _api_boxfilwin
9+
9 00000000 EXTERN _table.0
10+
10 00000000 EXTERN _api_linewin
11+
11 00000000 [FILE "2dball.c"]
12+
12 [SECTION .data]
13+
13 00000000 _table.0:
14+
14 00000000 000000CC DD 204
15+
15 00000004 00000081 DD 129
16+
16 00000008 000000C3 DD 195
17+
17 0000000C 0000005A DD 90
18+
18 00000010 000000AC DD 172
19+
19 00000014 0000003A DD 58
20+
20 00000018 00000089 DD 137
21+
21 0000001C 00000026 DD 38
22+
22 00000020 00000062 DD 98
23+
23 00000024 00000022 DD 34
24+
24 00000028 0000003D DD 61
25+
25 0000002C 0000002E DD 46
26+
26 00000030 0000001F DD 31
27+
27 00000034 00000049 DD 73
28+
28 00000038 0000000F DD 15
29+
29 0000003C 0000006E DD 110
30+
30 00000040 0000000F DD 15
31+
31 00000044 00000094 DD 148
32+
32 00000048 0000001F DD 31
33+
33 0000004C 000000B9 DD 185
34+
34 00000050 0000003D DD 61
35+
35 00000054 000000D4 DD 212
36+
36 00000058 00000062 DD 98
37+
37 0000005C 000000E0 DD 224
38+
38 00000060 00000089 DD 137
39+
39 00000064 000000DC DD 220
40+
40 00000068 000000AC DD 172
41+
41 0000006C 000000C8 DD 200
42+
42 00000070 000000C3 DD 195
43+
43 00000074 000000A8 DD 168
44+
44 00000078 000000CC DD 204
45+
45 0000007C 00000081 DD 129
46+
46 00000080 LC0:
47+
47 00000080 32 64 42 61 6C 6C 00 DB "2dBall",0x00
48+
48 [SECTION .text]
49+
49 00000000 GLOBAL __main
50+
50 00000000 __main:
51+
51 00000000 55 PUSH EBP
52+
52 00000001 B8 0000C804 MOV EAX,51204
53+
53 00000006 89 E5 MOV EBP,ESP
54+
54 00000008 57 PUSH EDI
55+
55 00000009 56 PUSH ESI
56+
56 0000000A 53 PUSH EBX
57+
57 0000000B E8 [00000000] CALL __alloca
58+
58 00000010 8D 85 FFFF37F4 LEA EAX,DWORD [-51212+EBP]
59+
59 00000016 68 [00000080] PUSH LC0
60+
60 0000001B 68 000000FF PUSH 255
61+
61 00000020 68 000000ED PUSH 237
62+
62 00000025 68 000000D8 PUSH 216
63+
63 0000002A 50 PUSH EAX
64+
64 0000002B E8 [00000000] CALL _api_openwin
65+
65 00000030 6A 00 PUSH 0
66+
66 00000032 68 000000E4 PUSH 228
67+
67 00000037 89 C7 MOV EDI,EAX
68+
68 00000039 68 000000CF PUSH 207
69+
69 0000003E 6A 1D PUSH 29
70+
70 00000040 6A 08 PUSH 8
71+
71 00000042 50 PUSH EAX
72+
72 00000043 E8 [00000000] CALL _api_boxfilwin
73+
73 00000048 83 C4 2C ADD ESP,44
74+
74 0000004B L2:
75+
75 0000004B FF 85 FFFF37F0 INC DWORD [-51216+EBP]
76+
76 00000051 31 F6 XOR ESI,ESI
77+
77 00000053 L16:
78+
78 00000053 8D 5E 01 LEA EBX,DWORD [1+ESI]
79+
79 00000056 83 FB 0F CMP EBX,15
80+
80 00000059 7F 41 JG L19
81+
81 0000005B L15:
82+
82 0000005B 89 DA MOV EDX,EBX
83+
83 0000005D 29 F2 SUB EDX,ESI
84+
84 0000005F 83 FA 07 CMP EDX,7
85+
85 00000062 7E 09 JLE L13
86+
86 00000064 B8 0000000F MOV EAX,15
87+
87 00000069 29 D0 SUB EAX,EDX
88+
88 0000006B 89 C2 MOV EDX,EAX
89+
89 0000006D L13:
90+
90 0000006D 85 D2 TEST EDX,EDX
91+
91 0000006F 74 25 JE L11
92+
92 00000071 8B 85 FFFF37F0 MOV EAX,DWORD [-51216+EBP]
93+
93 00000077 29 D0 SUB EAX,EDX
94+
94 00000079 50 PUSH EAX
95+
95 0000007A B8 [00000000] MOV EAX,_table.0
96+
96 0000007F FF 74 D8 04 PUSH DWORD [4+EAX+EBX*8]
97+
97 00000083 FF 34 D8 PUSH DWORD [EAX+EBX*8]
98+
98 00000086 FF 74 F0 04 PUSH DWORD [4+EAX+ESI*8]
99+
99 0000008A FF 34 F0 PUSH DWORD [EAX+ESI*8]
100+
100 0000008D 57 PUSH EDI
101+
101 0000008E E8 [00000000] CALL _api_linewin
102+
102 00000093 83 C4 18 ADD ESP,24
103+
103 00000096 L11:
104+
104 00000096 43 INC EBX
105+
105 00000097 83 FB 0F CMP EBX,15
106+
106 0000009A 7E BF JLE L15
107+
107 0000009C L19:
108+
108 0000009C 46 INC ESI
109+
109 0000009D 83 FE 0E CMP ESI,14
110+
110 000000A0 7E B1 JLE L16
111+
111 000000A2 EB A7 JMP L2

XuNet OS/apps/2dball/2dball.map

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
text size : 295(0x00127)
2+
data size : 135(0x00087)
3+
bss size : 0(0x00000)
4+
5+
0x00000024 : (.text)
6+
0x00000024 : __main
7+
0x000000C8 : _api_openwin
8+
0x000000C8 : (.text)
9+
0x000000EA : _api_boxfilwin
10+
0x000000EA : (.text)
11+
0x00000112 : _api_linewin
12+
0x00000112 : (.text)
13+
0x0000013A : __alloca
14+
0x0000013A : (.text)
15+
0x00000142 : (.text)
16+
0x00000142 : _HariStartup
17+
0x00000000 : (.data)
18+
0x00000000 : (.data)
19+
0x00000000 : (.data)
20+
0x00000000 : (.data)
21+
0x00000000 : (.data)
22+
0x00011800 : (.data)
23+
0x00000000 : (.bss)
24+
0x00000000 : (.bss)
25+
0x00000000 : (.bss)
26+
0x00000000 : (.bss)
27+
0x00000000 : (.bss)
28+
0x00000000 : (.bss)

XuNet OS/apps/2dball/2dball.obj

796 Bytes
Binary file not shown.

XuNet OS/apps/2dball/Helo_OS.img

1.41 MB
Binary file not shown.

XuNet OS/apps/2dball/Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
APP = 2dball
2+
STACK = 70k
3+
MALLOC = 0k
4+
5+
include ../app_make.txt

XuNet OS/apps/2dball/cmd.bat

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
cmd.exe

0 commit comments

Comments
 (0)