From svnnotify ¡÷ sourceforge.jp Tue Mar 3 19:01:14 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Tue, 03 Mar 2009 19:01:14 +0900 Subject: [PhoeniOS-SVN] [Commit] [65] Message-ID: <1236074474.676009.15722.nullmailer@users.sourceforge.jp> Revision: 65 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=65 Author: litesystems Date: 2009-03-03 19:01:14 +0900 (Tue, 03 Mar 2009) Log Message: ----------- Modified Paths: -------------- PhoeniOS/trunk/build.txt PhoeniOS/trunk/system/Makefile PhoeniOS/trunk/system/asmhead.nas PhoeniOS/trunk/system/bootinfo.cpp PhoeniOS/trunk/system/bootinfo.h PhoeniOS/trunk/system/bootpack.cpp PhoeniOS/trunk/system/color.cpp PhoeniOS/trunk/system/color.h PhoeniOS/trunk/system/descriptor.cpp PhoeniOS/trunk/system/descriptor.h PhoeniOS/trunk/system/drawing.cpp PhoeniOS/trunk/system/drawing.h PhoeniOS/trunk/system/make.bat PhoeniOS/trunk/system/nask_dsc.nas PhoeniOS/trunk/system/nask_io.nas PhoeniOS/trunk/system/palette.cpp PhoeniOS/trunk/system/palette.h PhoeniOS/trunk/system/phoenios.h PhoeniOS/trunk/system/phoenios.sys Added Paths: ----------- PhoeniOS/trunk/system/background.cpp PhoeniOS/trunk/system/background.h PhoeniOS/trunk/system/int.cpp PhoeniOS/trunk/system/int.h PhoeniOS/trunk/system/mouse.cpp PhoeniOS/trunk/system/mouse.h PhoeniOS/trunk/system/nask_dsc.h PhoeniOS/trunk/system/nask_int.h PhoeniOS/trunk/system/nask_int.nas PhoeniOS/trunk/system/nask_io.h Removed Paths: ------------- PhoeniOS/trunk/system/graphic.cpp PhoeniOS/trunk/system/graphic.h PhoeniOS/trunk/system/naskfunc.h -------------- next part -------------- Modified: PhoeniOS/trunk/build.txt =================================================================== --- PhoeniOS/trunk/build.txt 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/build.txt 2009-03-03 10:01:14 UTC (rev 65) @@ -1 +1 @@ -23 \ No newline at end of file +195 \ No newline at end of file Modified: PhoeniOS/trunk/system/Makefile =================================================================== --- PhoeniOS/trunk/system/Makefile 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/Makefile 2009-03-03 10:01:14 UTC (rev 65) @@ -1,12 +1,15 @@ -OBJS_BOOTPACK = bootpack.obj bootinfo.obj descriptor.obj drawing.obj graphic.obj palette.obj color.obj \ +OBJS_BOOTPACK = bootpack.obj background.obj bootinfo.obj color.obj descriptor.obj drawing.obj int.obj palette.obj mouse.obj \ hankaku.obj \ - nask_io.obj nask_dsc.obj + nask_dsc.obj nask_int.obj nask_io.obj TOOLPATH = ../../z_tools/ +INCPATH = ../../z_tools/haribote/ MAKE = $(TOOLPATH)make.exe -r NASK = $(TOOLPATH)nask.exe CPP = $(TOOLPATH)c++.exe -I../../z_tools/haribote -Os -Wall -nostdlib -fno-builtin -fno-exceptions -fno-rtti -B$(TOOLPATH) -c +CC1 = $(TOOLPATH)cc1.exe -I$(INCPATH) -Os -Wall -quiet +GAS2NASK = $(TOOLPATH)gas2nask.exe -a OBJ2BIM = $(TOOLPATH)obj2bim.exe MAKEFONT = $(TOOLPATH)makefont.exe BIN2OBJ = $(TOOLPATH)bin2obj.exe @@ -48,6 +51,12 @@ %.obj : %.cpp Makefile $(CPP) -o $*.obj $*.cpp +%.gas : %.c Makefile + $(CC1) -o $*.gas $*.c + +%.nas : %.gas Makefile + $(GAS2NASK) $*.gas $*.nas + %.obj : %.nas Makefile $(NASK) $*.nas $*.obj $*.lst Modified: PhoeniOS/trunk/system/asmhead.nas =================================================================== --- PhoeniOS/trunk/system/asmhead.nas 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/asmhead.nas 2009-03-03 10:01:14 UTC (rev 65) @@ -1,6 +1,6 @@ ; --------------------------------------------------------- ; File: asmhead.nas -; Update: 2008/12/12 +; Update: 2009/03/02 ; License: GNU General Public License v3 ; Description: PhoeniOS??????????????? ; --------------------------------------------------------- Added: PhoeniOS/trunk/system/background.cpp =================================================================== --- PhoeniOS/trunk/system/background.cpp (rev 0) +++ PhoeniOS/trunk/system/background.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,22 @@ +/* --------------------------------------------------------- */ +/* File: background.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Graphic { + void Background::Draw(void) { + System::Information::BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 0, 0, binfo.scrnx, binfo.scrny); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 24, Color::RGB24To8(255, 255, 255), (unsigned char *) "PhoeniOS"); + } +}; +}; +#endif Added: PhoeniOS/trunk/system/background.h =================================================================== --- PhoeniOS/trunk/system/background.h (rev 0) +++ PhoeniOS/trunk/system/background.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,18 @@ +/* --------------------------------------------------------- */ +/* File: background.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Background { + public: + static void Draw(void); + }; +}; +}; +#endif Modified: PhoeniOS/trunk/system/bootinfo.cpp =================================================================== --- PhoeniOS/trunk/system/bootinfo.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/bootinfo.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,14 +1,13 @@ /* --------------------------------------------------------- */ /* File: bootinfo.cpp */ -/* Update: 2008/12/19 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: BootInfo?????? */ /* --------------------------------------------------------- */ #include "phoenios.h" -#define ADR_BOOTINFO 0x00001000 - +#ifdef __cplusplus namespace System { namespace Information { BootInfo::BootInfo(void) { @@ -19,8 +18,9 @@ scrnx = *((short *)(ADR_BOOTINFO + 0x00000004)); scrny = *((short *)(ADR_BOOTINFO + 0x00000006)); vram = (char *) *((int *)(ADR_BOOTINFO + 0x00000008)); - + return; } }; }; +#endif Modified: PhoeniOS/trunk/system/bootinfo.h =================================================================== --- PhoeniOS/trunk/system/bootinfo.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/bootinfo.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,12 +1,13 @@ /* --------------------------------------------------------- */ /* File: bootinfo.h */ -/* Update: 2008/12/19 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: BootInfo????? */ /* --------------------------------------------------------- */ #define ADR_BOOTINFO 0x00001000 +#ifdef __cplusplus namespace System { namespace Information { class BootInfo { @@ -22,3 +23,4 @@ }; }; }; +#endif Modified: PhoeniOS/trunk/system/bootpack.cpp =================================================================== --- PhoeniOS/trunk/system/bootpack.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/bootpack.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,27 +1,48 @@ /* --------------------------------------------------------- */ /* File: bootpack.cpp */ -/* Update: 2009/02/25 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???? */ /* --------------------------------------------------------- */ +#include #include "phoenios.h" +extern "C" { + void Main(void); +}; + using namespace System::Descriptor; using namespace System::Graphic; using namespace System::Information; +using namespace System::Interrupt; +using namespace System::Mouse; -extern "C" { - void Main(void); -}; +void Main(void) +{ + BootInfo binfo; + char s[40], mcursor[256]; + int mx, my; -void Main(void) { Descriptor::Initialize(); - Palette::Initialize(); /* ???????*/ - Background::Draw(); /* ???? */ + PIC::Initialize(); + + io_sti(); - for (;;) - { + Palette::Initialize(); + Background::Draw(); + + mx = (binfo.scrnx - 16) / 2; + my = (binfo.scrny - 28 - 16) / 2; + Cursor::Initialize(mcursor, Color::RGB24To8(0, 64, 128)); + Cursor::PutBlock_8(binfo.vram, binfo.scrnx, 16, 16, mx, my, mcursor, 16); + sprintf(s, "CursorPosition:(%d, %d)", mx, my); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 48, COL8_FFFFFF, (unsigned char *) s); + + io_out8(PIC0_IMR, 0xf9); /* PIC1?????????(11111001) */ + io_out8(PIC1_IMR, 0xef); /* ??????(11101111) */ + + for (;;) { io_hlt(); } } Modified: PhoeniOS/trunk/system/color.cpp =================================================================== --- PhoeniOS/trunk/system/color.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/color.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: color.cpp */ -/* Update: 2009/01/18 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS????? */ /* ???????? */ @@ -9,6 +9,7 @@ #include #include "phoenios.h" +#ifdef __cplusplus namespace System { namespace Graphic { unsigned char Color::RGB24To8(unsigned char r,unsigned char g,unsigned char b) { @@ -16,3 +17,4 @@ } }; }; +#endif Modified: PhoeniOS/trunk/system/color.h =================================================================== --- PhoeniOS/trunk/system/color.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/color.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,11 +1,12 @@ /* --------------------------------------------------------- */ /* File: color.h */ -/* Update: 2009/01/18 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS????? */ /* ??????????????? */ /* --------------------------------------------------------- */ +#ifdef __cplusplus namespace System { namespace Graphic { class Color { @@ -14,3 +15,4 @@ }; }; }; +#endif Modified: PhoeniOS/trunk/system/descriptor.cpp =================================================================== --- PhoeniOS/trunk/system/descriptor.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/descriptor.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: descriptor.cpp */ -/* Update: 2009/02/25 */ +/* Update: 2009/03/02 */ /* License: GNU General Public License v3 */ /* Description: GDT,IDT?????????? */ /* --------------------------------------------------------- */ @@ -11,29 +11,30 @@ namespace System { namespace Descriptor { void Descriptor::Initialize(void) { - struct SEGMENT_DESCRIPTOR *gdt = (struct SEGMENT_DESCRIPTOR *) 0x00270000; /* GDT 0x00270000 - 0x0027ffff */ - struct GATE_DESCRIPTOR *idt = (struct GATE_DESCRIPTOR *) 0x0026f800; /* IDT 0x0026f800 - 0x0026ffff */ + struct SEGMENT_DESCRIPTOR *gdt = (struct SEGMENT_DESCRIPTOR *) ADR_GDT; + struct GATE_DESCRIPTOR *idt = (struct GATE_DESCRIPTOR *) ADR_IDT; int i; /* GDT????*/ - for (i = 0; i < 8192; i++) { - Set_SegmentDescriptor(gdt + i, 0, 0, 0); /* ????????????l??? */ + for (i = 0; i <= LIMIT_GDT / 8; i++) { + Set_SegmentDescriptor(gdt + i, 0, 0, 0); } + Set_SegmentDescriptor(gdt + 1, 0xffffffff, 0x00000000, AR_DATA32_RW); + Set_SegmentDescriptor(gdt + 2, LIMIT_BOTPAK, ADR_BOTPAK, AR_CODE32_ER); + load_gdtr(LIMIT_GDT, ADR_GDT); - Set_SegmentDescriptor(gdt + 1, 0xffffffff, 0x00000000, AR_DATA32_RW); /* ???????????, ?????*/ - Set_SegmentDescriptor(gdt + 1, 0x0007ffff, 0x00280000, AR_CODE32_ER); /* ???????????, ????,ŽÀ?? */ - - load_gdtr(0xffff, 0x00270000); /* GDTR?GDT??? */ - /* IDT????*/ - for (i = 0; i < 256; i++) { - Set_GateDescriptor(idt + i, 0, 0, 0); /* ????????????l??? */ + for (i = 0; i <= LIMIT_IDT / 8; i++) { + Set_GateDescriptor(idt + i, 0, 0, 0); } + load_idtr(LIMIT_IDT, ADR_IDT); - load_idtr(0x7ff, 0x0026f800); /* IDTR?IDT??? */ + /* IDT??? */ + Set_GateDescriptor(idt + 0x21, (int) asm_inthandler21, 2 * 8, AR_INTGATE32); + Set_GateDescriptor(idt + 0x2c, (int) asm_inthandler2c, 2 * 8, AR_INTGATE32); return; - }; + } void Descriptor::Set_SegmentDescriptor(struct SEGMENT_DESCRIPTOR *sd, unsigned int limit, int base, int ar) { if (limit > 0xfffff) { @@ -59,6 +60,6 @@ gd->offset_high = (offset >> 16) & 0xffff; return; - }; + } }; }; Modified: PhoeniOS/trunk/system/descriptor.h =================================================================== --- PhoeniOS/trunk/system/descriptor.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/descriptor.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,25 +1,32 @@ /* --------------------------------------------------------- */ /* File: descriptor.h */ -/* Update: 2009/02/25 */ +/* Update: 2009/03/02 */ /* License: GNU General Public License v3 */ /* Description: GDT,IDT????????????? */ /* --------------------------------------------------------- */ +#define ADR_IDT 0x0026f800 +#define LIMIT_IDT 0x000007ff +#define ADR_GDT 0x00270000 +#define LIMIT_GDT 0x0000ffff +#define ADR_BOTPAK 0x00280000 +#define LIMIT_BOTPAK 0x0007ffff #define AR_DATA32_RW 0x4092 #define AR_CODE32_ER 0x409a +#define AR_INTGATE32 0x008e struct SEGMENT_DESCRIPTOR { short limit_low, base_low; char base_mid, access_right; char limit_high, base_high; }; - struct GATE_DESCRIPTOR { short offset_low, selector; char dw_count, access_right; short offset_high; }; +#ifdef __cplusplus namespace System { namespace Descriptor { class Descriptor { @@ -31,3 +38,4 @@ }; }; }; +#endif Modified: PhoeniOS/trunk/system/drawing.cpp =================================================================== --- PhoeniOS/trunk/system/drawing.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/drawing.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -26,7 +26,7 @@ return; } - void Drawing::Put_Font(char *vram, int xsize, int x, int y, char c, char *font) { + void Drawing::PutFont(char *vram, int xsize, int x, int y, char c, char *font) { int i; char *p, d; @@ -47,9 +47,9 @@ return; } - void Drawing::Put_Fonts(char *vram, int xsize, int x, int y, char c, unsigned char *s) { + void Drawing::PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s) { for (; *s != 0x00; s++) { - Put_Font(vram, xsize, x, y, c, hankaku + *s * 16); + PutFont(vram, xsize, x, y, c, hankaku + *s * 16); x += 8; } } Modified: PhoeniOS/trunk/system/drawing.h =================================================================== --- PhoeniOS/trunk/system/drawing.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/drawing.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,22 +1,28 @@ /* --------------------------------------------------------- */ /* File: drawing.cpp */ -/* Update: 2009/01/18 */ +/* Update: 2009/03/02 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???????? */ /* ???????????? */ /* --------------------------------------------------------- */ +#ifdef __cplusplus extern "C" { +#endif extern char hankaku[4096]; +#ifdef __cplusplus } +#endif +#ifdef __cplusplus namespace System { namespace Graphic { class Drawing { public: static void FillRectangle_8(char *vram, int xsize, unsigned char c, int x0, int y0, int x1, int y1); - static void Put_Font(char *vram, int xsize, int x, int y, char c, char *font); - static void Put_Fonts(char *vram, int xsize, int x, int y, char c, unsigned char *s); + static void PutFont(char *vram, int xsize, int x, int y, char c, char *font); + static void PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s); }; }; }; +#endif Deleted: PhoeniOS/trunk/system/graphic.cpp =================================================================== --- PhoeniOS/trunk/system/graphic.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/graphic.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,26 +0,0 @@ -/* --------------------------------------------------------- */ -/* File: graphic.cpp */ -/* Update: 2008/12/18 */ -/* License: GNU General Public License v3 */ -/* Description: PhoeniOS?????????? */ -/* ????????? */ -/* --------------------------------------------------------- */ - -#include -#include "phoenios.h" - -namespace System { -namespace Graphic { - void Background::Draw(void) { - - char *s = ""; - System::Information::BootInfo binfo; - - Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 0, 0, binfo.scrnx, binfo.scrny); - Drawing::Put_Fonts(binfo.vram, binfo.scrnx, 8, 8, Color::RGB24To8(255, 255, 255), (unsigned char *) "PhoeniOS"); - - sprintf(s, "BootInfo : scrnx=%d, scrny=%d", binfo.scrnx, binfo.scrny); - Drawing::Put_Fonts(binfo.vram, binfo.scrnx, 8, 32, Color::RGB24To8(255, 255, 255), (unsigned char *) s); - } -}; -}; Deleted: PhoeniOS/trunk/system/graphic.h =================================================================== --- PhoeniOS/trunk/system/graphic.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/graphic.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,35 +0,0 @@ -/* --------------------------------------------------------- */ -/* File: graphic.h */ -/* Update: 2008/12/17 */ -/* License: GNU General Public License v3 */ -/* Description: PhoeniOS?????????? */ -/* ???????????? */ -/* --------------------------------------------------------- */ - -/* ????????? */ -#define COL8_000000 0 -#define COL8_FF0000 1 -#define COL8_00FF00 2 -#define COL8_FFFF00 3 -#define COL8_0000FF 4 -#define COL8_FF00FF 5 -#define COL8_00FFFF 6 -#define COL8_FFFFFF 7 -#define COL8_C6C6C6 8 -#define COL8_840000 9 -#define COL8_008400 10 -#define COL8_848400 11 -#define COL8_000084 12 -#define COL8_840084 13 -#define COL8_008484 14 -#define COL8_848484 15 - -/* ??? */ -namespace System { -namespace Graphic { - class Background { - public: - static void Draw(void); - }; -}; -}; Added: PhoeniOS/trunk/system/int.cpp =================================================================== --- PhoeniOS/trunk/system/int.cpp (rev 0) +++ PhoeniOS/trunk/system/int.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,63 @@ +/* --------------------------------------------------------- */ +/* File: int.cpp */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +using namespace System::Graphic; +using namespace System::Information; + +namespace System { +namespace Interrupt { + void PIC::Initialize(void) { + io_out8(PIC0_IMR, 0xff); /* ?????????????? */ + io_out8(PIC1_IMR, 0xff); /* ?????????????? */ + + io_out8(PIC0_ICW1, 0x11); /* ????????? */ + io_out8(PIC0_ICW2, 0x20); /* IRQ0-7?, INT20-27???? */ + io_out8(PIC0_ICW3, 1 << 2); /* PIC1?IRQ2???? */ + io_out8(PIC0_ICW4, 0x01); /* ????????? */ + + io_out8(PIC1_ICW1, 0x11); /* ????????? */ + io_out8(PIC1_ICW2, 0x28); /* IRQ8-15?, INT28-2f???? */ + io_out8(PIC1_ICW3, 2); /* PIC1?IRQ2???? */ + io_out8(PIC1_ICW4, 0x01); /* ????????? */ + + io_out8(PIC0_IMR, 0xfb); /* 11111011 PIC1?????????????? */ + io_out8(PIC1_IMR, 0xff); /* 11111111 ?????????? */ + + return; + } + + /* PS/2???????????? */ + void Handlers::Handler21(int *esp) { + BootInfo binfo; + unsigned char data, s[4]; + + io_out8(PIC0_OCW2, 0x61); /* IRQ-01?????PIC??? */ + data = io_in8(PORT_KEYDAT); + + sprintf((char *) s, "%02X", data); + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 8, 72, 23, 87); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 72, Color::RGB24To8(255, 255, 255), s); + + return; + } + + /* PS/2?????????? */ + void Handlers::Handler2c(int *esp) { + BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 0, 0), 0, 0, 32 * 8 - 1, 15); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 0, 0, Color::RGB24To8(255, 255, 255), (unsigned char *) "INT 2C (IRQ-12) : PS/2 Mouse"); + + for (;;) { + io_hlt(); + } + } +}; +}; Added: PhoeniOS/trunk/system/int.h =================================================================== --- PhoeniOS/trunk/system/int.h (rev 0) +++ PhoeniOS/trunk/system/int.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,42 @@ +/* --------------------------------------------------------- */ +/* File: int.h */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define PIC0_IMR 0x0021 +#define PIC0_ICW1 0x0020 +#define PIC0_ICW2 0x0021 +#define PIC0_ICW3 0x0021 +#define PIC0_ICW4 0x0021 +#define PIC0_OCW1 0x0021 +#define PIC0_OCW2 0x0020 +#define PIC0_OCW3 0x0020 +#define PIC1_IMR 0x00a1 +#define PIC1_ICW1 0x00a0 +#define PIC1_ICW2 0x00a1 +#define PIC1_ICW3 0x00a1 +#define PIC1_ICW4 0x00a1 +#define PIC1_OCW1 0x00a1 +#define PIC1_OCW2 0x00a0 +#define PIC1_OCW3 0x00a0 +#define PORT_KEYDAT 0x0060 + +#ifdef __cplusplus +namespace System { +namespace Interrupt { + class PIC { + public: + static void Initialize(void); + }; + + class Handlers { + public: + static void Handler21(int *esp); + static void Handler2c(int *esp); + }; +}; +}; +#endif Modified: PhoeniOS/trunk/system/make.bat =================================================================== --- PhoeniOS/trunk/system/make.bat 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/make.bat 2009-03-03 10:01:14 UTC (rev 65) @@ -1 +1 @@ -..\..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file +..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file Added: PhoeniOS/trunk/system/mouse.cpp =================================================================== --- PhoeniOS/trunk/system/mouse.cpp (rev 0) +++ PhoeniOS/trunk/system/mouse.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,93 @@ +/* --------------------------------------------------------- */ +/* File: mouse.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +namespace System { +namespace Mouse { + void Cursor::Initialize(char *mouse, char bc) { + static char cursor[16][17] = { + //"*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OOOOOOOO*......", + "*OOOOO****......", + "*OO*OO*.........", + "*O*.*OO*........", + "**..*OO*........", + "....*OO*........", + ".....*OO*.......", + "......**........" + }; + /*static char cursor[16][17] = { + "*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OO*O****.......", + "*O**O*..........", + "**..*O*.........", + "*...*O*.........", + ".....*O*........", + ".....*O*........", + "......**........" + };*/ + int x, y; + + for (y = 0; y < 16; y++) { + for (x = 0; x < 16; x++) { + if (cursor[y][x] == '*') { + mouse[y * 16 + x] = COL8_000000; + } + if (cursor[y][x] == 'O') { + mouse[y * 16 + x] = COL8_FFFFFF; + } + if (cursor[y][x] == '.') { + mouse[y * 16 + x] = bc; + } + } + } + + return; + } + + void Cursor::PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize) { + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; + } +}; +}; + + +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize) +{ + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; +} Added: PhoeniOS/trunk/system/mouse.h =================================================================== --- PhoeniOS/trunk/system/mouse.h (rev 0) +++ PhoeniOS/trunk/system/mouse.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,29 @@ +/* --------------------------------------------------------- */ +/* File: mouse.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Mouse { + class Cursor { + public: + static void Initialize(char *cursor, char bc); + static void PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize); + }; +}; +}; +#endif + +#ifdef __cplusplus +extern "C" { +#endif +void init_mouse_cursor8(char *mouse, char bc); +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_dsc.h =================================================================== --- PhoeniOS/trunk/system/nask_dsc.h (rev 0) +++ PhoeniOS/trunk/system/nask_dsc.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_dsc.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?GDT,IDT???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void load_gdtr(int limit, int addr); + void load_idtr(int limit, int addr); +#ifdef __cplusplus +}; +#endif Modified: PhoeniOS/trunk/system/nask_dsc.nas =================================================================== --- PhoeniOS/trunk/system/nask_dsc.nas 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/nask_dsc.nas 2009-03-03 10:01:14 UTC (rev 65) @@ -1,8 +1,8 @@ ; --------------------------------------------------------- ; File: nask_dsc.nas -; Update: 2009/02/25 +; Update: 2009/03/01 ; License: GNU General Public License v3 -; Description: PhoeniOS?IO???NASK????? +; Description: PhoeniOS?GDT,IDT???NASK????? ; --------------------------------------------------------- [FORMAT "WCOFF"] @@ -14,14 +14,14 @@ [SECTION .text] -_load_gdtr: ; void load_gdtr(int limit, int addr); - MOV AX,[ESP+4] ; limit +_load_gdtr: ; void load_gdtr(int limit, int addr); + MOV AX,[ESP+4] ; limit MOV [ESP+6],AX LGDT [ESP+6] RET -_load_idtr: ; void load_idtr(int limit, int addr); - MOV AX,[ESP+4] ; limit +_load_idtr: ; void load_idtr(int limit, int addr); + MOV AX,[ESP+4] ; limit MOV [ESP+6],AX LIDT [ESP+6] RET Added: PhoeniOS/trunk/system/nask_int.h =================================================================== --- PhoeniOS/trunk/system/nask_int.h (rev 0) +++ PhoeniOS/trunk/system/nask_int.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void asm_inthandler21(void); + void asm_inthandler2c(void); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_int.nas =================================================================== --- PhoeniOS/trunk/system/nask_int.nas (rev 0) +++ PhoeniOS/trunk/system/nask_int.nas 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,49 @@ +; --------------------------------------------------------- +; File: nask_int.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS????????NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_int.nas"] + + GLOBAL _asm_inthandler21, _asm_inthandler2c + EXTERN __ZN6System9Interrupt8Handlers9Handler21EPi + EXTERN __ZN6System9Interrupt8Handlers9Handler2cEPi + +[SECTION .text] + +_asm_inthandler21: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler21EPi + POP EAX + POPAD + POP DS + POP ES + IRETD + +_asm_inthandler2c: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler2cEPi + POP EAX + POPAD + POP DS + POP ES + IRETD Added: PhoeniOS/trunk/system/nask_io.h =================================================================== --- PhoeniOS/trunk/system/nask_io.h (rev 0) +++ PhoeniOS/trunk/system/nask_io.h 2009-03-03 10:01:14 UTC (rev 65) @@ -0,0 +1,20 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?IO???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void io_hlt(void); + void io_cli(void); + void io_sti(void); + int io_in8(int port); + void io_out8(int port, int data); + int io_load_eflags(void); + void io_store_eflags(int eflags); +#ifdef __cplusplus +}; +#endif Modified: PhoeniOS/trunk/system/nask_io.nas =================================================================== --- PhoeniOS/trunk/system/nask_io.nas 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/nask_io.nas 2009-03-03 10:01:14 UTC (rev 65) @@ -1,6 +1,6 @@ ; --------------------------------------------------------- ; File: nask_io.nas -; Update: 2009/02/25 +; Update: 2009/03/01 ; License: GNU General Public License v3 ; Description: PhoeniOS?IO???NASK????? ; --------------------------------------------------------- @@ -11,10 +11,9 @@ [FILE "nask_io.nas"] GLOBAL _io_hlt, _io_cli, _io_sti, _io_stihlt - GLOBAL _io_in8, _io_in16, io_in32 + GLOBAL _io_in8, _io_in16, _io_in32 GLOBAL _io_out8, _io_out16, _io_out32 GLOBAL _io_load_eflags, _io_store_eflags - GLOBAL _io_load_gdtr, _io_load_idtr [SECTION .text] @@ -35,19 +34,19 @@ HLT RET -_io_in8: ; void io_in8(int port); +_io_in8: ; int io_in8(int port); MOV EDX,[ESP+4] ; port MOV EAX,0 IN AL,DX RET -_io_in16: ; void io_in16(int port); +_io_in16: ; int io_in16(int port); MOV EDX,[ESP+4] ; port MOV EAX,0 IN AX,DX RET -_io_in32: ; void io_in32(int port); +_io_in32: ; int io_in32(int port); MOV EDX,[ESP+4] ; port IN EAX,DX RET @@ -60,7 +59,7 @@ _io_out16: ; void io_out16(int port, int data); MOV EDX,[ESP+4] ; port - MOV AX,[ESP+8] ; data + MOV EAX,[ESP+8] ; data OUT DX,AX RET @@ -70,7 +69,7 @@ OUT DX,EAX RET -_io_load_eflags: ; void io_load_eflags(void); +_io_load_eflags: ; int io_load_eflags(void); PUSHFD POP EAX RET @@ -80,15 +79,3 @@ PUSH EAX POPFD RET - -_load_gdtr: ; void load_gdtr(int limit, int addr); - MOV AX,[ESP+4] ; limit - MOV [ESP+6],AX - LGDT [ESP+6] - RET - -_load_idtr: ; void load_idtr(int limit, int addr); - MOV AX,[ESP+4] ; limit - MOV [ESP+6],AX - LIDT [ESP+6] - RET Deleted: PhoeniOS/trunk/system/naskfunc.h =================================================================== --- PhoeniOS/trunk/system/naskfunc.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/naskfunc.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,28 +0,0 @@ -/* --------------------------------------------------------- */ -/* File: naskfunc.h */ -/* Update: 2009/02/25 */ -/* License: GNU General Public License v3 */ -/* Description: nask???????? */ -/* --------------------------------------------------------- */ - -/* nask_io.nas */ -extern "C" { - void io_hlt(void); - void io_cli(void); - void io_sti(void); - void io_stihlt(void); - int io_in8(int port); - int io_in16(int port); - int io_in32(int port); - void io_out8(int port, int data); - void io_out16(int port, int data); - void io_out32(int port, int data); - int io_load_eflags(void); - void io_store_eflags(int eflags); -}; - -/* nask_dsc.nas */ -extern "C" { - void load_gdtr(int limit, int addr); - void load_idtr(int limit, int addr); -}; Modified: PhoeniOS/trunk/system/palette.cpp =================================================================== --- PhoeniOS/trunk/system/palette.cpp 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/palette.cpp 2009-03-03 10:01:14 UTC (rev 65) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: palette.cpp */ -/* Update: 2009/01/18 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???????? */ /* ????????? */ Modified: PhoeniOS/trunk/system/palette.h =================================================================== --- PhoeniOS/trunk/system/palette.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/palette.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,11 +1,30 @@ /* --------------------------------------------------------- */ /* File: palette.h */ -/* Update: 2009/01/18 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???????? */ /* ???????????? */ /* --------------------------------------------------------- */ +/* ????????? */ +#define COL8_000000 0 +#define COL8_FF0000 1 +#define COL8_00FF00 2 +#define COL8_FFFF00 3 +#define COL8_0000FF 4 +#define COL8_FF00FF 5 +#define COL8_00FFFF 6 +#define COL8_FFFFFF 7 +#define COL8_C6C6C6 8 +#define COL8_840000 9 +#define COL8_008400 10 +#define COL8_848400 11 +#define COL8_000084 12 +#define COL8_840084 13 +#define COL8_008484 14 +#define COL8_848484 15 + +#ifdef __cplusplus namespace System { namespace Graphic { class Palette { @@ -15,3 +34,4 @@ }; }; }; +#endif Modified: PhoeniOS/trunk/system/phoenios.h =================================================================== --- PhoeniOS/trunk/system/phoenios.h 2009-02-25 08:53:56 UTC (rev 64) +++ PhoeniOS/trunk/system/phoenios.h 2009-03-03 10:01:14 UTC (rev 65) @@ -1,17 +1,21 @@ /* --------------------------------------------------------- */ /* File: phoenios.h */ -/* Update: 2008/12/09 */ +/* Update: 2009/03/01 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???????????? */ /* --------------------------------------------------------- */ /* C,C++ */ +#include "background.h" #include "bootinfo.h" #include "color.h" #include "descriptor.h" #include "drawing.h" -#include "graphic.h" +#include "int.h" +#include "mouse.h" #include "palette.h" /* NASK */ -#include "naskfunc.h" +#include "nask_dsc.h" +#include "nask_int.h" +#include "nask_io.h" Modified: PhoeniOS/trunk/system/phoenios.sys =================================================================== (Binary files differ) From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:28:08 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:28:08 +0900 Subject: [PhoeniOS-SVN] [Commit] [66] Message-ID: <1236922088.019072.5159.nullmailer@users.sourceforge.jp> Revision: 66 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=66 Author: litesystems Date: 2009-03-13 14:28:07 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Removed Paths: ------------- PhoeniOS/trunk/ -------------- next part -------------- From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:31:32 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:31:32 +0900 Subject: [PhoeniOS-SVN] [Commit] [68] Message-ID: <1236922292.914724.8479.nullmailer@users.sourceforge.jp> Revision: 68 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=68 Author: litesystems Date: 2009-03-13 14:31:32 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Removed Paths: ------------- PhoeniOS/trunk/ -------------- next part -------------- From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:36:21 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:36:21 +0900 Subject: [PhoeniOS-SVN] [Commit] [70] Tagging the 0.2.1 release. Message-ID: <1236922581.797946.17117.nullmailer@users.sourceforge.jp> Revision: 70 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=70 Author: litesystems Date: 2009-03-13 14:36:21 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Tagging the 0.2.1 release. Added Paths: ----------- PhoeniOS/tags/0.2.1/ -------------- next part -------------- From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:40:47 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:40:47 +0900 Subject: [PhoeniOS-SVN] [Commit] [71] Make dir of release 0.2.1 Message-ID: <1236922847.859535.22587.nullmailer@users.sourceforge.jp> Revision: 71 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=71 Author: litesystems Date: 2009-03-13 14:40:47 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Make dir of release 0.2.1 Added Paths: ----------- PhoeniOS/release/0.2.1/ -------------- next part -------------- From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:41:30 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:41:30 +0900 Subject: [PhoeniOS-SVN] [Commit] [72] Import release of 0.2.1 Message-ID: <1236922890.942207.23227.nullmailer@users.sourceforge.jp> Revision: 72 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=72 Author: litesystems Date: 2009-03-13 14:41:30 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Import release of 0.2.1 Added Paths: ----------- PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.lzh PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.tar.gz PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.zip -------------- next part -------------- Added: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.lzh =================================================================== (Binary files differ) Property changes on: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.lzh ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Added: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.tar.gz =================================================================== (Binary files differ) Property changes on: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.tar.gz ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Added: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.zip =================================================================== (Binary files differ) Property changes on: PhoeniOS/release/0.2.1/PhoeniOS_0_2_1.zip ___________________________________________________________________ Added: svn:mime-type + application/octet-stream From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:28:37 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:28:37 +0900 Subject: [PhoeniOS-SVN] [Commit] [67] Message-ID: <1236922117.005384.5508.nullmailer@users.sourceforge.jp> Revision: 67 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=67 Author: litesystems Date: 2009-03-13 14:28:36 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Added Paths: ----------- PhoeniOS/trunk/ PhoeniOS/trunk/!cons_9x.bat PhoeniOS/trunk/!cons_nt.bat PhoeniOS/trunk/GPL.html PhoeniOS/trunk/GPL.txt PhoeniOS/trunk/Makefile PhoeniOS/trunk/build.txt PhoeniOS/trunk/make.bat PhoeniOS/trunk/phoenios.rul PhoeniOS/trunk/readme.txt PhoeniOS/trunk/release.txt PhoeniOS/trunk/system/ PhoeniOS/trunk/system/!cons_9x.bat PhoeniOS/trunk/system/!cons_nt.bat PhoeniOS/trunk/system/Makefile PhoeniOS/trunk/system/asmhead.nas PhoeniOS/trunk/system/background.cpp PhoeniOS/trunk/system/background.h PhoeniOS/trunk/system/bootinfo.cpp PhoeniOS/trunk/system/bootinfo.h PhoeniOS/trunk/system/color.cpp PhoeniOS/trunk/system/color.h PhoeniOS/trunk/system/descriptor.cpp PhoeniOS/trunk/system/descriptor.h PhoeniOS/trunk/system/drawing.cpp PhoeniOS/trunk/system/drawing.h PhoeniOS/trunk/system/fifo.cpp PhoeniOS/trunk/system/fifo.h PhoeniOS/trunk/system/hankaku.txt PhoeniOS/trunk/system/int.cpp PhoeniOS/trunk/system/int.h PhoeniOS/trunk/system/ipl.bin PhoeniOS/trunk/system/ipl.nas PhoeniOS/trunk/system/main.cpp PhoeniOS/trunk/system/make.bat PhoeniOS/trunk/system/mouse.cpp PhoeniOS/trunk/system/mouse.h PhoeniOS/trunk/system/nask_dsc.h PhoeniOS/trunk/system/nask_dsc.nas PhoeniOS/trunk/system/nask_int.h PhoeniOS/trunk/system/nask_int.nas PhoeniOS/trunk/system/nask_io.h PhoeniOS/trunk/system/nask_io.nas PhoeniOS/trunk/system/palette.cpp PhoeniOS/trunk/system/palette.h PhoeniOS/trunk/system/phoenios.h PhoeniOS/trunk/system/phoenios.sys -------------- next part -------------- Added: PhoeniOS/trunk/!cons_9x.bat =================================================================== --- PhoeniOS/trunk/!cons_9x.bat (rev 0) +++ PhoeniOS/trunk/!cons_9x.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +command \ No newline at end of file Added: PhoeniOS/trunk/!cons_nt.bat =================================================================== --- PhoeniOS/trunk/!cons_nt.bat (rev 0) +++ PhoeniOS/trunk/!cons_nt.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +cmd.exe \ No newline at end of file Added: PhoeniOS/trunk/GPL.html =================================================================== --- PhoeniOS/trunk/GPL.html (rev 0) +++ PhoeniOS/trunk/GPL.html 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,692 @@ + + + + + + GNU General Public License - GNU Project - Free Software Foundation (FSF) + +

GNU GENERAL PUBLIC LICENSE

+

Version 3, 29 June 2007

+ +

Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>

+ Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed.

+ +

Preamble

+ +

The GNU General Public License is a free, copyleft license for +software and other kinds of works.

+ +

The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too.

+ +

When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things.

+ +

To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others.

+ +

For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights.

+ +

Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it.

+ +

For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions.

+ +

Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users.

+ +

Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free.

+ +

The precise terms and conditions for copying, distribution and +modification follow.

+ +

TERMS AND CONDITIONS

+ +

0. Definitions.

+ +

??his License??refers to version 3 of the GNU General Public License.

+ +

??opyright??also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks.

+ +

??he Program??refers to any copyrightable work licensed under this +License. Each licensee is addressed as ??ou?? ??icensees??and +??ecipients??may be individuals or organizations.

+ +

To ??odify??a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a ??odified version??of the +earlier work or a work ??ased on??the earlier work.

+ +

A ??overed work??means either the unmodified Program or a work based +on the Program.

+ +

To ??ropagate??a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well.

+ +

To ??onvey??a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying.

+ +

An interactive user interface displays ??ppropriate Legal Notices??+to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion.

+ +

1. Source Code.

+ +

The ??ource code??for a work means the preferred form of the work +for making modifications to it. ??bject code??means any non-source +form of a work.

+ +

A ??tandard Interface??means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language.

+ +

The ??ystem Libraries??of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +??ajor Component?? in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it.

+ +

The ??orresponding Source??for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work.

+ +

The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source.

+ +

The Corresponding Source for a work in source code form is that +same work.

+ +

2. Basic Permissions.

+ +

All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law.

+ +

You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you.

+ +

Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary.

+ +

3. Protecting Users' Legal Rights From Anti-Circumvention Law.

+ +

No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures.

+ +

When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures.

+ +

4. Conveying Verbatim Copies.

+ +

You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program.

+ +

You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee.

+ +

5. Conveying Modified Source Versions.

+ +

You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions:

+ +
    +
  • a) The work must carry prominent notices stating that you modified + it, and giving a relevant date.
  • + +
  • b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + ??eep intact all notices??
  • + +
  • c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it.
  • + +
  • d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so.
  • +
+ +

A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +??ggregate??if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate.

+ +

6. Conveying Non-Source Forms.

+ +

You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways:

+ +
    +
  • a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange.
  • + +
  • b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge.
  • + +
  • c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b.
  • + +
  • d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements.
  • + +
  • e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d.
  • +
+ +

A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work.

+ +

A ??ser Product??is either (1) a ??onsumer product?? which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, ??ormally used??refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product.

+ +

??nstallation Information??for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made.

+ +

If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM).

+ +

The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network.

+ +

Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying.

+ +

7. Additional Terms.

+ +

??dditional permissions??are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions.

+ +

When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission.

+ +

Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms:

+ +
    +
  • a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or
  • + +
  • b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or
  • + +
  • c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or
  • + +
  • d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or
  • + +
  • e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or
  • + +
  • f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors.
  • +
+ +

All other non-permissive additional terms are considered ??urther +restrictions??within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying.

+ +

If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms.

+ +

Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way.

+ +

8. Termination.

+ +

You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11).

+ +

However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation.

+ +

Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice.

+ +

Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10.

+ +

9. Acceptance Not Required for Having Copies.

+ +

You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so.

+ +

10. Automatic Licensing of Downstream Recipients.

+ +

Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License.

+ +

An ??ntity transaction??is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts.

+ +

You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it.

+ +

11. Patents.

+ +

A ??ontributor??is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's ??ontributor version??

+ +

A contributor's ??ssential patent claims??are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, ??ontrol??includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License.

+ +

Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version.

+ +

In the following three paragraphs, a ??atent license??is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To ??rant??such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party.

+ +

If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. ??nowingly relying??means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid.

+ +

If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it.

+ +

A patent license is ??iscriminatory??if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007.

+ +

Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law.

+ +

12. No Surrender of Others' Freedom.

+ +

If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program.

+ +

13. Use with the GNU Affero General Public License.

+ +

Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such.

+ +

14. Revised Versions of this License.

+ +

The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns.

+ +

Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License ??r any later version??applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation.

+ +

If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program.

+ +

Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version.

+ +

15. Disclaimer of Warranty.

+ +

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM ??S IS??WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

+ +

16. Limitation of Liability.

+ +

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES.

+ +

17. Interpretation of Sections 15 and 16.

+ +

If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee.

+ +

END OF TERMS AND CONDITIONS

+ +

How to Apply These Terms to Your New Programs

+ +

If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms.

+ +

To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the ??opyright??line and a pointer to where the full notice is found.

+ +
    <one line to give the program's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This program is free software: you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation, either version 3 of the License, or
+    (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+ +

Also add information on how to contact you by electronic and paper mail.

+ +

If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode:

+ +
    <program>  Copyright (C) <year>  <name of author>
+    This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+    This is free software, and you are welcome to redistribute it
+    under certain conditions; type `show c' for details.
+
+ +

The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an ??bout box??

+ +

You should also get your employer (if you work as a programmer) or school, +if any, to sign a ??opyright disclaimer??for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +<http://www.gnu.org/licenses/>.

+ +

The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +<http://www.gnu.org/philosophy/why-not-lgpl.html>.

+ + + \ No newline at end of file Added: PhoeniOS/trunk/GPL.txt =================================================================== --- PhoeniOS/trunk/GPL.txt (rev 0) +++ PhoeniOS/trunk/GPL.txt 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. Added: PhoeniOS/trunk/Makefile =================================================================== --- PhoeniOS/trunk/Makefile (rev 0) +++ PhoeniOS/trunk/Makefile 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,67 @@ +TOOLPATH = ../z_tools/ + +BLDMGR = $(TOOLPATH)BuildManager.exe +MAKE = $(TOOLPATH)make.exe -r +NASK = $(TOOLPATH)nask.exe +EDIMG = $(TOOLPATH)edimg.exe +IMGTOL = $(TOOLPATH)imgtol.com +COPY = copy +DEL = del + +# ??????? + +default : + $(MAKE) phoenios.img + +# ???????? + +phoenios.img : system/ipl.bin system/phoenios.sys Makefile + $(EDIMG) imgin:../z_tools/fdimg0at.tek \ + wbinimg src:system/ipl.bin len:512 from:0 to:0 \ + copy from:system/phoenios.sys to:@: \ + imgout:phoenios.img + $(BLDMGR) build.txt + +# ???? + +run : + $(MAKE) phoenios.img + $(COPY) phoenios.img ..\z_tools\qemu\fdimage0.bin + $(MAKE) -C ../z_tools/qemu + +install : + $(MAKE) phoenios.img + $(IMGTOL) w a: phoenios.img + +full : + $(MAKE) -C system + +run_full : + $(MAKE) full + $(COPY) phoenios.img ..\z_tools\qemu\fdimage0.bin + $(MAKE) -C ../z_tools/qemu + +install_full : + $(MAKE) full + $(IMGTOL) w a: phoenios.img + +run_os : + $(MAKE) -C system + $(MAKE) run + +clean : + +src_only : + $(MAKE) clean + -$(DEL) phoenios.img + +clean_full : + $(MAKE) -C system clean + +src_only_full : + $(MAKE) -C system src_only + +refresh : + $(MAKE) full + $(MAKE) clean_full + -$(DEL) phoenios.img Added: PhoeniOS/trunk/build.txt =================================================================== --- PhoeniOS/trunk/build.txt (rev 0) +++ PhoeniOS/trunk/build.txt 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +256 \ No newline at end of file Added: PhoeniOS/trunk/make.bat =================================================================== --- PhoeniOS/trunk/make.bat (rev 0) +++ PhoeniOS/trunk/make.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file Added: PhoeniOS/trunk/phoenios.rul =================================================================== --- PhoeniOS/trunk/phoenios.rul (rev 0) +++ PhoeniOS/trunk/phoenios.rul 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,19 @@ +format: + /* ?????????????????*/ + code(align:1, logic:0x24, file:0x24); + data(align:4, logic:stack_end, file:code_end); + +file: + /* ????????????????????????+ .ojb?????.lib??????? */ + /* ??????????????????????B */ + /* ?? c:/osask/gg00libc.lib; */ + ../../z_tools/phoenios/phoenios.lib; + ../../z_tools/haribote/golibc.lib; + +label: + /* ???????????????????? */ + /* ???????????????????????? */ + _Startup; + + /* ?L3???????????????????? */ Added: PhoeniOS/trunk/readme.txt =================================================================== --- PhoeniOS/trunk/readme.txt (rev 0) +++ PhoeniOS/trunk/readme.txt 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,11 @@ +------------------------------------------- + Name: PhoeniOS + Version: 0.2.1 (Build 256) + Publisher: Lite Systems + License: GNU General Public License v3 +------------------------------------------- + +1,????? + +PhoeniOS??????? GNU General Public License v3 ??? +?????????GPL.txt???GPL.html???????? Added: PhoeniOS/trunk/release.txt =================================================================== --- PhoeniOS/trunk/release.txt (rev 0) +++ PhoeniOS/trunk/release.txt 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,30 @@ +-------------------------- + PhoeniOS Release Notes +-------------------------- +2009/03/13 Version:0.2.1 (Build 256) +- FIFO?????ŽÀ????? + +2009/02/25 Version:0.2.0 (Build 23) +- GDT,IDT?ŽÀ????? + +2008/12/19 Version:0.1.2 +- ????????????ŽÀ????? + +2008/12/16 Version:0.1.1 +- 16?????????????6??216??????ŽÀ????? + +2008/11/29 Version:0.1.0 +- 32bit??????????????? +- ?????????????+- C,C++??????????? + +2008/11/14 Version:0.0.2 +- IPL??????????+ +2008/11/13 Version:0.0.1 +- IPL?Version:1.0.1????????? + IPL????????????????????????ަ??? + +2008/11/08 Version:0.0.0 +- ??????J +- IPL Version:1.0.0 ??? Added: PhoeniOS/trunk/system/!cons_9x.bat =================================================================== --- PhoeniOS/trunk/system/!cons_9x.bat (rev 0) +++ PhoeniOS/trunk/system/!cons_9x.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +command \ No newline at end of file Added: PhoeniOS/trunk/system/!cons_nt.bat =================================================================== --- PhoeniOS/trunk/system/!cons_nt.bat (rev 0) +++ PhoeniOS/trunk/system/!cons_nt.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +cmd.exe \ No newline at end of file Added: PhoeniOS/trunk/system/Makefile =================================================================== --- PhoeniOS/trunk/system/Makefile (rev 0) +++ PhoeniOS/trunk/system/Makefile 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,77 @@ +OBJS_BOOTPACK = main.obj background.obj bootinfo.obj color.obj descriptor.obj drawing.obj fifo.obj int.obj palette.obj mouse.obj \ + hankaku.obj \ + nask_dsc.obj nask_int.obj nask_io.obj + +TOOLPATH = ../../z_tools/ +INCPATH = ../../z_tools/haribote/ + +MAKE = $(TOOLPATH)make.exe -r +NASK = $(TOOLPATH)nask.exe +CPP = $(TOOLPATH)c++.exe -I../../z_tools/haribote -Os -Wall -nostdlib -fno-builtin -fno-exceptions -fno-rtti -B$(TOOLPATH) -c +CC1 = $(TOOLPATH)cc1.exe -I$(INCPATH) -Os -Wall -quiet +GAS2NASK = $(TOOLPATH)gas2nask.exe -a +OBJ2BIM = $(TOOLPATH)obj2bim.exe +MAKEFONT = $(TOOLPATH)makefont.exe +BIN2OBJ = $(TOOLPATH)bin2obj.exe +BIM2HRB = $(TOOLPATH)bim2hrb.exe +RULEFILE = ../phoenios.rul +DEL = del + +# ??????? + +default : + $(MAKE) ipl.bin + $(MAKE) phoenios.sys + +# ???????? + +ipl.bin : ipl.nas Makefile + $(NASK) ipl.nas ipl.bin ipl.lst + +asmhead.bin : asmhead.nas Makefile + $(NASK) asmhead.nas asmhead.bin asmhead.lst + +hankaku.bin : hankaku.txt Makefile + $(MAKEFONT) hankaku.txt hankaku.bin + +hankaku.obj : hankaku.bin Makefile + $(BIN2OBJ) hankaku.bin hankaku.obj _hankaku + +phoenios.bim : $(OBJS_BOOTPACK) Makefile + $(OBJ2BIM) @$(RULEFILE) out:phoenios.bim stack:3136k map:bootpack.map $(OBJS_BOOTPACK) + +phoenios.hrb : phoenios.bim Makefile + $(BIM2HRB) phoenios.bim phoenios.hrb 0 + +phoenios.sys : asmhead.bin phoenios.hrb Makefile + copy /B asmhead.bin+phoenios.hrb phoenios.sys + +# ???? + +%.obj : %.cpp Makefile + $(CPP) -o $*.obj $*.cpp + +%.gas : %.c Makefile + $(CC1) -o $*.gas $*.c + +%.nas : %.gas Makefile + $(GAS2NASK) $*.gas $*.nas + +%.obj : %.nas Makefile + $(NASK) $*.nas $*.obj $*.lst + +# ???? + +clean : + -$(DEL) asmhead.bin + -$(DEL) hankaku.bin + -$(DEL) *.lst + -$(DEL) *.obj + -$(DEL) *.map + -$(DEL) *.bim + -$(DEL) *.hrb + +src_only : + $(MAKE) clean + -$(DEL) ipl.bin + -$(DEL) phoenios.sys Added: PhoeniOS/trunk/system/asmhead.nas =================================================================== --- PhoeniOS/trunk/system/asmhead.nas (rev 0) +++ PhoeniOS/trunk/system/asmhead.nas 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,201 @@ +; --------------------------------------------------------- +; File: asmhead.nas +; Update: 2009/03/13 +; License: GNU General Public License v3 +; Description: PhoeniOS???????????????+; --------------------------------------------------------- + +[INSTRSET "i486p"] + +KERNEL EQU 0x00280000 ; Kernel????? +DSKCAC EQU 0x00100000 ; ????????????+DSKCAC0 EQU 0x00008000 ; ????????????i??????? + +; ??????? +; 0x100 : 640 x 400 x 8bit +; 0x101 : 640 x 480 x 8bit +; 0x103 : 800 x 600 x 8bit +; 0x105 : 1024 x 768 x 8bit +; 0x107 : 1280 x 1024 x 8bit + +VBEMODE EQU 0x103 ; VBE??? + +; BOOTINFO +CYLS EQU 0x1000 ; ?????????? +LEDS EQU 0x1001 ; ????????+VMODE EQU 0x1002 ; ?? +SCRNX EQU 0x1004 ; ????X +SCRNY EQU 0x1006 ; ????Y +VRAM EQU 0x1008 ; ??????????????? + + ORG 0xc200 + +; VBE?????+ + MOV AX,0x9000 + MOV ES,AX + MOV DI,0 + MOV AX,0x4f00 + INT 0x10 + CMP AX,0x004f + JNE scrn320 + +; VBE?????????? + + MOV AX,[ES:DI+4] + CMP AX,0x0200 + JB scrn320 + +; ??????????+ + MOV CX,VBEMODE + MOV AX,0x4f01 + INT 0x10 + CMP AX,0x004f + JNE scrn320 + +; ????????m? + + CMP BYTE [ES:DI+0x19],8 + JNE scrn320 + CMP BYTE [ES:DI+0x1b],4 + JNE scrn320 + MOV AX,[ES:DI+0x00] + AND AX,0x0080 + JZ scrn320 + +; ?????????? + + MOV BX,VBEMODE+0x4000 + MOV AX,0x4f02 + INT 0x10 + MOV BYTE [VMODE],8 ; BOOTINFO - ?? + MOV AX,[ES:DI+0x12] + MOV [SCRNX],AX ; BOOTINFO - ????X + MOV AX,[ES:DI+0x14] + MOV [SCRNY],AX ; BOOTINFO - ????Y + MOV EAX,[ES:DI+0x28] + MOV [VRAM],EAX ; BOOTINFO - ??????????????? + JMP keystatus + +scrn320: + MOV AL,0x13 + MOV AH,0x00 + INT 0x10 + MOV BYTE [VMODE],8 + MOV WORD [SCRNX],320 + MOV WORD [SCRNY],200 + MOV DWORD [VRAM],0x000a0000 + +keystatus: + MOV AH,0x02 + INT 0x16 + MOV [LEDS],AL ; BOOTINFO - ????????+ +; PIC????????????????? + + MOV AL,0xff + OUT 0x21,AL + NOP + OUT 0xa1,AL + + CLI + +; A20GATE????? + + CALL waitkbdout + MOV AL,0xd1 + OUT 0x64,AL + CALL waitkbdout + MOV AL,0xdf + OUT 0x60,AL + CALL waitkbdout + +; ??????????? + + LGDT [GDTR0] ; ??GDT????? + MOV EAX,CR0 + AND EAX,0x7fffffff ; ???????????,bit31?0??? + OR EAX,0x00000001 ; ??????????????,bit0?1??? + MOV CR0,EAX + JMP pipelineflush + +pipelineflush: + MOV AX,1*8 ; ?????\?????32bit + MOV DS,AX + MOV ES,AX + MOV FS,AX + MOV GS,AX + MOV SS,AX + +; Kernel??? + + MOV ESI,kernel ; ??? + MOV EDI,KERNEL ; ??? + MOV ECX,512*1024/4 + CALL memcpy + +; ??????????? +; ?????? + + MOV ESI,0x7c00 ; ??? + MOV EDI,DSKCAC ; ??? + MOV ECX,512/4 + CALL memcpy + +; ???? + + MOV ESI,DSKCAC0+512 ; ??? + MOV EDI,DSKCAC+512 ; ??? + MOV ECX,0 + MOV CL,BYTE [CYLS] + IMUL ECX,512*18*2/4 ; ???????????/4??? + SUB ECX,512/4 + CALL memcpy + +; Kernel??? + + MOV EBX,KERNEL + MOV ECX,[EBX+16] + ADD ECX,3 + SHR ECX,2 + JZ skip + MOV ESI,[EBX+20] ; ??? + ADD ESI,EBX + MOV EDI,[EBX+12] ; ??? + CALL memcpy +skip: + MOV ESP,[EBX+12] + JMP DWORD 2*8:0x0000001b + +waitkbdout: + IN AL,0x64 + AND AL,0x02 + JNZ waitkbdout + RET + +memcpy: + MOV EAX,[ESI] + ADD ESI,4 + MOV [EDI],EAX + ADD EDI,4 + SUB ECX,1 + JNZ memcpy + RET + + ALIGNB 16 + +GDT0: + RESB 8 + DW 0xffff,0x0000,0x9200,0x00cf ; ?????\?????32bit + DW 0xffff,0x0000,0x9a28,0x0047 ; ŽÀ????????32bit (kernel?) + + DW 0 + +GDTR0: + DW 8*3-1 + DD GDT0 + + ALIGNB 16 + +kernel: Added: PhoeniOS/trunk/system/background.cpp =================================================================== --- PhoeniOS/trunk/system/background.cpp (rev 0) +++ PhoeniOS/trunk/system/background.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,22 @@ +/* --------------------------------------------------------- */ +/* File: background.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Graphic { + void Background::Draw(void) { + System::Information::BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 0, 0, binfo.scrnx, binfo.scrny); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 24, Color::RGB24To8(255, 255, 255), (unsigned char *) "PhoeniOS"); + } +}; +}; +#endif Added: PhoeniOS/trunk/system/background.h =================================================================== --- PhoeniOS/trunk/system/background.h (rev 0) +++ PhoeniOS/trunk/system/background.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,18 @@ +/* --------------------------------------------------------- */ +/* File: background.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Background { + public: + static void Draw(void); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/bootinfo.cpp =================================================================== --- PhoeniOS/trunk/system/bootinfo.cpp (rev 0) +++ PhoeniOS/trunk/system/bootinfo.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,26 @@ +/* --------------------------------------------------------- */ +/* File: bootinfo.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: BootInfo?????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Information { + BootInfo::BootInfo(void) { + cyls = *((char *) (ADR_BOOTINFO + 0x00000000)); + leds = *((char *) (ADR_BOOTINFO + 0x00000001)); + vmode = *((char *) (ADR_BOOTINFO + 0x00000002)); + reserve = *((char *) (ADR_BOOTINFO + 0x00000003)); + scrnx = *((short *)(ADR_BOOTINFO + 0x00000004)); + scrny = *((short *)(ADR_BOOTINFO + 0x00000006)); + vram = (char *) *((int *)(ADR_BOOTINFO + 0x00000008)); + + return; + } +}; +}; +#endif Added: PhoeniOS/trunk/system/bootinfo.h =================================================================== --- PhoeniOS/trunk/system/bootinfo.h (rev 0) +++ PhoeniOS/trunk/system/bootinfo.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,26 @@ +/* --------------------------------------------------------- */ +/* File: bootinfo.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: BootInfo????? */ +/* --------------------------------------------------------- */ + +#define ADR_BOOTINFO 0x00001000 + +#ifdef __cplusplus +namespace System { +namespace Information { + class BootInfo { + public: + BootInfo(void); + char cyls; + char leds; + char vmode; + char reserve; + short scrnx; + short scrny; + char *vram; + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/color.cpp =================================================================== --- PhoeniOS/trunk/system/color.cpp (rev 0) +++ PhoeniOS/trunk/system/color.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,20 @@ +/* --------------------------------------------------------- */ +/* File: color.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????? */ +/* ???????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Graphic { + unsigned char Color::RGB24To8(unsigned char r,unsigned char g,unsigned char b) { + return ((r / 43) * 36) + ((g / 43) * 6) + (b / 43) + 16; + } +}; +}; +#endif Added: PhoeniOS/trunk/system/color.h =================================================================== --- PhoeniOS/trunk/system/color.h (rev 0) +++ PhoeniOS/trunk/system/color.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,18 @@ +/* --------------------------------------------------------- */ +/* File: color.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????? */ +/* ??????????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Color { + public: + static unsigned char RGB24To8(unsigned char r,unsigned char g,unsigned char b); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/descriptor.cpp =================================================================== --- PhoeniOS/trunk/system/descriptor.cpp (rev 0) +++ PhoeniOS/trunk/system/descriptor.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,65 @@ +/* --------------------------------------------------------- */ +/* File: descriptor.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: GDT,IDT?????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Descriptor { + void Descriptor::Initialize(void) { + struct SEGMENT_DESCRIPTOR *gdt = (struct SEGMENT_DESCRIPTOR *) ADR_GDT; + struct GATE_DESCRIPTOR *idt = (struct GATE_DESCRIPTOR *) ADR_IDT; + int i; + + /* GDT????*/ + for (i = 0; i <= LIMIT_GDT / 8; i++) { + Set_SegmentDescriptor(gdt + i, 0, 0, 0); + } + Set_SegmentDescriptor(gdt + 1, 0xffffffff, 0x00000000, AR_DATA32_RW); + Set_SegmentDescriptor(gdt + 2, LIMIT_KERNEL, ADR_KERNEL, AR_CODE32_ER); + load_gdtr(LIMIT_GDT, ADR_GDT); + + /* IDT????*/ + for (i = 0; i <= LIMIT_IDT / 8; i++) { + Set_GateDescriptor(idt + i, 0, 0, 0); + } + load_idtr(LIMIT_IDT, ADR_IDT); + + /* IDT??? */ + Set_GateDescriptor(idt + 0x21, (int) asm_inthandler21, 2 * 8, AR_INTGATE32); + Set_GateDescriptor(idt + 0x2c, (int) asm_inthandler2c, 2 * 8, AR_INTGATE32); + + return; + } + + void Descriptor::Set_SegmentDescriptor(struct SEGMENT_DESCRIPTOR *sd, unsigned int limit, int base, int ar) { + if (limit > 0xfffff) { + ar |= 0x8000; /* G_bit = 1 */ + limit /= 0x1000; + } + + sd->limit_low = limit & 0xffff; + sd->base_low = base & 0xffff; + sd->base_mid = (base >> 16) & 0xff; + sd->access_right = ar & 0xff; + sd->limit_high = ((limit >> 16) & 0xff) | ((ar >> 8) & 0xf0); + sd->base_high = (base >> 24) & 0x0f; + + return; + }; + + void Descriptor::Set_GateDescriptor(struct GATE_DESCRIPTOR *gd, int offset, int selector, int ar) { + gd->offset_low = offset & 0xffff; + gd->selector = selector; + gd->dw_count = (ar >> 8) & 0xff; + gd->access_right = ar & 0xff; + gd->offset_high = (offset >> 16) & 0xffff; + + return; + } +}; +}; Added: PhoeniOS/trunk/system/descriptor.h =================================================================== --- PhoeniOS/trunk/system/descriptor.h (rev 0) +++ PhoeniOS/trunk/system/descriptor.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,41 @@ +/* --------------------------------------------------------- */ +/* File: descriptor.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: GDT,IDT????????????? */ +/* --------------------------------------------------------- */ + +#define ADR_IDT 0x0026f800 +#define LIMIT_IDT 0x000007ff +#define ADR_GDT 0x00270000 +#define LIMIT_GDT 0x0000ffff +#define ADR_KERNEL 0x00280000 +#define LIMIT_KERNEL 0x0007ffff +#define AR_DATA32_RW 0x4092 +#define AR_CODE32_ER 0x409a +#define AR_INTGATE32 0x008e + +struct SEGMENT_DESCRIPTOR { + short limit_low, base_low; + char base_mid, access_right; + char limit_high, base_high; +}; +struct GATE_DESCRIPTOR { + short offset_low, selector; + char dw_count, access_right; + short offset_high; +}; + +#ifdef __cplusplus +namespace System { +namespace Descriptor { + class Descriptor { + public: + static void Initialize(void); + private: + static void Set_SegmentDescriptor(struct SEGMENT_DESCRIPTOR *sd, unsigned int limit, int base, int ar); + static void Set_GateDescriptor(struct GATE_DESCRIPTOR *gd, int offset, int selector, int ar); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/drawing.cpp =================================================================== --- PhoeniOS/trunk/system/drawing.cpp (rev 0) +++ PhoeniOS/trunk/system/drawing.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,57 @@ +/* --------------------------------------------------------- */ +/* File: drawing.cpp */ +/* Update: 2009/01/18 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Graphic { + void Drawing::FillRectangle_8(char *vram, int xsize, unsigned char c, int x0, int y0, int x1, int y1) + { + int x, y; + + for (y = y0; y <= y1; y++) + { + for (x = x0; x <= x1; x++) + { + vram[y * xsize + x] = c; + } + } + + return; + } + + void Drawing::PutFont(char *vram, int xsize, int x, int y, char c, char *font) { + int i; + char *p, d; + + for (i = 0; i < 16; i++) { + p = vram + (y + i) * xsize + x; + d = font[i]; + + if ((d & 0x80) != 0) { p[0] = c; } + if ((d & 0x40) != 0) { p[1] = c; } + if ((d & 0x20) != 0) { p[2] = c; } + if ((d & 0x10) != 0) { p[3] = c; } + if ((d & 0x08) != 0) { p[4] = c; } + if ((d & 0x04) != 0) { p[5] = c; } + if ((d & 0x02) != 0) { p[6] = c; } + if ((d & 0x01) != 0) { p[7] = c; } + } + + return; + } + + void Drawing::PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s) { + for (; *s != 0x00; s++) { + PutFont(vram, xsize, x, y, c, hankaku + *s * 16); + x += 8; + } + } +}; +}; Added: PhoeniOS/trunk/system/drawing.h =================================================================== --- PhoeniOS/trunk/system/drawing.h (rev 0) +++ PhoeniOS/trunk/system/drawing.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,28 @@ +/* --------------------------------------------------------- */ +/* File: drawing.cpp */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + extern char hankaku[4096]; +#ifdef __cplusplus +} +#endif + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Drawing { + public: + static void FillRectangle_8(char *vram, int xsize, unsigned char c, int x0, int y0, int x1, int y1); + static void PutFont(char *vram, int xsize, int x, int y, char c, char *font); + static void PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/fifo.cpp =================================================================== --- PhoeniOS/trunk/system/fifo.cpp (rev 0) +++ PhoeniOS/trunk/system/fifo.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,65 @@ +/* --------------------------------------------------------- */ +/* File: fifo.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?FIFO??????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +namespace System { +namespace FIFO { + void FIFO8::Initialize(int s, unsigned char *b) { + size = s; + buf = b; + free = s; + flags = 0; + p = 0; + q = 0; + + return; + } + + int FIFO8::Put(unsigned char d) { + if (free == 0) { + flags |= FLAGS_OVERRUN; + return -1; + } + + buf[p] = d; + p++; + + if (p == size) { + p = 0; + } + + free--; + + return 0; + } + + int FIFO8::Get(void) { + int data; + + if (free == size) { + return -1; + } + + data = buf[q]; + q++; + + if (q == size) { + q = 0; + } + + free++; + + return data; + } + + int FIFO8::Status(void) { + return size - free; + } +}; +}; Added: PhoeniOS/trunk/system/fifo.h =================================================================== --- PhoeniOS/trunk/system/fifo.h (rev 0) +++ PhoeniOS/trunk/system/fifo.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,30 @@ +/* --------------------------------------------------------- */ +/* File: fifo.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?FIFO??????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define FLAGS_OVERRUN 0x0001 + +#ifdef __cplusplus +namespace System { +namespace FIFO{ + class FIFO8 { + public: + void Initialize(int s, unsigned char *b); + int Put(unsigned char d); + int Get(void); + int Status(void); + + unsigned char *buf; + int p; + int q; + int size; + int free; + int flags; + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/hankaku.txt =================================================================== --- PhoeniOS/trunk/system/hankaku.txt (rev 0) +++ PhoeniOS/trunk/system/hankaku.txt 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,4607 @@ +char 0x00 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x01 +........ +........ +..***... +.*...*.. +*.....*. +*.*.*.*. +*.*.*.*. +*.....*. +*.....*. +*.*.*.*. +*..*..*. +.*...*.. +..***... +........ +........ +........ + +char 0x02 +........ +........ +..***... +.*****.. +*******. +**.*.**. +**.*.**. +*******. +*******. +**.*.**. +***.***. +.*****.. +..***... +........ +........ +........ + +char 0x03 +........ +........ +........ +........ +.**.**.. +*******. +*******. +*******. +.*****.. +..***... +...*.... +........ +........ +........ +........ +........ + +char 0x04 +........ +........ +........ +........ +...*.... +..***... +.*****.. +*******. +.*****.. +..***... +...*.... +........ +........ +........ +........ +........ + +char 0x05 +........ +........ +........ +........ +...*.... +..***... +.*.*.*.. +*******. +.*.*.*.. +...*.... +..***... +........ +........ +........ +........ +........ + +char 0x06 +........ +........ +........ +........ +...*.... +..***... +.*****.. +*******. +**.*.**. +...*.... +..***... +........ +........ +........ +........ +........ + +char 0x07 +........ +........ +........ +........ +........ +........ +...**... +..****.. +..****.. +...**... +........ +........ +........ +........ +........ +........ + +char 0x08 +******** +******** +******** +******** +******** +******** +***..*** +**....** +**....** +***..*** +******** +******** +******** +******** +******** +******** + +char 0x09 +........ +........ +........ +........ +........ +..****.. +.**..**. +.*....*. +.*....*. +.**..**. +..****.. +........ +........ +........ +........ +........ + +char 0x0a +******** +******** +******** +******** +******** +**....** +*..**..* +*.****.* +*.****.* +*..**..* +**....** +******** +******** +******** +******** +******** + +char 0x0b +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x0c +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +........ +........ + +char 0x0d +........ +........ +....**.. +....***. +....*.** +....*.** +....*.*. +....*... +....*... +...**... +.****... +*****... +.***.... +........ +........ +........ + +char 0x0e +........ +........ +...***** +...***** +...*...* +...*...* +...*...* +...*...* +...*...* +...*...* +.***.*** +******** +.**..**. +........ +........ +........ + +char 0x0f +........ +........ +........ +........ +...*.... +.*.*.*.. +..***... +..*.*... +..***... +.*.*.*.. +...*.... +........ +........ +........ +........ +........ + +char 0x10 +........ +*....... +**...... +***..... +****.... +*****... +******.. +*******. +******.. +*****... +****.... +***..... +**...... +*....... +........ +........ + +char 0x11 +........ +......*. +.....**. +....***. +...****. +..*****. +.******. +*******. +.******. +..*****. +...****. +....***. +.....**. +......*. +........ +........ + +char 0x12 +........ +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +........ +........ +........ + +char 0x13 +........ +........ +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +........ +........ +.*...*.. +.*...*.. +........ +........ + +char 0x14 +........ +..*****. +.*..*.*. +*...*.*. +*...*.*. +*...*.*. +*...*.*. +.*..*.*. +..***.*. +....*.*. +....*.*. +....*.*. +....*.*. +....*.*. +........ +........ + +char 0x15 +.*****.. +*.....*. +.*...... +..*..... +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +....*... +.....*.. +*.....*. +.*****.. +........ + +char 0x16 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +*******. +*******. +........ +........ + +char 0x17 +........ +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +.*****.. +........ +........ + +char 0x18 +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x19 +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +........ +........ + +char 0x1a +........ +........ +........ +........ +...*.... +....*... +.....*.. +*******. +.....*.. +....*... +...*.... +........ +........ +........ +........ +........ + +char 0x1b +........ +........ +........ +........ +...*.... +..*..... +.*...... +*******. +.*...... +..*..... +...*.... +........ +........ +........ +........ +........ + +char 0x1c +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*....... +*....... +*******. +........ +........ + +char 0x1d +........ +........ +........ +........ +........ +..*.*... +.*...*.. +*******. +.*...*.. +..*.*... +........ +........ +........ +........ +........ +........ + +char 0x1e +........ +........ +........ +........ +...*.... +...*.... +..***... +..***... +.*****.. +.*****.. +*******. +*******. +........ +........ +........ +........ + +char 0x1f +........ +........ +........ +........ +*******. +*******. +.*****.. +.*****.. +..***... +..***... +...*.... +...*.... +........ +........ +........ +........ + +char 0x20 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x21 +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ +...*.... +...*.... +........ +........ + +char 0x22 +..*.*... +..*.*... +..*.*... +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x23 +........ +.*...*.. +.*...*.. +.*...*.. +*******. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +*******. +.*...*.. +.*...*.. +.*...*.. +........ +........ + +char 0x24 +...*.... +..***.*. +.*.*.**. +*..*..*. +*..*..*. +*..*.... +.*.*.... +..***... +...*.*.. +...*..*. +*..*..*. +*..*..*. +**.*.*.. +*.***... +...*.... +...*.... + +char 0x25 +.**...*. +*..*..*. +*..*.*.. +*..*.*.. +.**.*... +....*... +...*.... +...*.... +..*..... +..*.**.. +.*.*..*. +.*.*..*. +*..*..*. +*...**.. +........ +........ + +char 0x26 +........ +.***.... +*...*... +*...*... +*...*... +*..*.... +.**..... +.*...*** +*.*...*. +*..*..*. +*...*.*. +*....*.. +.*...**. +..***..* +........ +........ + +char 0x27 +.....*.. +....*... +...*.... +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x28 +......*. +.....*.. +....*... +....*... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +....*... +....*... +.....*.. +......*. +........ + +char 0x29 +*....... +.*...... +..*..... +..*..... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..*..... +..*..... +.*...... +*....... +........ + +char 0x2a +........ +........ +........ +........ +........ +...*.... +*..*..*. +.*.*.*.. +..***... +.*.*.*.. +*..*..*. +...*.... +........ +........ +........ +........ + +char 0x2b +........ +........ +........ +........ +........ +...*.... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +........ +........ +........ +........ + +char 0x2c +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +...**... +...**... +....*... +....*... +...*.... + +char 0x2d +........ +........ +........ +........ +........ +........ +........ +........ +*******. +........ +........ +........ +........ +........ +........ +........ + +char 0x2e +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +...**... +...**... +........ +........ + +char 0x2f +......*. +......*. +.....*.. +.....*.. +....*... +....*... +....*... +...*.... +...*.... +..*..... +..*..... +.*...... +.*...... +.*...... +*....... +*....... + +char 0x30 +........ +...**... +..*..*.. +..*..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +...**... +........ +........ + +char 0x31 +........ +....*... +...**... +..*.*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +..*****. +........ +........ + +char 0x32 +........ +...**... +..*..*.. +.*....*. +.*....*. +......*. +.....*.. +....*... +...*.... +..*..... +..*..... +.*...... +.*...... +.******. +........ +........ + +char 0x33 +........ +...**... +..*..*.. +.*....*. +......*. +......*. +.....*.. +...**... +.....*.. +......*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x34 +........ +....**.. +....**.. +....**.. +...*.*.. +...*.*.. +...*.*.. +..*..*.. +..*..*.. +.*...*.. +.******. +.....*.. +.....*.. +...****. +........ +........ + +char 0x35 +........ +.*****.. +.*...... +.*...... +.*...... +.*.**... +.**..*.. +......*. +......*. +......*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x36 +........ +...**... +..*..*.. +.*....*. +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x37 +........ +.******. +.*....*. +.*....*. +.....*.. +.....*.. +....*... +....*... +....*... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x38 +........ +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x39 +........ +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..**. +...**.*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x3a +........ +........ +........ +........ +........ +...**... +...**... +........ +........ +........ +........ +........ +...**... +...**... +........ +........ + +char 0x3b +........ +........ +........ +........ +........ +...**... +...**... +........ +........ +........ +........ +...**... +...**... +....*... +....*... +...*.... + +char 0x3c +........ +......*. +.....*.. +....*... +...*.... +..*..... +.*...... +*....... +*....... +.*...... +..*..... +...*.... +....*... +.....*.. +......*. +........ + +char 0x3d +........ +........ +........ +........ +........ +........ +*******. +........ +........ +*******. +........ +........ +........ +........ +........ +........ + +char 0x3e +........ +*....... +.*...... +..*..... +...*.... +....*... +.....*.. +......*. +......*. +.....*.. +....*... +...*.... +..*..... +.*...... +*....... +........ + +char 0x3f +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.....*.. +....*... +...*.... +...*.... +........ +........ +...**... +...**... +........ +........ + +char 0x40 +........ +..***... +.*...*.. +*.....*. +*..**.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*..***.. +*....... +.*...**. +..***... +........ +........ + +char 0x41 +........ +...**... +...**... +...**... +...**... +..*..*.. +..*..*.. +..*..*.. +..*..*.. +.******. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x42 +........ +****.... +.*..*... +.*...*.. +.*...*.. +.*...*.. +.*..*... +.****... +.*...*.. +.*....*. +.*....*. +.*....*. +.*...*.. +*****... +........ +........ + +char 0x43 +........ +..***.*. +.*...**. +.*....*. +*.....*. +*....... +*....... +*....... +*....... +*....... +*.....*. +.*....*. +.*...*.. +..***... +........ +........ + +char 0x44 +........ +*****... +.*...*.. +.*...*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*...*.. +.*...*.. +*****... +........ +........ + +char 0x45 +........ +*******. +.*....*. +.*....*. +.*...... +.*...... +.*...*.. +.*****.. +.*...*.. +.*...... +.*...... +.*....*. +.*....*. +*******. +........ +........ + +char 0x46 +........ +*******. +.*....*. +.*....*. +.*...... +.*...... +.*...*.. +.*****.. +.*...*.. +.*...*.. +.*...... +.*...... +.*...... +****.... +........ +........ + +char 0x47 +........ +..***.*. +.*...**. +.*....*. +*.....*. +*....... +*....... +*..****. +*.....*. +*.....*. +*.....*. +.*....*. +.*...**. +..***... +........ +........ + +char 0x48 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.******. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x49 +........ +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x4a +........ +...***** +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +*....*.. +.*..*... +..**.... +........ + +char 0x4b +........ +***..*** +.*....*. +.*...*.. +.*..*... +.*.*.... +.*.*.... +.**..... +.*.*.... +.*.*.... +.*..*... +.*...*.. +.*....*. +***..*** +........ +........ + +char 0x4c +........ +****.... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*....*. +.*....*. +*******. +........ +........ + +char 0x4d +........ +**....** +.*....*. +.**..**. +.**..**. +.**..**. +.*.**.*. +.*.**.*. +.*.**.*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x4e +........ +**...*** +.*....*. +.**...*. +.**...*. +.*.*..*. +.*.*..*. +.*.*..*. +.*..*.*. +.*..*.*. +.*..*.*. +.*...**. +.*...**. +***...*. +........ +........ + +char 0x4f +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x50 +........ +*****... +.*...*.. +.*....*. +.*....*. +.*....*. +.*...*.. +.****... +.*...... +.*...... +.*...... +.*...... +.*...... +****.... +........ +........ + +char 0x51 +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*..*..*. +*...*.*. +.*...*.. +..***.*. +........ +........ + +char 0x52 +........ +******.. +.*....*. +.*....*. +.*....*. +.*....*. +.*****.. +.*...*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x53 +........ +..***.*. +.*...**. +*.....*. +*.....*. +*....... +.*...... +..***... +.....*.. +......*. +*.....*. +*.....*. +**...*.. +*.***... +........ +........ + +char 0x54 +........ +*******. +*..*..*. +*..*..*. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x55 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..****.. +........ +........ + +char 0x56 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +...**... +...**... +........ +........ + +char 0x57 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*.**.*. +.*.**.*. +.*.**.*. +.*.**.*. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +........ +........ + +char 0x58 +........ +***..*** +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +..*..*.. +..*..*.. +..*..*.. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x59 +........ +***.***. +.*...*.. +.*...*.. +.*...*.. +..*.*... +..*.*... +..*.*... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x5a +........ +*******. +*....*.. +*....*.. +....*... +....*... +...*.... +...*.... +..*..... +..*..... +.*...... +.*....*. +*.....*. +*******. +........ +........ + +char 0x5b +........ +..*****. +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*****. +........ + +char 0x5c +*....... +*....... +.*...... +.*...... +..*..... +..*..... +..*..... +...*.... +...*.... +....*... +....*... +.....*.. +.....*.. +.....*.. +......*. +......*. + +char 0x5d +........ +.*****.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.*****.. +........ + +char 0x5e +........ +...*.... +..*.*... +.*...*.. +*.....*. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x5f +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +........ + +char 0x60 +...*.... +....*... +.....*.. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x61 +........ +........ +........ +........ +........ +.***.... +....*... +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +*...**.. +.***.**. +........ +........ + +char 0x62 +**...... +.*...... +.*...... +.*...... +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.**..*.. +.*.**... +........ +........ + +char 0x63 +........ +........ +........ +........ +........ +..**.... +.*..**.. +*....*.. +*....*.. +*....... +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x64 +....**.. +.....*.. +.....*.. +.....*.. +.....*.. +..**.*.. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.**. +........ +........ + +char 0x65 +........ +........ +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +******.. +*....... +*.....*. +.*....*. +..****.. +........ +........ + +char 0x66 +....***. +...*.... +...*.... +...*.... +...*.... +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x67 +........ +........ +........ +........ +........ +..**.**. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.*.. +.....*.. +.....*.. +.****... + +char 0x68 +**...... +.*...... +.*...... +.*...... +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***...** +........ +........ + +char 0x69 +........ +...*.... +...*.... +........ +........ +..**.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x6a +........ +.....*.. +.....*.. +........ +........ +....**.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +....*... +....*... +..**.... + +char 0x6b +**...... +.*...... +.*...... +.*...... +.*...... +.*..***. +.*...*.. +.*..*... +.*.*.... +.**..... +.*.*.... +.*..*... +.*...*.. +***..**. +........ +........ + +char 0x6c +..**.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x6d +........ +........ +........ +........ +........ +****.**. +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +**.**.** +........ +........ + +char 0x6e +........ +........ +........ +........ +........ +**.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***...** +........ +........ + +char 0x6f +........ +........ +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x70 +........ +........ +........ +........ +........ +**.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.**..*.. +.*.**... +.*...... +***..... + +char 0x71 +........ +........ +........ +........ +........ +..**.*.. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.*.. +.....*.. +....***. + +char 0x72 +........ +........ +........ +........ +........ +**.***.. +.**...*. +.*....*. +.*...... +.*...... +.*...... +.*...... +.*...... +***..... +........ +........ + +char 0x73 +........ +........ +........ +........ +........ +.****.*. +*....**. +*.....*. +**...... +..***... +.....**. +*.....*. +**....*. +*.****.. +........ +........ + +char 0x74 +........ +........ +...*.... +...*.... +...*.... +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +....***. +........ +........ + +char 0x75 +........ +........ +........ +........ +........ +**...**. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*...**. +..***.** +........ +........ + +char 0x76 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +........ +........ + +char 0x77 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +.*.**.*. +.*.**.*. +.*.**.*. +..*..*.. +..*..*.. +..*..*.. +........ +........ + +char 0x78 +........ +........ +........ +........ +........ +**...**. +.*...*.. +..*.*... +..*.*... +...*.... +..*.*... +..*.*... +.*...*.. +**...**. +........ +........ + +char 0x79 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +...*.... +...*.... +.**..... + +char 0x7a +........ +........ +........ +........ +........ +*******. +*.....*. +*....*.. +....*... +...*.... +..*..... +.*....*. +*.....*. +*******. +........ +........ + +char 0x7b +........ +.....**. +....*... +...*.... +...*.... +...*.... +...*.... +.**..... +...*.... +...*.... +...*.... +...*.... +....*... +.....**. +........ +........ + +char 0x7c +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0x7d +........ +.**..... +...*.... +....*... +....*... +....*... +....*... +.....**. +....*... +....*... +....*... +....*... +...*.... +.**..... +........ +........ + +char 0x7e +........ +.***..*. +*...**.. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x7f +........ +........ +........ +........ +...*.... +..*.*... +.*...*.. +*.....*. +*******. +*.....*. +*******. +........ +........ +........ +........ +........ + +char 0x80 +........ +..***... +.*...*.. +*.....*. +*....... +*....... +*....... +*....... +*....... +*....... +*....... +*.....*. +.*...*.. +..***... +...*.... +..*..... + +char 0x81 +........ +........ +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x82 +....**.. +....*... +...*.... +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x83 +........ +...*.... +..*.*... +.*...*.. +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x84 +........ +........ +..*..*.. +..*..*.. +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x85 +...*.... +....*... +.....*.. +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x86 +........ +...**... +..*..*.. +...**... +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x87 +........ +........ +........ +........ +........ +..****.. +.*....*. +*....... +*....... +*....... +*....... +*....... +.*....*. +..****.. +....*... +...*.... + +char 0x88 +........ +...*.... +..*.*... +.*...*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x89 +........ +........ +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x8a +...*.... +....*... +.....*.. +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x8b +........ +........ +..*..*.. +..*..*.. +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8c +........ +...*.... +..*.*... +.*...*.. +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8d +...*.... +....*... +.....*.. +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8e +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*******. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0x8f +........ +..***... +.*...*.. +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*******. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0x90 +....**.. +....*... +...*.... +*******. +*....... +*....... +*....... +*....... +*****... +*....... +*....... +*....... +*....... +*******. +........ +........ + +char 0x91 +........ +........ +........ +........ +........ +.**..... +...***.. +...*..*. +.***..*. +*..****. +*..*.... +*..*.... +*..*..*. +.**.**.. +........ +........ + +char 0x92 +....**.. +...*.... +..*..... +..*.*... +..*.*... +..*.*... +*******. +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +........ +........ + +char 0x93 +........ +...*.... +..*.*... +.*...*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x94 +........ +........ +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x95 +...*.... +....*... +.....*.. +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x96 +........ +...*.... +..*.*... +.*...*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x97 +...*.... +....*... +.....*.. +........ +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x98 +........ +........ +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +.*...*.. +.*...*.. +..*.*... +..*.*... +...*.... +...*.... +..*..... +..*..... +.*...... + +char 0x99 +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x9a +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x9b +........ +..*.*... +..*.*... +..*.*... +..****.. +.**.*.*. +*.*.*... +*.*.*... +*.*.*... +*.*.*... +*.*.*... +.**.*.*. +..****.. +..*.*... +..*.*... +..*.*... + +char 0x9c +........ +....**.. +...*..*. +..*..... +..*..... +..*..... +******.. +..*..... +..*..... +..*..... +.**..... +*.*..... +*.**..*. +.*..**.. +........ +........ + +char 0x9d +........ +*.....*. +*.....*. +.*...*.. +..*.*... +...*.... +*******. +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x9e +........ +***..... +*..*.... +*...*... +*...*... +*...*... +*..*.*.. +***..*.. +*..***** +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +........ +........ + +char 0x9f +........ +....**.. +...*..*. +...*.... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +...*.... +...*.... +*..*.... +.**..... +........ +........ + +char 0xa0 +....**.. +....*... +...*.... +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0xa1 +....**.. +....*... +...*.... +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0xa2 +....**.. +....*... +...*.... +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0xa3 +....**.. +....*... +...*.... +........ +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0xa4 +........ +...*..*. +..*.*.*. +..*..*.. +........ +*****... +*....*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0xa5 +...*..*. +..*.*.*. +..*..*.. +........ +*.....*. +**....*. +**....*. +*.*...*. +*..*..*. +*..*..*. +*...*.*. +*....**. +*....**. +*.....*. +........ +........ + +char 0xa6 +........ +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +*******. +........ +........ + +char 0xa7 +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +*******. +........ +........ + +char 0xa8 +........ +...*.... +...*.... +........ +........ +...*.... +...*.... +..*..... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0xa9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +*....... +*....... +*....... +........ +........ + +char 0xaa +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +......*. +......*. +......*. +........ +........ + +char 0xab +........ +...*.... +..**.... +...*.... +...*.... +...*.... +........ +*******. +........ +.****... +.....*.. +..***... +.*...... +.*****.. +........ +........ + +char 0xac +........ +...*.... +..**.... +...*.... +...*.... +...*.... +........ +*******. +........ +...**... +..*.*... +.*..*... +.*****.. +....*... +........ +........ + +char 0xad +........ +...*.... +...*.... +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0xae +........ +........ +........ +........ +...*..*. +..*..*.. +.*..*... +*..*.... +*..*.... +.*..*... +..*..*.. +...*..*. +........ +........ +........ +........ + +char 0xaf +........ +........ +........ +........ +*..*.... +.*..*... +..*..*.. +...*..*. +...*..*. +..*..*.. +.*..*... +*..*.... +........ +........ +........ +........ + +char 0xb0 +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. + +char 0xb1 +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. + +char 0xb2 +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* + +char 0xb3 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb4 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb5 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb6 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xb7 +........ +........ +........ +........ +........ +........ +........ +******.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xb8 +........ +........ +........ +........ +........ +........ +........ +****.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb9 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +.....*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xba +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xbb +........ +........ +........ +........ +........ +........ +........ +******.. +.....*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xbc +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +.....*.. +******.. +........ +........ +........ +........ +........ +........ + +char 0xbd +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +******.. +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xbe +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +****.... +........ +........ +........ +........ +........ +........ + +char 0xbf +........ +........ +........ +........ +........ +........ +........ +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc0 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc1 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc2 +........ +........ +........ +........ +........ +........ +........ +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc3 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc4 +........ +........ +........ +........ +........ +........ +........ +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc5 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc6 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc7 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xc8 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.... +...***** +........ +........ +........ +........ +........ +........ + +char 0xc9 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xca +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xcb +........ +........ +........ +........ +........ +........ +........ +******** +........ +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcc +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.... +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcd +........ +........ +........ +........ +........ +........ +........ +******** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xce +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +........ +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcf +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xd0 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xd1 +........ +........ +........ +........ +........ +........ +........ +******** +........ +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd2 +........ +........ +........ +........ +........ +........ +........ +******** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd3 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...***** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xd4 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...***** +........ +........ +........ +........ +........ +........ + +char 0xd5 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd6 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd7 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd8 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +...*.... +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd9 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xda +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xdb +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** + +char 0xdc +........ +........ +........ +........ +........ +........ +........ +........ +******** +******** +******** +******** +******** +******** +******** +******** + +char 0xdd +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... + +char 0xde +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** + +char 0xdf +******** +******** +******** +******** +******** +******** +******** +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe0 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe1 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe2 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe3 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe4 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe5 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe6 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe7 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe8 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xea +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xeb +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xec +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xed +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xee +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xef +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf0 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf1 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf2 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf3 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf4 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf5 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf6 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf7 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf8 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfa +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfb +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfc +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfd +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfe +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xff +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ Added: PhoeniOS/trunk/system/int.cpp =================================================================== --- PhoeniOS/trunk/system/int.cpp (rev 0) +++ PhoeniOS/trunk/system/int.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,59 @@ +/* --------------------------------------------------------- */ +/* File: int.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +extern System::FIFO::FIFO8 keyfifo; + +using namespace System::Graphic; +using namespace System::Information; + +namespace System { +namespace Interrupt { + void PIC::Initialize(void) { + io_out8(PIC0_IMR, 0xff); /* ?????????????? */ + io_out8(PIC1_IMR, 0xff); /* ?????????????? */ + + io_out8(PIC0_ICW1, 0x11); /* ????????? */ + io_out8(PIC0_ICW2, 0x20); /* IRQ0-7?, INT20-27???? */ + io_out8(PIC0_ICW3, 1 << 2); /* PIC1?IRQ2???? */ + io_out8(PIC0_ICW4, 0x01); /* ????????? */ + + io_out8(PIC1_ICW1, 0x11); /* ????????? */ + io_out8(PIC1_ICW2, 0x28); /* IRQ8-15?, INT28-2f???? */ + io_out8(PIC1_ICW3, 2); /* PIC1?IRQ2???? */ + io_out8(PIC1_ICW4, 0x01); /* ????????? */ + + io_out8(PIC0_IMR, 0xfb); /* 11111011 PIC1?????????????? */ + io_out8(PIC1_IMR, 0xff); /* 11111111 ?????????? */ + + return; + } + + /* PS/2???????????? */ + void Handlers::Handler21(int *esp) { + unsigned char data; + io_out8(PIC0_OCW2, 0x61); /* IRQ-01?????PIC??? */ + data = io_in8(PORT_KEYDAT); + keyfifo.Put(data); + return; + } + + /* PS/2?????????? */ + void Handlers::Handler2c(int *esp) { + BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 0, 0), 0, 0, 32 * 8 - 1, 15); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 0, 0, Color::RGB24To8(255, 255, 255), (unsigned char *) "INT 2C (IRQ-12) : PS/2 Mouse"); + + for (;;) { + io_hlt(); + } + } +}; +}; Added: PhoeniOS/trunk/system/int.h =================================================================== --- PhoeniOS/trunk/system/int.h (rev 0) +++ PhoeniOS/trunk/system/int.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,42 @@ +/* --------------------------------------------------------- */ +/* File: int.h */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define PIC0_IMR 0x0021 +#define PIC0_ICW1 0x0020 +#define PIC0_ICW2 0x0021 +#define PIC0_ICW3 0x0021 +#define PIC0_ICW4 0x0021 +#define PIC0_OCW1 0x0021 +#define PIC0_OCW2 0x0020 +#define PIC0_OCW3 0x0020 +#define PIC1_IMR 0x00a1 +#define PIC1_ICW1 0x00a0 +#define PIC1_ICW2 0x00a1 +#define PIC1_ICW3 0x00a1 +#define PIC1_ICW4 0x00a1 +#define PIC1_OCW1 0x00a1 +#define PIC1_OCW2 0x00a0 +#define PIC1_OCW3 0x00a0 +#define PORT_KEYDAT 0x0060 + +#ifdef __cplusplus +namespace System { +namespace Interrupt { + class PIC { + public: + static void Initialize(void); + }; + + class Handlers { + public: + static void Handler21(int *esp); + static void Handler2c(int *esp); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/ipl.bin =================================================================== (Binary files differ) Property changes on: PhoeniOS/trunk/system/ipl.bin ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Added: PhoeniOS/trunk/system/ipl.nas =================================================================== --- PhoeniOS/trunk/system/ipl.nas (rev 0) +++ PhoeniOS/trunk/system/ipl.nas 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,175 @@ +; --------------------------------------------------------- +; File: ipl.nas +; Version: 1.1.0 +; Update: 2008/11/16 +; License: GNU General Public License v3 +; Description: PhoeniOS?IPL?? +; CYLS????????????????? +; ???????OS???????? +; --------------------------------------------------------- + +CYLS EQU 10 ; ????????? (30??????) + + ORG 0x7c00 ; IPL????????????? + +; ?????I?FAT12?????????????????????+ + JMP entry + DB 0x90 + DB "PhoeniOS" ; ????????? + DW 512 ; 1??????? (??,512Bytes) + DB 1 ; ???????? (??,1Sector) + DW 1 ; FAT??????? (??,1Sector) + DB 2 ; FAT?? (??,2) + DW 224 ; ??????????????? (??,224Entries) + DW 2880 ; ?????????? (??,2880Sectors) + DB 0xf0 ; ???????? (??,0xf0) + DW 9 ; FAT????? (??,9Sectors) + DW 18 ; 1???????????? (??,18Sectors) + DW 2 ; ????? (??,2Heads) + DD 0 ; ???????????????? (??,0) + DD 2880 ; ?????????? (FAT32?) (??,0) + DB 0,0 ; ?? + DB 0x29 ; ?????? (??,0x29) + DD 0xffffffff ; ??????????? + DB "PhoeniOS " ; ???????? + DB "FAT12 " ; ????????? + RESB 18 ; 18?????? + +; ??????? + +entry: + MOV AX,0 ; ???????+ MOV SS,AX + MOV SP,0x7c00 + MOV DS,AX + + CALL put_line + MOV SI,msg_title + CALL put_msg + CALL put_line + +; ??????? + + MOV SI,msg_loading + CALL put_msg + + MOV AX,0x0820 + MOV ES,AX + MOV CH,0 ; ?????0??? + MOV DH,0 ; ????0??? + MOV CL,2 ; ????2??? + +readloop: + MOV SI,0 ; ޏ???????????????+ +retry: + MOV AH,0x02 ; ?????????????? + MOV AL,1 ; 1????????? + MOV BX,0 + MOV DL,0x00 ; A????????? + INT 0x13 ; ????BIOS??????????+ JNC next ; ??????????Next? + ADD SI,1 ; ޏ????1??? + CMP SI,5 + JAE error ; ޏ????5??????Error? + MOV AH,0x00 + MOV DL,0x00 ; A????????? + INT 0x13 ; ????????? + JMP retry + +next: + MOV AX,ES ; ?????0x200??? + ADD AX,0x0020 + MOV ES,AX + ADD CL,1 ; ????1??? + CMP CL,18 + JBE readloop ; ????18?????,Readloop? + MOV CL,1 ; ????1??? + ADD DH,1 ; ????1??? + CMP DH,2 + JB readloop ; ????2???????+ MOV DH,0 ; ????0??? + ADD CH,1 ; ?????1??? + + ; ?????????ަ + PUSH AX + MOV AL,'*' + MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ POP AX + + CMP CH,CYLS + JB readloop ; ?????CYLS???????+ + MOV SI,msg_complete + CALL put_msg + + ; phoenios.sys?ŽÀ? + MOV [0x1000],CH ; BOOTINFO - ?????????? + JMP 0xc200 ; phoenios.sys?ŽÀ? + +fin: + HLT + JMP fin + +error: + MOV AX,0 + MOV ES,AX + MOV SI,msg_load_error + CALL put_msg + JMP fin + +put_msg: + MOV AL,[SI] + ADD SI,1 ; ???????1??? + CMP AL,0 + JE .fin ; ???0?????+ MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ JMP put_msg +.fin: + RET + +put_line: + MOV CX,0 +.next: + MOV AL,'-' + MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ ADD CX,1 + CMP CX,51 + JB .next + RET + +msg_title: + DB 0x0d, 0x0a + DB " PhoeniOS IPL Version:1.1.0", 0x0d, 0x0a + DB " Copyright (C) 2008 Lite Systems.", 0x0d, 0x0a + DB " Licensed under the GNU General Public License v3.", 0x0d, 0x0a + DB 0 + +msg_loading: + DB 0x0d, 0x0a + DB 0x0d, 0x0a + DB "Loading..." + DB 0x0d, 0x0a + DB 0 + +msg_complete: + DB 0x0d, 0x0a + DB "Complete." + DB 0x0d, 0x0a + DB 0 + +msg_load_error: + DB "Load error." + DB 0x0d, 0x0a ; ?? + DB 0 + + RESB 0x7dfe-$ ; 0x7dfe?0???? + + DB 0x55, 0xaa Added: PhoeniOS/trunk/system/main.cpp =================================================================== --- PhoeniOS/trunk/system/main.cpp (rev 0) +++ PhoeniOS/trunk/system/main.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,63 @@ +/* --------------------------------------------------------- */ +/* File: main.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +extern "C" { + void Main(void); +}; + +using namespace System::Descriptor; +using namespace System::FIFO; +using namespace System::Graphic; +using namespace System::Information; +using namespace System::Interrupt; +using namespace System::Mouse; + +FIFO8 keyfifo; +unsigned char keybuf[32]; + +void Main(void) +{ + BootInfo binfo; + char s[40], mcursor[256]; + int mx, my, i; + + Descriptor::Initialize(); + PIC::Initialize(); + + io_sti(); + + Palette::Initialize(); + Background::Draw(); + + mx = (binfo.scrnx - 16) / 2; + my = (binfo.scrny - 28 - 16) / 2; + Cursor::Initialize(mcursor, Color::RGB24To8(0, 64, 128)); + Cursor::PutBlock_8(binfo.vram, binfo.scrnx, 16, 16, mx, my, mcursor, 16); + sprintf(s, "CursorPosition:(%d, %d)", mx, my); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 48, COL8_FFFFFF, (unsigned char *) s); + + keyfifo.Initialize(32, keybuf); + + io_out8(PIC0_IMR, 0xf9); /* PIC1?????????(11111001) */ + io_out8(PIC1_IMR, 0xef); /* ??????(11101111) */ + + for (;;) { + io_cli(); + if (keyfifo.Status() == 0) { + io_stihlt(); + } else { + i = keyfifo.Get(); + io_sti(); + sprintf(s, "%02X", i); + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 8, 72, 23, 87); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 72, Color::RGB24To8(255, 255, 255), (unsigned char *) s); + } + } +} Added: PhoeniOS/trunk/system/make.bat =================================================================== --- PhoeniOS/trunk/system/make.bat (rev 0) +++ PhoeniOS/trunk/system/make.bat 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1 @@ +..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file Added: PhoeniOS/trunk/system/mouse.cpp =================================================================== --- PhoeniOS/trunk/system/mouse.cpp (rev 0) +++ PhoeniOS/trunk/system/mouse.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,93 @@ +/* --------------------------------------------------------- */ +/* File: mouse.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +namespace System { +namespace Mouse { + void Cursor::Initialize(char *mouse, char bc) { + static char cursor[16][17] = { + //"*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OOOOOOOO*......", + "*OOOOO****......", + "*OO*OO*.........", + "*O*.*OO*........", + "**..*OO*........", + "....*OO*........", + ".....*OO*.......", + "......**........" + }; + /*static char cursor[16][17] = { + "*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OO*O****.......", + "*O**O*..........", + "**..*O*.........", + "*...*O*.........", + ".....*O*........", + ".....*O*........", + "......**........" + };*/ + int x, y; + + for (y = 0; y < 16; y++) { + for (x = 0; x < 16; x++) { + if (cursor[y][x] == '*') { + mouse[y * 16 + x] = COL8_000000; + } + if (cursor[y][x] == 'O') { + mouse[y * 16 + x] = COL8_FFFFFF; + } + if (cursor[y][x] == '.') { + mouse[y * 16 + x] = bc; + } + } + } + + return; + } + + void Cursor::PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize) { + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; + } +}; +}; + + +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize) +{ + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; +} Added: PhoeniOS/trunk/system/mouse.h =================================================================== --- PhoeniOS/trunk/system/mouse.h (rev 0) +++ PhoeniOS/trunk/system/mouse.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,29 @@ +/* --------------------------------------------------------- */ +/* File: mouse.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Mouse { + class Cursor { + public: + static void Initialize(char *cursor, char bc); + static void PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize); + }; +}; +}; +#endif + +#ifdef __cplusplus +extern "C" { +#endif +void init_mouse_cursor8(char *mouse, char bc); +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_dsc.h =================================================================== --- PhoeniOS/trunk/system/nask_dsc.h (rev 0) +++ PhoeniOS/trunk/system/nask_dsc.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_dsc.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?GDT,IDT???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void load_gdtr(int limit, int addr); + void load_idtr(int limit, int addr); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_dsc.nas =================================================================== --- PhoeniOS/trunk/system/nask_dsc.nas (rev 0) +++ PhoeniOS/trunk/system/nask_dsc.nas 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,27 @@ +; --------------------------------------------------------- +; File: nask_dsc.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS?GDT,IDT???NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_dsc.nas"] + + GLOBAL _load_gdtr, _load_idtr + +[SECTION .text] + +_load_gdtr: ; void load_gdtr(int limit, int addr); + MOV AX,[ESP+4] ; limit + MOV [ESP+6],AX + LGDT [ESP+6] + RET + +_load_idtr: ; void load_idtr(int limit, int addr); + MOV AX,[ESP+4] ; limit + MOV [ESP+6],AX + LIDT [ESP+6] + RET Added: PhoeniOS/trunk/system/nask_int.h =================================================================== --- PhoeniOS/trunk/system/nask_int.h (rev 0) +++ PhoeniOS/trunk/system/nask_int.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void asm_inthandler21(void); + void asm_inthandler2c(void); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_int.nas =================================================================== --- PhoeniOS/trunk/system/nask_int.nas (rev 0) +++ PhoeniOS/trunk/system/nask_int.nas 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,49 @@ +; --------------------------------------------------------- +; File: nask_int.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS????????NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_int.nas"] + + GLOBAL _asm_inthandler21, _asm_inthandler2c + EXTERN __ZN6System9Interrupt8Handlers9Handler21EPi + EXTERN __ZN6System9Interrupt8Handlers9Handler2cEPi + +[SECTION .text] + +_asm_inthandler21: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler21EPi + POP EAX + POPAD + POP DS + POP ES + IRETD + +_asm_inthandler2c: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler2cEPi + POP EAX + POPAD + POP DS + POP ES + IRETD Added: PhoeniOS/trunk/system/nask_io.h =================================================================== --- PhoeniOS/trunk/system/nask_io.h (rev 0) +++ PhoeniOS/trunk/system/nask_io.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,21 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?IO???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void io_hlt(void); + void io_cli(void); + void io_sti(void); + void io_stihlt(void); + int io_in8(int port); + void io_out8(int port, int data); + int io_load_eflags(void); + void io_store_eflags(int eflags); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_io.nas =================================================================== --- PhoeniOS/trunk/system/nask_io.nas (rev 0) +++ PhoeniOS/trunk/system/nask_io.nas 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,81 @@ +; --------------------------------------------------------- +; File: nask_io.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS?IO???NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_io.nas"] + + GLOBAL _io_hlt, _io_cli, _io_sti, _io_stihlt + GLOBAL _io_in8, _io_in16, _io_in32 + GLOBAL _io_out8, _io_out16, _io_out32 + GLOBAL _io_load_eflags, _io_store_eflags + +[SECTION .text] + +_io_hlt: ; void io_hlt(void); + HLT + RET + +_io_cli: ; void io_cli(void); + CLI + RET + +_io_sti: ; void io_sti(void); + STI + RET + +_io_stihlt: ; void io_stihlt(void); + STI + HLT + RET + +_io_in8: ; int io_in8(int port); + MOV EDX,[ESP+4] ; port + MOV EAX,0 + IN AL,DX + RET + +_io_in16: ; int io_in16(int port); + MOV EDX,[ESP+4] ; port + MOV EAX,0 + IN AX,DX + RET + +_io_in32: ; int io_in32(int port); + MOV EDX,[ESP+4] ; port + IN EAX,DX + RET + +_io_out8: ; void io_out8(int port, int data); + MOV EDX,[ESP+4] ; port + MOV AL,[ESP+8] ; data + OUT DX,AL + RET + +_io_out16: ; void io_out16(int port, int data); + MOV EDX,[ESP+4] ; port + MOV EAX,[ESP+8] ; data + OUT DX,AX + RET + +_io_out32: ; void io_out32(int port, int data); + MOV EDX,[ESP+4] ; port + MOV EAX,[ESP+8] ; data + OUT DX,EAX + RET + +_io_load_eflags: ; int io_load_eflags(void); + PUSHFD + POP EAX + RET + +_io_store_eflags: ; void io_store_eflags(int eflags); + MOV EAX,[ESP+4] + PUSH EAX + POPFD + RET Added: PhoeniOS/trunk/system/palette.cpp =================================================================== --- PhoeniOS/trunk/system/palette.cpp (rev 0) +++ PhoeniOS/trunk/system/palette.cpp 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,73 @@ +/* --------------------------------------------------------- */ +/* File: palette.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Graphic { + void Palette::Initialize(void) { + static unsigned char table_rgb[16 * 3] = { /* ??????? */ + 0x00, 0x00, 0x00, /* 0:? */ + 0xff, 0x00, 0x00, /* 1:???? */ + 0x00, 0xff, 0x00, /* 2:???? */ + 0xff, 0xff, 0x00, /* 3:????? */ + 0x00, 0x00, 0xff, /* 4:???? */ + 0xff, 0x00, 0xff, /* 5:???? */ + 0x00, 0xff, 0xff, /* 6:????? */ + 0xff, 0xff, 0xff, /* 7:? */ + 0xc6, 0xc6, 0xc6, /* 8:????? */ + 0x84, 0x00, 0x00, /* 9:??? */ + 0x00, 0x84, 0x00, /* 10:??? */ + 0x84, 0x84, 0x00, /* 11:???? */ + 0x00, 0x00, 0x84, /* 12:??? */ + 0x84, 0x00, 0x84, /* 13:??? */ + 0x00, 0x84, 0x84, /* 14:???? */ + 0x84, 0x84, 0x84 /* 15:???? */ + }; + unsigned char table_rgb_216[216 * 3]; + int r, g, b; + + Set_Palette(0, 15, table_rgb); /* ??????????????? */ + + for (r = 0; r < 6; r++) { /* 216????????*/ + for (g = 0; g < 6; g++) { + for (b = 0; b < 6; b++) { + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 0] = r * 51; + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 1] = g * 51; + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 2] = b * 51; + } + } + } + + Set_Palette(16, 231, table_rgb_216); /* 216???????????? */ + + return; + } + + void Palette::Set_Palette(int start, int end, unsigned char *rgb) { + int eflags; + + eflags = io_load_eflags(); /* ?????????????? */ + io_cli(); /* ??????? */ + + io_out8(0x03c8, start); /* ?????????????? */ + + for (int i = start; i <= end; i++) { + io_out8(0x03c9, rgb[0] / 4); /* ?????R??? */ + io_out8(0x03c9, rgb[1] / 4); /* ?????G??? */ + io_out8(0x03c9, rgb[2] / 4); /* ?????B??? */ + rgb += 3; + } + + io_store_eflags(eflags); /* ???????????? */ + + return; + } +}; +}; Added: PhoeniOS/trunk/system/palette.h =================================================================== --- PhoeniOS/trunk/system/palette.h (rev 0) +++ PhoeniOS/trunk/system/palette.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,37 @@ +/* --------------------------------------------------------- */ +/* File: palette.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +/* ????????? */ +#define COL8_000000 0 +#define COL8_FF0000 1 +#define COL8_00FF00 2 +#define COL8_FFFF00 3 +#define COL8_0000FF 4 +#define COL8_FF00FF 5 +#define COL8_00FFFF 6 +#define COL8_FFFFFF 7 +#define COL8_C6C6C6 8 +#define COL8_840000 9 +#define COL8_008400 10 +#define COL8_848400 11 +#define COL8_000084 12 +#define COL8_840084 13 +#define COL8_008484 14 +#define COL8_848484 15 + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Palette { + public: + static void Initialize(void); + static void Set_Palette(int start, int end, unsigned char *rgb); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/phoenios.h =================================================================== --- PhoeniOS/trunk/system/phoenios.h (rev 0) +++ PhoeniOS/trunk/system/phoenios.h 2009-03-13 05:28:36 UTC (rev 67) @@ -0,0 +1,22 @@ +/* --------------------------------------------------------- */ +/* File: phoenios.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????????? */ +/* --------------------------------------------------------- */ + +/* C,C++ */ +#include "background.h" +#include "bootinfo.h" +#include "color.h" +#include "descriptor.h" +#include "drawing.h" +#include "fifo.h" +#include "int.h" +#include "mouse.h" +#include "palette.h" + +/* NASK */ +#include "nask_dsc.h" +#include "nask_int.h" +#include "nask_io.h" Added: PhoeniOS/trunk/system/phoenios.sys =================================================================== (Binary files differ) Property changes on: PhoeniOS/trunk/system/phoenios.sys ___________________________________________________________________ Added: svn:mime-type + application/octet-stream From svnnotify ¡÷ sourceforge.jp Fri Mar 13 14:32:33 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Fri, 13 Mar 2009 14:32:33 +0900 Subject: [PhoeniOS-SVN] [Commit] [69] Message-ID: <1236922353.516445.10591.nullmailer@users.sourceforge.jp> Revision: 69 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=69 Author: litesystems Date: 2009-03-13 14:32:33 +0900 (Fri, 13 Mar 2009) Log Message: ----------- Added Paths: ----------- PhoeniOS/trunk/ PhoeniOS/trunk/!cons_9x.bat PhoeniOS/trunk/!cons_nt.bat PhoeniOS/trunk/GPL.html PhoeniOS/trunk/GPL.txt PhoeniOS/trunk/Makefile PhoeniOS/trunk/build.txt PhoeniOS/trunk/make.bat PhoeniOS/trunk/phoenios.rul PhoeniOS/trunk/readme.txt PhoeniOS/trunk/release.txt PhoeniOS/trunk/system/ PhoeniOS/trunk/system/!cons_9x.bat PhoeniOS/trunk/system/!cons_nt.bat PhoeniOS/trunk/system/Makefile PhoeniOS/trunk/system/asmhead.nas PhoeniOS/trunk/system/background.cpp PhoeniOS/trunk/system/background.h PhoeniOS/trunk/system/bootinfo.cpp PhoeniOS/trunk/system/bootinfo.h PhoeniOS/trunk/system/color.cpp PhoeniOS/trunk/system/color.h PhoeniOS/trunk/system/descriptor.cpp PhoeniOS/trunk/system/descriptor.h PhoeniOS/trunk/system/drawing.cpp PhoeniOS/trunk/system/drawing.h PhoeniOS/trunk/system/fifo.cpp PhoeniOS/trunk/system/fifo.h PhoeniOS/trunk/system/hankaku.txt PhoeniOS/trunk/system/int.cpp PhoeniOS/trunk/system/int.h PhoeniOS/trunk/system/ipl.bin PhoeniOS/trunk/system/ipl.nas PhoeniOS/trunk/system/main.cpp PhoeniOS/trunk/system/make.bat PhoeniOS/trunk/system/mouse.cpp PhoeniOS/trunk/system/mouse.h PhoeniOS/trunk/system/nask_dsc.h PhoeniOS/trunk/system/nask_dsc.nas PhoeniOS/trunk/system/nask_int.h PhoeniOS/trunk/system/nask_int.nas PhoeniOS/trunk/system/nask_io.h PhoeniOS/trunk/system/nask_io.nas PhoeniOS/trunk/system/palette.cpp PhoeniOS/trunk/system/palette.h PhoeniOS/trunk/system/phoenios.h PhoeniOS/trunk/system/phoenios.sys -------------- next part -------------- Added: PhoeniOS/trunk/!cons_9x.bat =================================================================== --- PhoeniOS/trunk/!cons_9x.bat (rev 0) +++ PhoeniOS/trunk/!cons_9x.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +command \ No newline at end of file Added: PhoeniOS/trunk/!cons_nt.bat =================================================================== --- PhoeniOS/trunk/!cons_nt.bat (rev 0) +++ PhoeniOS/trunk/!cons_nt.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +cmd.exe \ No newline at end of file Added: PhoeniOS/trunk/GPL.html =================================================================== --- PhoeniOS/trunk/GPL.html (rev 0) +++ PhoeniOS/trunk/GPL.html 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,692 @@ + + + + + + GNU General Public License - GNU Project - Free Software Foundation (FSF) + +

GNU GENERAL PUBLIC LICENSE

+

Version 3, 29 June 2007

+ +

Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>

+ Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed.

+ +

Preamble

+ +

The GNU General Public License is a free, copyleft license for +software and other kinds of works.

+ +

The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too.

+ +

When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things.

+ +

To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others.

+ +

For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights.

+ +

Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it.

+ +

For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions.

+ +

Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users.

+ +

Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free.

+ +

The precise terms and conditions for copying, distribution and +modification follow.

+ +

TERMS AND CONDITIONS

+ +

0. Definitions.

+ +

??his License??refers to version 3 of the GNU General Public License.

+ +

??opyright??also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks.

+ +

??he Program??refers to any copyrightable work licensed under this +License. Each licensee is addressed as ??ou?? ??icensees??and +??ecipients??may be individuals or organizations.

+ +

To ??odify??a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a ??odified version??of the +earlier work or a work ??ased on??the earlier work.

+ +

A ??overed work??means either the unmodified Program or a work based +on the Program.

+ +

To ??ropagate??a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well.

+ +

To ??onvey??a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying.

+ +

An interactive user interface displays ??ppropriate Legal Notices??+to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion.

+ +

1. Source Code.

+ +

The ??ource code??for a work means the preferred form of the work +for making modifications to it. ??bject code??means any non-source +form of a work.

+ +

A ??tandard Interface??means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language.

+ +

The ??ystem Libraries??of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +??ajor Component?? in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it.

+ +

The ??orresponding Source??for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work.

+ +

The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source.

+ +

The Corresponding Source for a work in source code form is that +same work.

+ +

2. Basic Permissions.

+ +

All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law.

+ +

You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you.

+ +

Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary.

+ +

3. Protecting Users' Legal Rights From Anti-Circumvention Law.

+ +

No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures.

+ +

When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures.

+ +

4. Conveying Verbatim Copies.

+ +

You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program.

+ +

You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee.

+ +

5. Conveying Modified Source Versions.

+ +

You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions:

+ +
    +
  • a) The work must carry prominent notices stating that you modified + it, and giving a relevant date.
  • + +
  • b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + ??eep intact all notices??
  • + +
  • c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it.
  • + +
  • d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so.
  • +
+ +

A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +??ggregate??if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate.

+ +

6. Conveying Non-Source Forms.

+ +

You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways:

+ +
    +
  • a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange.
  • + +
  • b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge.
  • + +
  • c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b.
  • + +
  • d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements.
  • + +
  • e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d.
  • +
+ +

A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work.

+ +

A ??ser Product??is either (1) a ??onsumer product?? which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, ??ormally used??refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product.

+ +

??nstallation Information??for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made.

+ +

If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM).

+ +

The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network.

+ +

Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying.

+ +

7. Additional Terms.

+ +

??dditional permissions??are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions.

+ +

When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission.

+ +

Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms:

+ +
    +
  • a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or
  • + +
  • b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or
  • + +
  • c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or
  • + +
  • d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or
  • + +
  • e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or
  • + +
  • f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors.
  • +
+ +

All other non-permissive additional terms are considered ??urther +restrictions??within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying.

+ +

If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms.

+ +

Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way.

+ +

8. Termination.

+ +

You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11).

+ +

However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation.

+ +

Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice.

+ +

Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10.

+ +

9. Acceptance Not Required for Having Copies.

+ +

You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so.

+ +

10. Automatic Licensing of Downstream Recipients.

+ +

Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License.

+ +

An ??ntity transaction??is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts.

+ +

You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it.

+ +

11. Patents.

+ +

A ??ontributor??is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's ??ontributor version??

+ +

A contributor's ??ssential patent claims??are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, ??ontrol??includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License.

+ +

Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version.

+ +

In the following three paragraphs, a ??atent license??is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To ??rant??such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party.

+ +

If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. ??nowingly relying??means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid.

+ +

If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it.

+ +

A patent license is ??iscriminatory??if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007.

+ +

Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law.

+ +

12. No Surrender of Others' Freedom.

+ +

If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program.

+ +

13. Use with the GNU Affero General Public License.

+ +

Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such.

+ +

14. Revised Versions of this License.

+ +

The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns.

+ +

Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License ??r any later version??applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation.

+ +

If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program.

+ +

Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version.

+ +

15. Disclaimer of Warranty.

+ +

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM ??S IS??WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

+ +

16. Limitation of Liability.

+ +

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES.

+ +

17. Interpretation of Sections 15 and 16.

+ +

If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee.

+ +

END OF TERMS AND CONDITIONS

+ +

How to Apply These Terms to Your New Programs

+ +

If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms.

+ +

To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the ??opyright??line and a pointer to where the full notice is found.

+ +
    <one line to give the program's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This program is free software: you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation, either version 3 of the License, or
+    (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+ +

Also add information on how to contact you by electronic and paper mail.

+ +

If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode:

+ +
    <program>  Copyright (C) <year>  <name of author>
+    This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+    This is free software, and you are welcome to redistribute it
+    under certain conditions; type `show c' for details.
+
+ +

The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an ??bout box??

+ +

You should also get your employer (if you work as a programmer) or school, +if any, to sign a ??opyright disclaimer??for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +<http://www.gnu.org/licenses/>.

+ +

The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +<http://www.gnu.org/philosophy/why-not-lgpl.html>.

+ + + \ No newline at end of file Added: PhoeniOS/trunk/GPL.txt =================================================================== --- PhoeniOS/trunk/GPL.txt (rev 0) +++ PhoeniOS/trunk/GPL.txt 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. Added: PhoeniOS/trunk/Makefile =================================================================== --- PhoeniOS/trunk/Makefile (rev 0) +++ PhoeniOS/trunk/Makefile 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,67 @@ +TOOLPATH = ../z_tools/ + +BLDMGR = $(TOOLPATH)BuildManager.exe +MAKE = $(TOOLPATH)make.exe -r +NASK = $(TOOLPATH)nask.exe +EDIMG = $(TOOLPATH)edimg.exe +IMGTOL = $(TOOLPATH)imgtol.com +COPY = copy +DEL = del + +# ??????? + +default : + $(MAKE) phoenios.img + +# ???????? + +phoenios.img : system/ipl.bin system/phoenios.sys Makefile + $(EDIMG) imgin:../z_tools/fdimg0at.tek \ + wbinimg src:system/ipl.bin len:512 from:0 to:0 \ + copy from:system/phoenios.sys to:@: \ + imgout:phoenios.img + $(BLDMGR) build.txt + +# ???? + +run : + $(MAKE) phoenios.img + $(COPY) phoenios.img ..\z_tools\qemu\fdimage0.bin + $(MAKE) -C ../z_tools/qemu + +install : + $(MAKE) phoenios.img + $(IMGTOL) w a: phoenios.img + +full : + $(MAKE) -C system + +run_full : + $(MAKE) full + $(COPY) phoenios.img ..\z_tools\qemu\fdimage0.bin + $(MAKE) -C ../z_tools/qemu + +install_full : + $(MAKE) full + $(IMGTOL) w a: phoenios.img + +run_os : + $(MAKE) -C system + $(MAKE) run + +clean : + +src_only : + $(MAKE) clean + -$(DEL) phoenios.img + +clean_full : + $(MAKE) -C system clean + +src_only_full : + $(MAKE) -C system src_only + +refresh : + $(MAKE) full + $(MAKE) clean_full + -$(DEL) phoenios.img Added: PhoeniOS/trunk/build.txt =================================================================== --- PhoeniOS/trunk/build.txt (rev 0) +++ PhoeniOS/trunk/build.txt 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +256 \ No newline at end of file Added: PhoeniOS/trunk/make.bat =================================================================== --- PhoeniOS/trunk/make.bat (rev 0) +++ PhoeniOS/trunk/make.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file Added: PhoeniOS/trunk/phoenios.rul =================================================================== --- PhoeniOS/trunk/phoenios.rul (rev 0) +++ PhoeniOS/trunk/phoenios.rul 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,19 @@ +format: + /* ?????????????????*/ + code(align:1, logic:0x24, file:0x24); + data(align:4, logic:stack_end, file:code_end); + +file: + /* ????????????????????????+ .ojb?????.lib??????? */ + /* ??????????????????????B */ + /* ?? c:/osask/gg00libc.lib; */ + ../../z_tools/phoenios/phoenios.lib; + ../../z_tools/haribote/golibc.lib; + +label: + /* ???????????????????? */ + /* ???????????????????????? */ + _Startup; + + /* ?L3???????????????????? */ Added: PhoeniOS/trunk/readme.txt =================================================================== --- PhoeniOS/trunk/readme.txt (rev 0) +++ PhoeniOS/trunk/readme.txt 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,11 @@ +------------------------------------------- + Name: PhoeniOS + Version: 0.2.1 (Build 256) + Publisher: Lite Systems + License: GNU General Public License v3 +------------------------------------------- + +1,????? + +PhoeniOS??????? GNU General Public License v3 ??? +?????????GPL.txt???GPL.html???????? Added: PhoeniOS/trunk/release.txt =================================================================== --- PhoeniOS/trunk/release.txt (rev 0) +++ PhoeniOS/trunk/release.txt 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,30 @@ +-------------------------- + PhoeniOS Release Notes +-------------------------- +2009/03/13 Version:0.2.1 (Build 256) +- FIFO?????ŽÀ????? + +2009/02/25 Version:0.2.0 (Build 23) +- GDT,IDT?ŽÀ????? + +2008/12/19 Version:0.1.2 +- ????????????ŽÀ????? + +2008/12/16 Version:0.1.1 +- 16?????????????6??216??????ŽÀ????? + +2008/11/29 Version:0.1.0 +- 32bit??????????????? +- ?????????????+- C,C++??????????? + +2008/11/14 Version:0.0.2 +- IPL??????????+ +2008/11/13 Version:0.0.1 +- IPL?Version:1.0.1????????? + IPL????????????????????????ަ??? + +2008/11/08 Version:0.0.0 +- ??????J +- IPL Version:1.0.0 ??? Added: PhoeniOS/trunk/system/!cons_9x.bat =================================================================== --- PhoeniOS/trunk/system/!cons_9x.bat (rev 0) +++ PhoeniOS/trunk/system/!cons_9x.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +command \ No newline at end of file Added: PhoeniOS/trunk/system/!cons_nt.bat =================================================================== --- PhoeniOS/trunk/system/!cons_nt.bat (rev 0) +++ PhoeniOS/trunk/system/!cons_nt.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +cmd.exe \ No newline at end of file Added: PhoeniOS/trunk/system/Makefile =================================================================== --- PhoeniOS/trunk/system/Makefile (rev 0) +++ PhoeniOS/trunk/system/Makefile 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,77 @@ +OBJS_BOOTPACK = main.obj background.obj bootinfo.obj color.obj descriptor.obj drawing.obj fifo.obj int.obj palette.obj mouse.obj \ + hankaku.obj \ + nask_dsc.obj nask_int.obj nask_io.obj + +TOOLPATH = ../../z_tools/ +INCPATH = ../../z_tools/haribote/ + +MAKE = $(TOOLPATH)make.exe -r +NASK = $(TOOLPATH)nask.exe +CPP = $(TOOLPATH)c++.exe -I../../z_tools/haribote -Os -Wall -nostdlib -fno-builtin -fno-exceptions -fno-rtti -B$(TOOLPATH) -c +CC1 = $(TOOLPATH)cc1.exe -I$(INCPATH) -Os -Wall -quiet +GAS2NASK = $(TOOLPATH)gas2nask.exe -a +OBJ2BIM = $(TOOLPATH)obj2bim.exe +MAKEFONT = $(TOOLPATH)makefont.exe +BIN2OBJ = $(TOOLPATH)bin2obj.exe +BIM2HRB = $(TOOLPATH)bim2hrb.exe +RULEFILE = ../phoenios.rul +DEL = del + +# ??????? + +default : + $(MAKE) ipl.bin + $(MAKE) phoenios.sys + +# ???????? + +ipl.bin : ipl.nas Makefile + $(NASK) ipl.nas ipl.bin ipl.lst + +asmhead.bin : asmhead.nas Makefile + $(NASK) asmhead.nas asmhead.bin asmhead.lst + +hankaku.bin : hankaku.txt Makefile + $(MAKEFONT) hankaku.txt hankaku.bin + +hankaku.obj : hankaku.bin Makefile + $(BIN2OBJ) hankaku.bin hankaku.obj _hankaku + +phoenios.bim : $(OBJS_BOOTPACK) Makefile + $(OBJ2BIM) @$(RULEFILE) out:phoenios.bim stack:3136k map:bootpack.map $(OBJS_BOOTPACK) + +phoenios.hrb : phoenios.bim Makefile + $(BIM2HRB) phoenios.bim phoenios.hrb 0 + +phoenios.sys : asmhead.bin phoenios.hrb Makefile + copy /B asmhead.bin+phoenios.hrb phoenios.sys + +# ???? + +%.obj : %.cpp Makefile + $(CPP) -o $*.obj $*.cpp + +%.gas : %.c Makefile + $(CC1) -o $*.gas $*.c + +%.nas : %.gas Makefile + $(GAS2NASK) $*.gas $*.nas + +%.obj : %.nas Makefile + $(NASK) $*.nas $*.obj $*.lst + +# ???? + +clean : + -$(DEL) asmhead.bin + -$(DEL) hankaku.bin + -$(DEL) *.lst + -$(DEL) *.obj + -$(DEL) *.map + -$(DEL) *.bim + -$(DEL) *.hrb + +src_only : + $(MAKE) clean + -$(DEL) ipl.bin + -$(DEL) phoenios.sys Added: PhoeniOS/trunk/system/asmhead.nas =================================================================== --- PhoeniOS/trunk/system/asmhead.nas (rev 0) +++ PhoeniOS/trunk/system/asmhead.nas 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,201 @@ +; --------------------------------------------------------- +; File: asmhead.nas +; Update: 2009/03/13 +; License: GNU General Public License v3 +; Description: PhoeniOS???????????????+; --------------------------------------------------------- + +[INSTRSET "i486p"] + +KERNEL EQU 0x00280000 ; Kernel????? +DSKCAC EQU 0x00100000 ; ????????????+DSKCAC0 EQU 0x00008000 ; ????????????i??????? + +; ??????? +; 0x100 : 640 x 400 x 8bit +; 0x101 : 640 x 480 x 8bit +; 0x103 : 800 x 600 x 8bit +; 0x105 : 1024 x 768 x 8bit +; 0x107 : 1280 x 1024 x 8bit + +VBEMODE EQU 0x103 ; VBE??? + +; BOOTINFO +CYLS EQU 0x1000 ; ?????????? +LEDS EQU 0x1001 ; ????????+VMODE EQU 0x1002 ; ?? +SCRNX EQU 0x1004 ; ????X +SCRNY EQU 0x1006 ; ????Y +VRAM EQU 0x1008 ; ??????????????? + + ORG 0xc200 + +; VBE?????+ + MOV AX,0x9000 + MOV ES,AX + MOV DI,0 + MOV AX,0x4f00 + INT 0x10 + CMP AX,0x004f + JNE scrn320 + +; VBE?????????? + + MOV AX,[ES:DI+4] + CMP AX,0x0200 + JB scrn320 + +; ??????????+ + MOV CX,VBEMODE + MOV AX,0x4f01 + INT 0x10 + CMP AX,0x004f + JNE scrn320 + +; ????????m? + + CMP BYTE [ES:DI+0x19],8 + JNE scrn320 + CMP BYTE [ES:DI+0x1b],4 + JNE scrn320 + MOV AX,[ES:DI+0x00] + AND AX,0x0080 + JZ scrn320 + +; ?????????? + + MOV BX,VBEMODE+0x4000 + MOV AX,0x4f02 + INT 0x10 + MOV BYTE [VMODE],8 ; BOOTINFO - ?? + MOV AX,[ES:DI+0x12] + MOV [SCRNX],AX ; BOOTINFO - ????X + MOV AX,[ES:DI+0x14] + MOV [SCRNY],AX ; BOOTINFO - ????Y + MOV EAX,[ES:DI+0x28] + MOV [VRAM],EAX ; BOOTINFO - ??????????????? + JMP keystatus + +scrn320: + MOV AL,0x13 + MOV AH,0x00 + INT 0x10 + MOV BYTE [VMODE],8 + MOV WORD [SCRNX],320 + MOV WORD [SCRNY],200 + MOV DWORD [VRAM],0x000a0000 + +keystatus: + MOV AH,0x02 + INT 0x16 + MOV [LEDS],AL ; BOOTINFO - ????????+ +; PIC????????????????? + + MOV AL,0xff + OUT 0x21,AL + NOP + OUT 0xa1,AL + + CLI + +; A20GATE????? + + CALL waitkbdout + MOV AL,0xd1 + OUT 0x64,AL + CALL waitkbdout + MOV AL,0xdf + OUT 0x60,AL + CALL waitkbdout + +; ??????????? + + LGDT [GDTR0] ; ??GDT????? + MOV EAX,CR0 + AND EAX,0x7fffffff ; ???????????,bit31?0??? + OR EAX,0x00000001 ; ??????????????,bit0?1??? + MOV CR0,EAX + JMP pipelineflush + +pipelineflush: + MOV AX,1*8 ; ?????\?????32bit + MOV DS,AX + MOV ES,AX + MOV FS,AX + MOV GS,AX + MOV SS,AX + +; Kernel??? + + MOV ESI,kernel ; ??? + MOV EDI,KERNEL ; ??? + MOV ECX,512*1024/4 + CALL memcpy + +; ??????????? +; ?????? + + MOV ESI,0x7c00 ; ??? + MOV EDI,DSKCAC ; ??? + MOV ECX,512/4 + CALL memcpy + +; ???? + + MOV ESI,DSKCAC0+512 ; ??? + MOV EDI,DSKCAC+512 ; ??? + MOV ECX,0 + MOV CL,BYTE [CYLS] + IMUL ECX,512*18*2/4 ; ???????????/4??? + SUB ECX,512/4 + CALL memcpy + +; Kernel??? + + MOV EBX,KERNEL + MOV ECX,[EBX+16] + ADD ECX,3 + SHR ECX,2 + JZ skip + MOV ESI,[EBX+20] ; ??? + ADD ESI,EBX + MOV EDI,[EBX+12] ; ??? + CALL memcpy +skip: + MOV ESP,[EBX+12] + JMP DWORD 2*8:0x0000001b + +waitkbdout: + IN AL,0x64 + AND AL,0x02 + JNZ waitkbdout + RET + +memcpy: + MOV EAX,[ESI] + ADD ESI,4 + MOV [EDI],EAX + ADD EDI,4 + SUB ECX,1 + JNZ memcpy + RET + + ALIGNB 16 + +GDT0: + RESB 8 + DW 0xffff,0x0000,0x9200,0x00cf ; ?????\?????32bit + DW 0xffff,0x0000,0x9a28,0x0047 ; ŽÀ????????32bit (kernel?) + + DW 0 + +GDTR0: + DW 8*3-1 + DD GDT0 + + ALIGNB 16 + +kernel: Added: PhoeniOS/trunk/system/background.cpp =================================================================== --- PhoeniOS/trunk/system/background.cpp (rev 0) +++ PhoeniOS/trunk/system/background.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,22 @@ +/* --------------------------------------------------------- */ +/* File: background.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Graphic { + void Background::Draw(void) { + System::Information::BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 0, 0, binfo.scrnx, binfo.scrny); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 24, Color::RGB24To8(255, 255, 255), (unsigned char *) "PhoeniOS"); + } +}; +}; +#endif Added: PhoeniOS/trunk/system/background.h =================================================================== --- PhoeniOS/trunk/system/background.h (rev 0) +++ PhoeniOS/trunk/system/background.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,18 @@ +/* --------------------------------------------------------- */ +/* File: background.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Background { + public: + static void Draw(void); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/bootinfo.cpp =================================================================== --- PhoeniOS/trunk/system/bootinfo.cpp (rev 0) +++ PhoeniOS/trunk/system/bootinfo.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,26 @@ +/* --------------------------------------------------------- */ +/* File: bootinfo.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: BootInfo?????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Information { + BootInfo::BootInfo(void) { + cyls = *((char *) (ADR_BOOTINFO + 0x00000000)); + leds = *((char *) (ADR_BOOTINFO + 0x00000001)); + vmode = *((char *) (ADR_BOOTINFO + 0x00000002)); + reserve = *((char *) (ADR_BOOTINFO + 0x00000003)); + scrnx = *((short *)(ADR_BOOTINFO + 0x00000004)); + scrny = *((short *)(ADR_BOOTINFO + 0x00000006)); + vram = (char *) *((int *)(ADR_BOOTINFO + 0x00000008)); + + return; + } +}; +}; +#endif Added: PhoeniOS/trunk/system/bootinfo.h =================================================================== --- PhoeniOS/trunk/system/bootinfo.h (rev 0) +++ PhoeniOS/trunk/system/bootinfo.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,26 @@ +/* --------------------------------------------------------- */ +/* File: bootinfo.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: BootInfo????? */ +/* --------------------------------------------------------- */ + +#define ADR_BOOTINFO 0x00001000 + +#ifdef __cplusplus +namespace System { +namespace Information { + class BootInfo { + public: + BootInfo(void); + char cyls; + char leds; + char vmode; + char reserve; + short scrnx; + short scrny; + char *vram; + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/color.cpp =================================================================== --- PhoeniOS/trunk/system/color.cpp (rev 0) +++ PhoeniOS/trunk/system/color.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,20 @@ +/* --------------------------------------------------------- */ +/* File: color.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????? */ +/* ???????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +#ifdef __cplusplus +namespace System { +namespace Graphic { + unsigned char Color::RGB24To8(unsigned char r,unsigned char g,unsigned char b) { + return ((r / 43) * 36) + ((g / 43) * 6) + (b / 43) + 16; + } +}; +}; +#endif Added: PhoeniOS/trunk/system/color.h =================================================================== --- PhoeniOS/trunk/system/color.h (rev 0) +++ PhoeniOS/trunk/system/color.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,18 @@ +/* --------------------------------------------------------- */ +/* File: color.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????? */ +/* ??????????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Color { + public: + static unsigned char RGB24To8(unsigned char r,unsigned char g,unsigned char b); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/descriptor.cpp =================================================================== --- PhoeniOS/trunk/system/descriptor.cpp (rev 0) +++ PhoeniOS/trunk/system/descriptor.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,65 @@ +/* --------------------------------------------------------- */ +/* File: descriptor.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: GDT,IDT?????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Descriptor { + void Descriptor::Initialize(void) { + struct SEGMENT_DESCRIPTOR *gdt = (struct SEGMENT_DESCRIPTOR *) ADR_GDT; + struct GATE_DESCRIPTOR *idt = (struct GATE_DESCRIPTOR *) ADR_IDT; + int i; + + /* GDT????*/ + for (i = 0; i <= LIMIT_GDT / 8; i++) { + Set_SegmentDescriptor(gdt + i, 0, 0, 0); + } + Set_SegmentDescriptor(gdt + 1, 0xffffffff, 0x00000000, AR_DATA32_RW); + Set_SegmentDescriptor(gdt + 2, LIMIT_KERNEL, ADR_KERNEL, AR_CODE32_ER); + load_gdtr(LIMIT_GDT, ADR_GDT); + + /* IDT????*/ + for (i = 0; i <= LIMIT_IDT / 8; i++) { + Set_GateDescriptor(idt + i, 0, 0, 0); + } + load_idtr(LIMIT_IDT, ADR_IDT); + + /* IDT??? */ + Set_GateDescriptor(idt + 0x21, (int) asm_inthandler21, 2 * 8, AR_INTGATE32); + Set_GateDescriptor(idt + 0x2c, (int) asm_inthandler2c, 2 * 8, AR_INTGATE32); + + return; + } + + void Descriptor::Set_SegmentDescriptor(struct SEGMENT_DESCRIPTOR *sd, unsigned int limit, int base, int ar) { + if (limit > 0xfffff) { + ar |= 0x8000; /* G_bit = 1 */ + limit /= 0x1000; + } + + sd->limit_low = limit & 0xffff; + sd->base_low = base & 0xffff; + sd->base_mid = (base >> 16) & 0xff; + sd->access_right = ar & 0xff; + sd->limit_high = ((limit >> 16) & 0xff) | ((ar >> 8) & 0xf0); + sd->base_high = (base >> 24) & 0x0f; + + return; + }; + + void Descriptor::Set_GateDescriptor(struct GATE_DESCRIPTOR *gd, int offset, int selector, int ar) { + gd->offset_low = offset & 0xffff; + gd->selector = selector; + gd->dw_count = (ar >> 8) & 0xff; + gd->access_right = ar & 0xff; + gd->offset_high = (offset >> 16) & 0xffff; + + return; + } +}; +}; Added: PhoeniOS/trunk/system/descriptor.h =================================================================== --- PhoeniOS/trunk/system/descriptor.h (rev 0) +++ PhoeniOS/trunk/system/descriptor.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,41 @@ +/* --------------------------------------------------------- */ +/* File: descriptor.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: GDT,IDT????????????? */ +/* --------------------------------------------------------- */ + +#define ADR_IDT 0x0026f800 +#define LIMIT_IDT 0x000007ff +#define ADR_GDT 0x00270000 +#define LIMIT_GDT 0x0000ffff +#define ADR_KERNEL 0x00280000 +#define LIMIT_KERNEL 0x0007ffff +#define AR_DATA32_RW 0x4092 +#define AR_CODE32_ER 0x409a +#define AR_INTGATE32 0x008e + +struct SEGMENT_DESCRIPTOR { + short limit_low, base_low; + char base_mid, access_right; + char limit_high, base_high; +}; +struct GATE_DESCRIPTOR { + short offset_low, selector; + char dw_count, access_right; + short offset_high; +}; + +#ifdef __cplusplus +namespace System { +namespace Descriptor { + class Descriptor { + public: + static void Initialize(void); + private: + static void Set_SegmentDescriptor(struct SEGMENT_DESCRIPTOR *sd, unsigned int limit, int base, int ar); + static void Set_GateDescriptor(struct GATE_DESCRIPTOR *gd, int offset, int selector, int ar); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/drawing.cpp =================================================================== --- PhoeniOS/trunk/system/drawing.cpp (rev 0) +++ PhoeniOS/trunk/system/drawing.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,57 @@ +/* --------------------------------------------------------- */ +/* File: drawing.cpp */ +/* Update: 2009/01/18 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Graphic { + void Drawing::FillRectangle_8(char *vram, int xsize, unsigned char c, int x0, int y0, int x1, int y1) + { + int x, y; + + for (y = y0; y <= y1; y++) + { + for (x = x0; x <= x1; x++) + { + vram[y * xsize + x] = c; + } + } + + return; + } + + void Drawing::PutFont(char *vram, int xsize, int x, int y, char c, char *font) { + int i; + char *p, d; + + for (i = 0; i < 16; i++) { + p = vram + (y + i) * xsize + x; + d = font[i]; + + if ((d & 0x80) != 0) { p[0] = c; } + if ((d & 0x40) != 0) { p[1] = c; } + if ((d & 0x20) != 0) { p[2] = c; } + if ((d & 0x10) != 0) { p[3] = c; } + if ((d & 0x08) != 0) { p[4] = c; } + if ((d & 0x04) != 0) { p[5] = c; } + if ((d & 0x02) != 0) { p[6] = c; } + if ((d & 0x01) != 0) { p[7] = c; } + } + + return; + } + + void Drawing::PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s) { + for (; *s != 0x00; s++) { + PutFont(vram, xsize, x, y, c, hankaku + *s * 16); + x += 8; + } + } +}; +}; Added: PhoeniOS/trunk/system/drawing.h =================================================================== --- PhoeniOS/trunk/system/drawing.h (rev 0) +++ PhoeniOS/trunk/system/drawing.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,28 @@ +/* --------------------------------------------------------- */ +/* File: drawing.cpp */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + extern char hankaku[4096]; +#ifdef __cplusplus +} +#endif + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Drawing { + public: + static void FillRectangle_8(char *vram, int xsize, unsigned char c, int x0, int y0, int x1, int y1); + static void PutFont(char *vram, int xsize, int x, int y, char c, char *font); + static void PutFonts(char *vram, int xsize, int x, int y, char c, unsigned char *s); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/fifo.cpp =================================================================== --- PhoeniOS/trunk/system/fifo.cpp (rev 0) +++ PhoeniOS/trunk/system/fifo.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,65 @@ +/* --------------------------------------------------------- */ +/* File: fifo.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?FIFO??????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +namespace System { +namespace FIFO { + void FIFO8::Initialize(int s, unsigned char *b) { + size = s; + buf = b; + free = s; + flags = 0; + p = 0; + q = 0; + + return; + } + + int FIFO8::Put(unsigned char d) { + if (free == 0) { + flags |= FLAGS_OVERRUN; + return -1; + } + + buf[p] = d; + p++; + + if (p == size) { + p = 0; + } + + free--; + + return 0; + } + + int FIFO8::Get(void) { + int data; + + if (free == size) { + return -1; + } + + data = buf[q]; + q++; + + if (q == size) { + q = 0; + } + + free++; + + return data; + } + + int FIFO8::Status(void) { + return size - free; + } +}; +}; Added: PhoeniOS/trunk/system/fifo.h =================================================================== --- PhoeniOS/trunk/system/fifo.h (rev 0) +++ PhoeniOS/trunk/system/fifo.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,30 @@ +/* --------------------------------------------------------- */ +/* File: fifo.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?FIFO??????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define FLAGS_OVERRUN 0x0001 + +#ifdef __cplusplus +namespace System { +namespace FIFO{ + class FIFO8 { + public: + void Initialize(int s, unsigned char *b); + int Put(unsigned char d); + int Get(void); + int Status(void); + + unsigned char *buf; + int p; + int q; + int size; + int free; + int flags; + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/hankaku.txt =================================================================== --- PhoeniOS/trunk/system/hankaku.txt (rev 0) +++ PhoeniOS/trunk/system/hankaku.txt 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,4607 @@ +char 0x00 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x01 +........ +........ +..***... +.*...*.. +*.....*. +*.*.*.*. +*.*.*.*. +*.....*. +*.....*. +*.*.*.*. +*..*..*. +.*...*.. +..***... +........ +........ +........ + +char 0x02 +........ +........ +..***... +.*****.. +*******. +**.*.**. +**.*.**. +*******. +*******. +**.*.**. +***.***. +.*****.. +..***... +........ +........ +........ + +char 0x03 +........ +........ +........ +........ +.**.**.. +*******. +*******. +*******. +.*****.. +..***... +...*.... +........ +........ +........ +........ +........ + +char 0x04 +........ +........ +........ +........ +...*.... +..***... +.*****.. +*******. +.*****.. +..***... +...*.... +........ +........ +........ +........ +........ + +char 0x05 +........ +........ +........ +........ +...*.... +..***... +.*.*.*.. +*******. +.*.*.*.. +...*.... +..***... +........ +........ +........ +........ +........ + +char 0x06 +........ +........ +........ +........ +...*.... +..***... +.*****.. +*******. +**.*.**. +...*.... +..***... +........ +........ +........ +........ +........ + +char 0x07 +........ +........ +........ +........ +........ +........ +...**... +..****.. +..****.. +...**... +........ +........ +........ +........ +........ +........ + +char 0x08 +******** +******** +******** +******** +******** +******** +***..*** +**....** +**....** +***..*** +******** +******** +******** +******** +******** +******** + +char 0x09 +........ +........ +........ +........ +........ +..****.. +.**..**. +.*....*. +.*....*. +.**..**. +..****.. +........ +........ +........ +........ +........ + +char 0x0a +******** +******** +******** +******** +******** +**....** +*..**..* +*.****.* +*.****.* +*..**..* +**....** +******** +******** +******** +******** +******** + +char 0x0b +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x0c +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +........ +........ + +char 0x0d +........ +........ +....**.. +....***. +....*.** +....*.** +....*.*. +....*... +....*... +...**... +.****... +*****... +.***.... +........ +........ +........ + +char 0x0e +........ +........ +...***** +...***** +...*...* +...*...* +...*...* +...*...* +...*...* +...*...* +.***.*** +******** +.**..**. +........ +........ +........ + +char 0x0f +........ +........ +........ +........ +...*.... +.*.*.*.. +..***... +..*.*... +..***... +.*.*.*.. +...*.... +........ +........ +........ +........ +........ + +char 0x10 +........ +*....... +**...... +***..... +****.... +*****... +******.. +*******. +******.. +*****... +****.... +***..... +**...... +*....... +........ +........ + +char 0x11 +........ +......*. +.....**. +....***. +...****. +..*****. +.******. +*******. +.******. +..*****. +...****. +....***. +.....**. +......*. +........ +........ + +char 0x12 +........ +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +........ +........ +........ + +char 0x13 +........ +........ +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +........ +........ +.*...*.. +.*...*.. +........ +........ + +char 0x14 +........ +..*****. +.*..*.*. +*...*.*. +*...*.*. +*...*.*. +*...*.*. +.*..*.*. +..***.*. +....*.*. +....*.*. +....*.*. +....*.*. +....*.*. +........ +........ + +char 0x15 +.*****.. +*.....*. +.*...... +..*..... +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +....*... +.....*.. +*.....*. +.*****.. +........ + +char 0x16 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +*******. +*******. +........ +........ + +char 0x17 +........ +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +.*****.. +........ +........ + +char 0x18 +........ +...*.... +..***... +.*.*.*.. +*..*..*. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x19 +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +*..*..*. +.*.*.*.. +..***... +...*.... +........ +........ + +char 0x1a +........ +........ +........ +........ +...*.... +....*... +.....*.. +*******. +.....*.. +....*... +...*.... +........ +........ +........ +........ +........ + +char 0x1b +........ +........ +........ +........ +...*.... +..*..... +.*...... +*******. +.*...... +..*..... +...*.... +........ +........ +........ +........ +........ + +char 0x1c +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*....... +*....... +*******. +........ +........ + +char 0x1d +........ +........ +........ +........ +........ +..*.*... +.*...*.. +*******. +.*...*.. +..*.*... +........ +........ +........ +........ +........ +........ + +char 0x1e +........ +........ +........ +........ +...*.... +...*.... +..***... +..***... +.*****.. +.*****.. +*******. +*******. +........ +........ +........ +........ + +char 0x1f +........ +........ +........ +........ +*******. +*******. +.*****.. +.*****.. +..***... +..***... +...*.... +...*.... +........ +........ +........ +........ + +char 0x20 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x21 +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ +...*.... +...*.... +........ +........ + +char 0x22 +..*.*... +..*.*... +..*.*... +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x23 +........ +.*...*.. +.*...*.. +.*...*.. +*******. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +.*...*.. +*******. +.*...*.. +.*...*.. +.*...*.. +........ +........ + +char 0x24 +...*.... +..***.*. +.*.*.**. +*..*..*. +*..*..*. +*..*.... +.*.*.... +..***... +...*.*.. +...*..*. +*..*..*. +*..*..*. +**.*.*.. +*.***... +...*.... +...*.... + +char 0x25 +.**...*. +*..*..*. +*..*.*.. +*..*.*.. +.**.*... +....*... +...*.... +...*.... +..*..... +..*.**.. +.*.*..*. +.*.*..*. +*..*..*. +*...**.. +........ +........ + +char 0x26 +........ +.***.... +*...*... +*...*... +*...*... +*..*.... +.**..... +.*...*** +*.*...*. +*..*..*. +*...*.*. +*....*.. +.*...**. +..***..* +........ +........ + +char 0x27 +.....*.. +....*... +...*.... +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x28 +......*. +.....*.. +....*... +....*... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +....*... +....*... +.....*.. +......*. +........ + +char 0x29 +*....... +.*...... +..*..... +..*..... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..*..... +..*..... +.*...... +*....... +........ + +char 0x2a +........ +........ +........ +........ +........ +...*.... +*..*..*. +.*.*.*.. +..***... +.*.*.*.. +*..*..*. +...*.... +........ +........ +........ +........ + +char 0x2b +........ +........ +........ +........ +........ +...*.... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +........ +........ +........ +........ + +char 0x2c +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +...**... +...**... +....*... +....*... +...*.... + +char 0x2d +........ +........ +........ +........ +........ +........ +........ +........ +*******. +........ +........ +........ +........ +........ +........ +........ + +char 0x2e +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +...**... +...**... +........ +........ + +char 0x2f +......*. +......*. +.....*.. +.....*.. +....*... +....*... +....*... +...*.... +...*.... +..*..... +..*..... +.*...... +.*...... +.*...... +*....... +*....... + +char 0x30 +........ +...**... +..*..*.. +..*..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +...**... +........ +........ + +char 0x31 +........ +....*... +...**... +..*.*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +....*... +..*****. +........ +........ + +char 0x32 +........ +...**... +..*..*.. +.*....*. +.*....*. +......*. +.....*.. +....*... +...*.... +..*..... +..*..... +.*...... +.*...... +.******. +........ +........ + +char 0x33 +........ +...**... +..*..*.. +.*....*. +......*. +......*. +.....*.. +...**... +.....*.. +......*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x34 +........ +....**.. +....**.. +....**.. +...*.*.. +...*.*.. +...*.*.. +..*..*.. +..*..*.. +.*...*.. +.******. +.....*.. +.....*.. +...****. +........ +........ + +char 0x35 +........ +.*****.. +.*...... +.*...... +.*...... +.*.**... +.**..*.. +......*. +......*. +......*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x36 +........ +...**... +..*..*.. +.*....*. +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x37 +........ +.******. +.*....*. +.*....*. +.....*.. +.....*.. +....*... +....*... +....*... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x38 +........ +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x39 +........ +...**... +..*..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..**. +...**.*. +......*. +.*....*. +..*..*.. +...**... +........ +........ + +char 0x3a +........ +........ +........ +........ +........ +...**... +...**... +........ +........ +........ +........ +........ +...**... +...**... +........ +........ + +char 0x3b +........ +........ +........ +........ +........ +...**... +...**... +........ +........ +........ +........ +...**... +...**... +....*... +....*... +...*.... + +char 0x3c +........ +......*. +.....*.. +....*... +...*.... +..*..... +.*...... +*....... +*....... +.*...... +..*..... +...*.... +....*... +.....*.. +......*. +........ + +char 0x3d +........ +........ +........ +........ +........ +........ +*******. +........ +........ +*******. +........ +........ +........ +........ +........ +........ + +char 0x3e +........ +*....... +.*...... +..*..... +...*.... +....*... +.....*.. +......*. +......*. +.....*.. +....*... +...*.... +..*..... +.*...... +*....... +........ + +char 0x3f +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +.....*.. +....*... +...*.... +...*.... +........ +........ +...**... +...**... +........ +........ + +char 0x40 +........ +..***... +.*...*.. +*.....*. +*..**.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*.*.*.*. +*..***.. +*....... +.*...**. +..***... +........ +........ + +char 0x41 +........ +...**... +...**... +...**... +...**... +..*..*.. +..*..*.. +..*..*.. +..*..*.. +.******. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x42 +........ +****.... +.*..*... +.*...*.. +.*...*.. +.*...*.. +.*..*... +.****... +.*...*.. +.*....*. +.*....*. +.*....*. +.*...*.. +*****... +........ +........ + +char 0x43 +........ +..***.*. +.*...**. +.*....*. +*.....*. +*....... +*....... +*....... +*....... +*....... +*.....*. +.*....*. +.*...*.. +..***... +........ +........ + +char 0x44 +........ +*****... +.*...*.. +.*...*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*...*.. +.*...*.. +*****... +........ +........ + +char 0x45 +........ +*******. +.*....*. +.*....*. +.*...... +.*...... +.*...*.. +.*****.. +.*...*.. +.*...... +.*...... +.*....*. +.*....*. +*******. +........ +........ + +char 0x46 +........ +*******. +.*....*. +.*....*. +.*...... +.*...... +.*...*.. +.*****.. +.*...*.. +.*...*.. +.*...... +.*...... +.*...... +****.... +........ +........ + +char 0x47 +........ +..***.*. +.*...**. +.*....*. +*.....*. +*....... +*....... +*..****. +*.....*. +*.....*. +*.....*. +.*....*. +.*...**. +..***... +........ +........ + +char 0x48 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.******. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x49 +........ +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x4a +........ +...***** +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +*....*.. +.*..*... +..**.... +........ + +char 0x4b +........ +***..*** +.*....*. +.*...*.. +.*..*... +.*.*.... +.*.*.... +.**..... +.*.*.... +.*.*.... +.*..*... +.*...*.. +.*....*. +***..*** +........ +........ + +char 0x4c +........ +****.... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*...... +.*....*. +.*....*. +*******. +........ +........ + +char 0x4d +........ +**....** +.*....*. +.**..**. +.**..**. +.**..**. +.*.**.*. +.*.**.*. +.*.**.*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x4e +........ +**...*** +.*....*. +.**...*. +.**...*. +.*.*..*. +.*.*..*. +.*.*..*. +.*..*.*. +.*..*.*. +.*..*.*. +.*...**. +.*...**. +***...*. +........ +........ + +char 0x4f +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x50 +........ +*****... +.*...*.. +.*....*. +.*....*. +.*....*. +.*...*.. +.****... +.*...... +.*...... +.*...... +.*...... +.*...... +****.... +........ +........ + +char 0x51 +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*..*..*. +*...*.*. +.*...*.. +..***.*. +........ +........ + +char 0x52 +........ +******.. +.*....*. +.*....*. +.*....*. +.*....*. +.*****.. +.*...*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x53 +........ +..***.*. +.*...**. +*.....*. +*.....*. +*....... +.*...... +..***... +.....*.. +......*. +*.....*. +*.....*. +**...*.. +*.***... +........ +........ + +char 0x54 +........ +*******. +*..*..*. +*..*..*. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x55 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..****.. +........ +........ + +char 0x56 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +...**... +...**... +........ +........ + +char 0x57 +........ +***..*** +.*....*. +.*....*. +.*....*. +.*.**.*. +.*.**.*. +.*.**.*. +.*.**.*. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +..*..*.. +........ +........ + +char 0x58 +........ +***..*** +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +..*..*.. +..*..*.. +..*..*.. +.*....*. +.*....*. +***..*** +........ +........ + +char 0x59 +........ +***.***. +.*...*.. +.*...*.. +.*...*.. +..*.*... +..*.*... +..*.*... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x5a +........ +*******. +*....*.. +*....*.. +....*... +....*... +...*.... +...*.... +..*..... +..*..... +.*...... +.*....*. +*.....*. +*******. +........ +........ + +char 0x5b +........ +..*****. +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*..... +..*****. +........ + +char 0x5c +*....... +*....... +.*...... +.*...... +..*..... +..*..... +..*..... +...*.... +...*.... +....*... +....*... +.....*.. +.....*.. +.....*.. +......*. +......*. + +char 0x5d +........ +.*****.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.*****.. +........ + +char 0x5e +........ +...*.... +..*.*... +.*...*.. +*.....*. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x5f +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +........ + +char 0x60 +...*.... +....*... +.....*.. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x61 +........ +........ +........ +........ +........ +.***.... +....*... +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +*...**.. +.***.**. +........ +........ + +char 0x62 +**...... +.*...... +.*...... +.*...... +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.**..*.. +.*.**... +........ +........ + +char 0x63 +........ +........ +........ +........ +........ +..**.... +.*..**.. +*....*.. +*....*.. +*....... +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x64 +....**.. +.....*.. +.....*.. +.....*.. +.....*.. +..**.*.. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.**. +........ +........ + +char 0x65 +........ +........ +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +******.. +*....... +*.....*. +.*....*. +..****.. +........ +........ + +char 0x66 +....***. +...*.... +...*.... +...*.... +...*.... +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +.*****.. +........ +........ + +char 0x67 +........ +........ +........ +........ +........ +..**.**. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.*.. +.....*.. +.....*.. +.****... + +char 0x68 +**...... +.*...... +.*...... +.*...... +.*...... +.*.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***...** +........ +........ + +char 0x69 +........ +...*.... +...*.... +........ +........ +..**.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x6a +........ +.....*.. +.....*.. +........ +........ +....**.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +.....*.. +....*... +....*... +..**.... + +char 0x6b +**...... +.*...... +.*...... +.*...... +.*...... +.*..***. +.*...*.. +.*..*... +.*.*.... +.**..... +.*.*.... +.*..*... +.*...*.. +***..**. +........ +........ + +char 0x6c +..**.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +..***... +........ +........ + +char 0x6d +........ +........ +........ +........ +........ +****.**. +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +.*..*..* +**.**.** +........ +........ + +char 0x6e +........ +........ +........ +........ +........ +**.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +***...** +........ +........ + +char 0x6f +........ +........ +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x70 +........ +........ +........ +........ +........ +**.**... +.**..*.. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.**..*.. +.*.**... +.*...... +***..... + +char 0x71 +........ +........ +........ +........ +........ +..**.*.. +.*..**.. +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +.*..**.. +..**.*.. +.....*.. +....***. + +char 0x72 +........ +........ +........ +........ +........ +**.***.. +.**...*. +.*....*. +.*...... +.*...... +.*...... +.*...... +.*...... +***..... +........ +........ + +char 0x73 +........ +........ +........ +........ +........ +.****.*. +*....**. +*.....*. +**...... +..***... +.....**. +*.....*. +**....*. +*.****.. +........ +........ + +char 0x74 +........ +........ +...*.... +...*.... +...*.... +.*****.. +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +....***. +........ +........ + +char 0x75 +........ +........ +........ +........ +........ +**...**. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*....*. +.*...**. +..***.** +........ +........ + +char 0x76 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +........ +........ + +char 0x77 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +.*.**.*. +.*.**.*. +.*.**.*. +..*..*.. +..*..*.. +..*..*.. +........ +........ + +char 0x78 +........ +........ +........ +........ +........ +**...**. +.*...*.. +..*.*... +..*.*... +...*.... +..*.*... +..*.*... +.*...*.. +**...**. +........ +........ + +char 0x79 +........ +........ +........ +........ +........ +***..*** +.*....*. +.*....*. +..*..*.. +..*..*.. +..*..*.. +...**... +...**... +...*.... +...*.... +.**..... + +char 0x7a +........ +........ +........ +........ +........ +*******. +*.....*. +*....*.. +....*... +...*.... +..*..... +.*....*. +*.....*. +*******. +........ +........ + +char 0x7b +........ +.....**. +....*... +...*.... +...*.... +...*.... +...*.... +.**..... +...*.... +...*.... +...*.... +...*.... +....*... +.....**. +........ +........ + +char 0x7c +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0x7d +........ +.**..... +...*.... +....*... +....*... +....*... +....*... +.....**. +....*... +....*... +....*... +....*... +...*.... +.**..... +........ +........ + +char 0x7e +........ +.***..*. +*...**.. +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0x7f +........ +........ +........ +........ +...*.... +..*.*... +.*...*.. +*.....*. +*******. +*.....*. +*******. +........ +........ +........ +........ +........ + +char 0x80 +........ +..***... +.*...*.. +*.....*. +*....... +*....... +*....... +*....... +*....... +*....... +*....... +*.....*. +.*...*.. +..***... +...*.... +..*..... + +char 0x81 +........ +........ +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x82 +....**.. +....*... +...*.... +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x83 +........ +...*.... +..*.*... +.*...*.. +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x84 +........ +........ +..*..*.. +..*..*.. +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x85 +...*.... +....*... +.....*.. +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x86 +........ +...**... +..*..*.. +...**... +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0x87 +........ +........ +........ +........ +........ +..****.. +.*....*. +*....... +*....... +*....... +*....... +*....... +.*....*. +..****.. +....*... +...*.... + +char 0x88 +........ +...*.... +..*.*... +.*...*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x89 +........ +........ +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x8a +...*.... +....*... +.....*.. +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*******. +*....... +*.....*. +.*...*.. +..***... +........ +........ + +char 0x8b +........ +........ +..*..*.. +..*..*.. +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8c +........ +...*.... +..*.*... +.*...*.. +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8d +...*.... +....*... +.....*.. +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x8e +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*******. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0x8f +........ +..***... +.*...*.. +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*******. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0x90 +....**.. +....*... +...*.... +*******. +*....... +*....... +*....... +*....... +*****... +*....... +*....... +*....... +*....... +*******. +........ +........ + +char 0x91 +........ +........ +........ +........ +........ +.**..... +...***.. +...*..*. +.***..*. +*..****. +*..*.... +*..*.... +*..*..*. +.**.**.. +........ +........ + +char 0x92 +....**.. +...*.... +..*..... +..*.*... +..*.*... +..*.*... +*******. +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +..*.*... +........ +........ + +char 0x93 +........ +...*.... +..*.*... +.*...*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x94 +........ +........ +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x95 +...*.... +....*... +.....*.. +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x96 +........ +...*.... +..*.*... +.*...*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x97 +...*.... +....*... +.....*.. +........ +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0x98 +........ +........ +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +.*...*.. +.*...*.. +..*.*... +..*.*... +...*.... +...*.... +..*..... +..*..... +.*...... + +char 0x99 +..*..*.. +..*..*.. +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x9a +..*..*.. +..*..*.. +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0x9b +........ +..*.*... +..*.*... +..*.*... +..****.. +.**.*.*. +*.*.*... +*.*.*... +*.*.*... +*.*.*... +*.*.*... +.**.*.*. +..****.. +..*.*... +..*.*... +..*.*... + +char 0x9c +........ +....**.. +...*..*. +..*..... +..*..... +..*..... +******.. +..*..... +..*..... +..*..... +.**..... +*.*..... +*.**..*. +.*..**.. +........ +........ + +char 0x9d +........ +*.....*. +*.....*. +.*...*.. +..*.*... +...*.... +*******. +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0x9e +........ +***..... +*..*.... +*...*... +*...*... +*...*... +*..*.*.. +***..*.. +*..***** +*....*.. +*....*.. +*....*.. +*....*.. +*....*.. +........ +........ + +char 0x9f +........ +....**.. +...*..*. +...*.... +...*.... +...*.... +*******. +...*.... +...*.... +...*.... +...*.... +...*.... +*..*.... +.**..... +........ +........ + +char 0xa0 +....**.. +....*... +...*.... +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +........ + +char 0xa1 +....**.. +....*... +...*.... +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0xa2 +....**.. +....*... +...*.... +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0xa3 +....**.. +....*... +...*.... +........ +........ +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*....*. +..*****. +........ +........ + +char 0xa4 +........ +...*..*. +..*.*.*. +..*..*.. +........ +*****... +*....*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +........ +........ + +char 0xa5 +...*..*. +..*.*.*. +..*..*.. +........ +*.....*. +**....*. +**....*. +*.*...*. +*..*..*. +*..*..*. +*...*.*. +*....**. +*....**. +*.....*. +........ +........ + +char 0xa6 +........ +........ +........ +.****... +.....*.. +.....*.. +..****.. +.*...*.. +*....*.. +*....*.. +.*...*.. +..*****. +........ +*******. +........ +........ + +char 0xa7 +........ +........ +........ +..***... +.*...*.. +*.....*. +*.....*. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +*******. +........ +........ + +char 0xa8 +........ +...*.... +...*.... +........ +........ +...*.... +...*.... +..*..... +.*...*.. +*.....*. +*.....*. +*.....*. +.*...*.. +..***... +........ +........ + +char 0xa9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +*....... +*....... +*....... +........ +........ + +char 0xaa +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +*******. +......*. +......*. +......*. +........ +........ + +char 0xab +........ +...*.... +..**.... +...*.... +...*.... +...*.... +........ +*******. +........ +.****... +.....*.. +..***... +.*...... +.*****.. +........ +........ + +char 0xac +........ +...*.... +..**.... +...*.... +...*.... +...*.... +........ +*******. +........ +...**... +..*.*... +.*..*... +.*****.. +....*... +........ +........ + +char 0xad +........ +...*.... +...*.... +........ +........ +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +........ +........ + +char 0xae +........ +........ +........ +........ +...*..*. +..*..*.. +.*..*... +*..*.... +*..*.... +.*..*... +..*..*.. +...*..*. +........ +........ +........ +........ + +char 0xaf +........ +........ +........ +........ +*..*.... +.*..*... +..*..*.. +...*..*. +...*..*. +..*..*.. +.*..*... +*..*.... +........ +........ +........ +........ + +char 0xb0 +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. +...*...* +.*...*.. + +char 0xb1 +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. +.*.*.*.* +*.*.*.*. + +char 0xb2 +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* +.***.*** +**.***.* + +char 0xb3 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb4 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb5 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb6 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xb7 +........ +........ +........ +........ +........ +........ +........ +******.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xb8 +........ +........ +........ +........ +........ +........ +........ +****.... +...*.... +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xb9 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +.....*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xba +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xbb +........ +........ +........ +........ +........ +........ +........ +******.. +.....*.. +****.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xbc +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*.. +.....*.. +******.. +........ +........ +........ +........ +........ +........ + +char 0xbd +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +******.. +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xbe +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +...*.... +****.... +........ +........ +........ +........ +........ +........ + +char 0xbf +........ +........ +........ +........ +........ +........ +........ +****.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc0 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc1 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc2 +........ +........ +........ +........ +........ +........ +........ +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc3 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc4 +........ +........ +........ +........ +........ +........ +........ +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xc5 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc6 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xc7 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xc8 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.... +...***** +........ +........ +........ +........ +........ +........ + +char 0xc9 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xca +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xcb +........ +........ +........ +........ +........ +........ +........ +******** +........ +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcc +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*** +...*.... +...*.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcd +........ +........ +........ +........ +........ +........ +........ +******** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xce +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +........ +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xcf +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +........ +******** +........ +........ +........ +........ +........ +........ + +char 0xd0 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xd1 +........ +........ +........ +........ +........ +........ +........ +******** +........ +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd2 +........ +........ +........ +........ +........ +........ +........ +******** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd3 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...***** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xd4 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...***** +...*.... +...***** +........ +........ +........ +........ +........ +........ + +char 0xd5 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd6 +........ +........ +........ +........ +........ +........ +........ +...***** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd7 +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +****.*** +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. +...*.*.. + +char 0xd8 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +******** +...*.... +******** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xd9 +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +****.... +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xda +........ +........ +........ +........ +........ +........ +........ +...***** +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... +...*.... + +char 0xdb +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** +******** + +char 0xdc +........ +........ +........ +........ +........ +........ +........ +........ +******** +******** +******** +******** +******** +******** +******** +******** + +char 0xdd +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... +****.... + +char 0xde +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** +....**** + +char 0xdf +******** +******** +******** +******** +******** +******** +******** +******** +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe0 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe1 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe2 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe3 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe4 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe5 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe6 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe7 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe8 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xe9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xea +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xeb +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xec +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xed +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xee +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xef +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf0 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf1 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf2 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf3 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf4 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf5 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf6 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf7 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf8 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xf9 +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfa +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfb +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfc +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfd +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xfe +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ + +char 0xff +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ +........ Added: PhoeniOS/trunk/system/int.cpp =================================================================== --- PhoeniOS/trunk/system/int.cpp (rev 0) +++ PhoeniOS/trunk/system/int.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,59 @@ +/* --------------------------------------------------------- */ +/* File: int.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +extern System::FIFO::FIFO8 keyfifo; + +using namespace System::Graphic; +using namespace System::Information; + +namespace System { +namespace Interrupt { + void PIC::Initialize(void) { + io_out8(PIC0_IMR, 0xff); /* ?????????????? */ + io_out8(PIC1_IMR, 0xff); /* ?????????????? */ + + io_out8(PIC0_ICW1, 0x11); /* ????????? */ + io_out8(PIC0_ICW2, 0x20); /* IRQ0-7?, INT20-27???? */ + io_out8(PIC0_ICW3, 1 << 2); /* PIC1?IRQ2???? */ + io_out8(PIC0_ICW4, 0x01); /* ????????? */ + + io_out8(PIC1_ICW1, 0x11); /* ????????? */ + io_out8(PIC1_ICW2, 0x28); /* IRQ8-15?, INT28-2f???? */ + io_out8(PIC1_ICW3, 2); /* PIC1?IRQ2???? */ + io_out8(PIC1_ICW4, 0x01); /* ????????? */ + + io_out8(PIC0_IMR, 0xfb); /* 11111011 PIC1?????????????? */ + io_out8(PIC1_IMR, 0xff); /* 11111111 ?????????? */ + + return; + } + + /* PS/2???????????? */ + void Handlers::Handler21(int *esp) { + unsigned char data; + io_out8(PIC0_OCW2, 0x61); /* IRQ-01?????PIC??? */ + data = io_in8(PORT_KEYDAT); + keyfifo.Put(data); + return; + } + + /* PS/2?????????? */ + void Handlers::Handler2c(int *esp) { + BootInfo binfo; + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 0, 0), 0, 0, 32 * 8 - 1, 15); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 0, 0, Color::RGB24To8(255, 255, 255), (unsigned char *) "INT 2C (IRQ-12) : PS/2 Mouse"); + + for (;;) { + io_hlt(); + } + } +}; +}; Added: PhoeniOS/trunk/system/int.h =================================================================== --- PhoeniOS/trunk/system/int.h (rev 0) +++ PhoeniOS/trunk/system/int.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,42 @@ +/* --------------------------------------------------------- */ +/* File: int.h */ +/* Update: 2009/03/02 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????W? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define PIC0_IMR 0x0021 +#define PIC0_ICW1 0x0020 +#define PIC0_ICW2 0x0021 +#define PIC0_ICW3 0x0021 +#define PIC0_ICW4 0x0021 +#define PIC0_OCW1 0x0021 +#define PIC0_OCW2 0x0020 +#define PIC0_OCW3 0x0020 +#define PIC1_IMR 0x00a1 +#define PIC1_ICW1 0x00a0 +#define PIC1_ICW2 0x00a1 +#define PIC1_ICW3 0x00a1 +#define PIC1_ICW4 0x00a1 +#define PIC1_OCW1 0x00a1 +#define PIC1_OCW2 0x00a0 +#define PIC1_OCW3 0x00a0 +#define PORT_KEYDAT 0x0060 + +#ifdef __cplusplus +namespace System { +namespace Interrupt { + class PIC { + public: + static void Initialize(void); + }; + + class Handlers { + public: + static void Handler21(int *esp); + static void Handler2c(int *esp); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/ipl.bin =================================================================== (Binary files differ) Property changes on: PhoeniOS/trunk/system/ipl.bin ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Added: PhoeniOS/trunk/system/ipl.nas =================================================================== --- PhoeniOS/trunk/system/ipl.nas (rev 0) +++ PhoeniOS/trunk/system/ipl.nas 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,175 @@ +; --------------------------------------------------------- +; File: ipl.nas +; Version: 1.1.0 +; Update: 2008/11/16 +; License: GNU General Public License v3 +; Description: PhoeniOS?IPL?? +; CYLS????????????????? +; ???????OS???????? +; --------------------------------------------------------- + +CYLS EQU 10 ; ????????? (30??????) + + ORG 0x7c00 ; IPL????????????? + +; ?????I?FAT12?????????????????????+ + JMP entry + DB 0x90 + DB "PhoeniOS" ; ????????? + DW 512 ; 1??????? (??,512Bytes) + DB 1 ; ???????? (??,1Sector) + DW 1 ; FAT??????? (??,1Sector) + DB 2 ; FAT?? (??,2) + DW 224 ; ??????????????? (??,224Entries) + DW 2880 ; ?????????? (??,2880Sectors) + DB 0xf0 ; ???????? (??,0xf0) + DW 9 ; FAT????? (??,9Sectors) + DW 18 ; 1???????????? (??,18Sectors) + DW 2 ; ????? (??,2Heads) + DD 0 ; ???????????????? (??,0) + DD 2880 ; ?????????? (FAT32?) (??,0) + DB 0,0 ; ?? + DB 0x29 ; ?????? (??,0x29) + DD 0xffffffff ; ??????????? + DB "PhoeniOS " ; ???????? + DB "FAT12 " ; ????????? + RESB 18 ; 18?????? + +; ??????? + +entry: + MOV AX,0 ; ???????+ MOV SS,AX + MOV SP,0x7c00 + MOV DS,AX + + CALL put_line + MOV SI,msg_title + CALL put_msg + CALL put_line + +; ??????? + + MOV SI,msg_loading + CALL put_msg + + MOV AX,0x0820 + MOV ES,AX + MOV CH,0 ; ?????0??? + MOV DH,0 ; ????0??? + MOV CL,2 ; ????2??? + +readloop: + MOV SI,0 ; ޏ???????????????+ +retry: + MOV AH,0x02 ; ?????????????? + MOV AL,1 ; 1????????? + MOV BX,0 + MOV DL,0x00 ; A????????? + INT 0x13 ; ????BIOS??????????+ JNC next ; ??????????Next? + ADD SI,1 ; ޏ????1??? + CMP SI,5 + JAE error ; ޏ????5??????Error? + MOV AH,0x00 + MOV DL,0x00 ; A????????? + INT 0x13 ; ????????? + JMP retry + +next: + MOV AX,ES ; ?????0x200??? + ADD AX,0x0020 + MOV ES,AX + ADD CL,1 ; ????1??? + CMP CL,18 + JBE readloop ; ????18?????,Readloop? + MOV CL,1 ; ????1??? + ADD DH,1 ; ????1??? + CMP DH,2 + JB readloop ; ????2???????+ MOV DH,0 ; ????0??? + ADD CH,1 ; ?????1??? + + ; ?????????ަ + PUSH AX + MOV AL,'*' + MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ POP AX + + CMP CH,CYLS + JB readloop ; ?????CYLS???????+ + MOV SI,msg_complete + CALL put_msg + + ; phoenios.sys?ŽÀ? + MOV [0x1000],CH ; BOOTINFO - ?????????? + JMP 0xc200 ; phoenios.sys?ŽÀ? + +fin: + HLT + JMP fin + +error: + MOV AX,0 + MOV ES,AX + MOV SI,msg_load_error + CALL put_msg + JMP fin + +put_msg: + MOV AL,[SI] + ADD SI,1 ; ???????1??? + CMP AL,0 + JE .fin ; ???0?????+ MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ JMP put_msg +.fin: + RET + +put_line: + MOV CX,0 +.next: + MOV AL,'-' + MOV AH,0x0e ; ????ަ?? + MOV BX,15 ; ?????? + INT 0x10 ; ???BIOS????+ ADD CX,1 + CMP CX,51 + JB .next + RET + +msg_title: + DB 0x0d, 0x0a + DB " PhoeniOS IPL Version:1.1.0", 0x0d, 0x0a + DB " Copyright (C) 2008 Lite Systems.", 0x0d, 0x0a + DB " Licensed under the GNU General Public License v3.", 0x0d, 0x0a + DB 0 + +msg_loading: + DB 0x0d, 0x0a + DB 0x0d, 0x0a + DB "Loading..." + DB 0x0d, 0x0a + DB 0 + +msg_complete: + DB 0x0d, 0x0a + DB "Complete." + DB 0x0d, 0x0a + DB 0 + +msg_load_error: + DB "Load error." + DB 0x0d, 0x0a ; ?? + DB 0 + + RESB 0x7dfe-$ ; 0x7dfe?0???? + + DB 0x55, 0xaa Added: PhoeniOS/trunk/system/main.cpp =================================================================== --- PhoeniOS/trunk/system/main.cpp (rev 0) +++ PhoeniOS/trunk/system/main.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,63 @@ +/* --------------------------------------------------------- */ +/* File: main.cpp */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +extern "C" { + void Main(void); +}; + +using namespace System::Descriptor; +using namespace System::FIFO; +using namespace System::Graphic; +using namespace System::Information; +using namespace System::Interrupt; +using namespace System::Mouse; + +FIFO8 keyfifo; +unsigned char keybuf[32]; + +void Main(void) +{ + BootInfo binfo; + char s[40], mcursor[256]; + int mx, my, i; + + Descriptor::Initialize(); + PIC::Initialize(); + + io_sti(); + + Palette::Initialize(); + Background::Draw(); + + mx = (binfo.scrnx - 16) / 2; + my = (binfo.scrny - 28 - 16) / 2; + Cursor::Initialize(mcursor, Color::RGB24To8(0, 64, 128)); + Cursor::PutBlock_8(binfo.vram, binfo.scrnx, 16, 16, mx, my, mcursor, 16); + sprintf(s, "CursorPosition:(%d, %d)", mx, my); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 48, COL8_FFFFFF, (unsigned char *) s); + + keyfifo.Initialize(32, keybuf); + + io_out8(PIC0_IMR, 0xf9); /* PIC1?????????(11111001) */ + io_out8(PIC1_IMR, 0xef); /* ??????(11101111) */ + + for (;;) { + io_cli(); + if (keyfifo.Status() == 0) { + io_stihlt(); + } else { + i = keyfifo.Get(); + io_sti(); + sprintf(s, "%02X", i); + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 8, 72, 23, 87); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 72, Color::RGB24To8(255, 255, 255), (unsigned char *) s); + } + } +} Added: PhoeniOS/trunk/system/make.bat =================================================================== --- PhoeniOS/trunk/system/make.bat (rev 0) +++ PhoeniOS/trunk/system/make.bat 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1 @@ +..\z_tools\make.exe %1 %2 %3 %4 %5 %6 %7 %8 %9 \ No newline at end of file Added: PhoeniOS/trunk/system/mouse.cpp =================================================================== --- PhoeniOS/trunk/system/mouse.cpp (rev 0) +++ PhoeniOS/trunk/system/mouse.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,93 @@ +/* --------------------------------------------------------- */ +/* File: mouse.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +namespace System { +namespace Mouse { + void Cursor::Initialize(char *mouse, char bc) { + static char cursor[16][17] = { + //"*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OOOOOOOO*......", + "*OOOOO****......", + "*OO*OO*.........", + "*O*.*OO*........", + "**..*OO*........", + "....*OO*........", + ".....*OO*.......", + "......**........" + }; + /*static char cursor[16][17] = { + "*...............", + "**..............", + "*O*.............", + "*OO*............", + "*OOO*...........", + "*OOOO*..........", + "*OOOOO*.........", + "*OOOOOO*........", + "*OOOOOOO*.......", + "*OO*O****.......", + "*O**O*..........", + "**..*O*.........", + "*...*O*.........", + ".....*O*........", + ".....*O*........", + "......**........" + };*/ + int x, y; + + for (y = 0; y < 16; y++) { + for (x = 0; x < 16; x++) { + if (cursor[y][x] == '*') { + mouse[y * 16 + x] = COL8_000000; + } + if (cursor[y][x] == 'O') { + mouse[y * 16 + x] = COL8_FFFFFF; + } + if (cursor[y][x] == '.') { + mouse[y * 16 + x] = bc; + } + } + } + + return; + } + + void Cursor::PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize) { + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; + } +}; +}; + + +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize) +{ + int x, y; + for (y = 0; y < pysize; y++) { + for (x = 0; x < pxsize; x++) { + vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; + } + } + return; +} Added: PhoeniOS/trunk/system/mouse.h =================================================================== --- PhoeniOS/trunk/system/mouse.h (rev 0) +++ PhoeniOS/trunk/system/mouse.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,29 @@ +/* --------------------------------------------------------- */ +/* File: mouse.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS??????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +namespace System { +namespace Mouse { + class Cursor { + public: + static void Initialize(char *cursor, char bc); + static void PutBlock_8(char *vram, int vxsize, int pxsize, int pysize, int px0, int py0, char *buf, int bxsize); + }; +}; +}; +#endif + +#ifdef __cplusplus +extern "C" { +#endif +void init_mouse_cursor8(char *mouse, char bc); +void putblock8_8(char *vram, int vxsize, int pxsize, + int pysize, int px0, int py0, char *buf, int bxsize); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_dsc.h =================================================================== --- PhoeniOS/trunk/system/nask_dsc.h (rev 0) +++ PhoeniOS/trunk/system/nask_dsc.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_dsc.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?GDT,IDT???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void load_gdtr(int limit, int addr); + void load_idtr(int limit, int addr); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_dsc.nas =================================================================== --- PhoeniOS/trunk/system/nask_dsc.nas (rev 0) +++ PhoeniOS/trunk/system/nask_dsc.nas 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,27 @@ +; --------------------------------------------------------- +; File: nask_dsc.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS?GDT,IDT???NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_dsc.nas"] + + GLOBAL _load_gdtr, _load_idtr + +[SECTION .text] + +_load_gdtr: ; void load_gdtr(int limit, int addr); + MOV AX,[ESP+4] ; limit + MOV [ESP+6],AX + LGDT [ESP+6] + RET + +_load_idtr: ; void load_idtr(int limit, int addr); + MOV AX,[ESP+4] ; limit + MOV [ESP+6],AX + LIDT [ESP+6] + RET Added: PhoeniOS/trunk/system/nask_int.h =================================================================== --- PhoeniOS/trunk/system/nask_int.h (rev 0) +++ PhoeniOS/trunk/system/nask_int.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,15 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void asm_inthandler21(void); + void asm_inthandler2c(void); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_int.nas =================================================================== --- PhoeniOS/trunk/system/nask_int.nas (rev 0) +++ PhoeniOS/trunk/system/nask_int.nas 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,49 @@ +; --------------------------------------------------------- +; File: nask_int.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS????????NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_int.nas"] + + GLOBAL _asm_inthandler21, _asm_inthandler2c + EXTERN __ZN6System9Interrupt8Handlers9Handler21EPi + EXTERN __ZN6System9Interrupt8Handlers9Handler2cEPi + +[SECTION .text] + +_asm_inthandler21: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler21EPi + POP EAX + POPAD + POP DS + POP ES + IRETD + +_asm_inthandler2c: + PUSH ES + PUSH DS + PUSHAD + MOV EAX,ESP + PUSH EAX + MOV AX,SS + MOV DS,AX + MOV ES,AX + CALL __ZN6System9Interrupt8Handlers9Handler2cEPi + POP EAX + POPAD + POP DS + POP ES + IRETD Added: PhoeniOS/trunk/system/nask_io.h =================================================================== --- PhoeniOS/trunk/system/nask_io.h (rev 0) +++ PhoeniOS/trunk/system/nask_io.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,21 @@ +/* --------------------------------------------------------- */ +/* File: nask_io.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS?IO???NASK???????? */ +/* --------------------------------------------------------- */ + +#ifdef __cplusplus +extern "C" { +#endif + void io_hlt(void); + void io_cli(void); + void io_sti(void); + void io_stihlt(void); + int io_in8(int port); + void io_out8(int port, int data); + int io_load_eflags(void); + void io_store_eflags(int eflags); +#ifdef __cplusplus +}; +#endif Added: PhoeniOS/trunk/system/nask_io.nas =================================================================== --- PhoeniOS/trunk/system/nask_io.nas (rev 0) +++ PhoeniOS/trunk/system/nask_io.nas 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,81 @@ +; --------------------------------------------------------- +; File: nask_io.nas +; Update: 2009/03/01 +; License: GNU General Public License v3 +; Description: PhoeniOS?IO???NASK????? +; --------------------------------------------------------- + +[FORMAT "WCOFF"] +[INSTRSET "i486p"] +[BITS 32] +[FILE "nask_io.nas"] + + GLOBAL _io_hlt, _io_cli, _io_sti, _io_stihlt + GLOBAL _io_in8, _io_in16, _io_in32 + GLOBAL _io_out8, _io_out16, _io_out32 + GLOBAL _io_load_eflags, _io_store_eflags + +[SECTION .text] + +_io_hlt: ; void io_hlt(void); + HLT + RET + +_io_cli: ; void io_cli(void); + CLI + RET + +_io_sti: ; void io_sti(void); + STI + RET + +_io_stihlt: ; void io_stihlt(void); + STI + HLT + RET + +_io_in8: ; int io_in8(int port); + MOV EDX,[ESP+4] ; port + MOV EAX,0 + IN AL,DX + RET + +_io_in16: ; int io_in16(int port); + MOV EDX,[ESP+4] ; port + MOV EAX,0 + IN AX,DX + RET + +_io_in32: ; int io_in32(int port); + MOV EDX,[ESP+4] ; port + IN EAX,DX + RET + +_io_out8: ; void io_out8(int port, int data); + MOV EDX,[ESP+4] ; port + MOV AL,[ESP+8] ; data + OUT DX,AL + RET + +_io_out16: ; void io_out16(int port, int data); + MOV EDX,[ESP+4] ; port + MOV EAX,[ESP+8] ; data + OUT DX,AX + RET + +_io_out32: ; void io_out32(int port, int data); + MOV EDX,[ESP+4] ; port + MOV EAX,[ESP+8] ; data + OUT DX,EAX + RET + +_io_load_eflags: ; int io_load_eflags(void); + PUSHFD + POP EAX + RET + +_io_store_eflags: ; void io_store_eflags(int eflags); + MOV EAX,[ESP+4] + PUSH EAX + POPFD + RET Added: PhoeniOS/trunk/system/palette.cpp =================================================================== --- PhoeniOS/trunk/system/palette.cpp (rev 0) +++ PhoeniOS/trunk/system/palette.cpp 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,73 @@ +/* --------------------------------------------------------- */ +/* File: palette.cpp */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include +#include "phoenios.h" + +namespace System { +namespace Graphic { + void Palette::Initialize(void) { + static unsigned char table_rgb[16 * 3] = { /* ??????? */ + 0x00, 0x00, 0x00, /* 0:? */ + 0xff, 0x00, 0x00, /* 1:???? */ + 0x00, 0xff, 0x00, /* 2:???? */ + 0xff, 0xff, 0x00, /* 3:????? */ + 0x00, 0x00, 0xff, /* 4:???? */ + 0xff, 0x00, 0xff, /* 5:???? */ + 0x00, 0xff, 0xff, /* 6:????? */ + 0xff, 0xff, 0xff, /* 7:? */ + 0xc6, 0xc6, 0xc6, /* 8:????? */ + 0x84, 0x00, 0x00, /* 9:??? */ + 0x00, 0x84, 0x00, /* 10:??? */ + 0x84, 0x84, 0x00, /* 11:???? */ + 0x00, 0x00, 0x84, /* 12:??? */ + 0x84, 0x00, 0x84, /* 13:??? */ + 0x00, 0x84, 0x84, /* 14:???? */ + 0x84, 0x84, 0x84 /* 15:???? */ + }; + unsigned char table_rgb_216[216 * 3]; + int r, g, b; + + Set_Palette(0, 15, table_rgb); /* ??????????????? */ + + for (r = 0; r < 6; r++) { /* 216????????*/ + for (g = 0; g < 6; g++) { + for (b = 0; b < 6; b++) { + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 0] = r * 51; + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 1] = g * 51; + table_rgb_216[(r * 36 + g * 6 + b) * 3 + 2] = b * 51; + } + } + } + + Set_Palette(16, 231, table_rgb_216); /* 216???????????? */ + + return; + } + + void Palette::Set_Palette(int start, int end, unsigned char *rgb) { + int eflags; + + eflags = io_load_eflags(); /* ?????????????? */ + io_cli(); /* ??????? */ + + io_out8(0x03c8, start); /* ?????????????? */ + + for (int i = start; i <= end; i++) { + io_out8(0x03c9, rgb[0] / 4); /* ?????R??? */ + io_out8(0x03c9, rgb[1] / 4); /* ?????G??? */ + io_out8(0x03c9, rgb[2] / 4); /* ?????B??? */ + rgb += 3; + } + + io_store_eflags(eflags); /* ???????????? */ + + return; + } +}; +}; Added: PhoeniOS/trunk/system/palette.h =================================================================== --- PhoeniOS/trunk/system/palette.h (rev 0) +++ PhoeniOS/trunk/system/palette.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,37 @@ +/* --------------------------------------------------------- */ +/* File: palette.h */ +/* Update: 2009/03/01 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +/* ????????? */ +#define COL8_000000 0 +#define COL8_FF0000 1 +#define COL8_00FF00 2 +#define COL8_FFFF00 3 +#define COL8_0000FF 4 +#define COL8_FF00FF 5 +#define COL8_00FFFF 6 +#define COL8_FFFFFF 7 +#define COL8_C6C6C6 8 +#define COL8_840000 9 +#define COL8_008400 10 +#define COL8_848400 11 +#define COL8_000084 12 +#define COL8_840084 13 +#define COL8_008484 14 +#define COL8_848484 15 + +#ifdef __cplusplus +namespace System { +namespace Graphic { + class Palette { + public: + static void Initialize(void); + static void Set_Palette(int start, int end, unsigned char *rgb); + }; +}; +}; +#endif Added: PhoeniOS/trunk/system/phoenios.h =================================================================== --- PhoeniOS/trunk/system/phoenios.h (rev 0) +++ PhoeniOS/trunk/system/phoenios.h 2009-03-13 05:32:33 UTC (rev 69) @@ -0,0 +1,22 @@ +/* --------------------------------------------------------- */ +/* File: phoenios.h */ +/* Update: 2009/03/13 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS???????????? */ +/* --------------------------------------------------------- */ + +/* C,C++ */ +#include "background.h" +#include "bootinfo.h" +#include "color.h" +#include "descriptor.h" +#include "drawing.h" +#include "fifo.h" +#include "int.h" +#include "mouse.h" +#include "palette.h" + +/* NASK */ +#include "nask_dsc.h" +#include "nask_int.h" +#include "nask_io.h" Added: PhoeniOS/trunk/system/phoenios.sys =================================================================== (Binary files differ) Property changes on: PhoeniOS/trunk/system/phoenios.sys ___________________________________________________________________ Added: svn:mime-type + application/octet-stream From svnnotify ¡÷ sourceforge.jp Wed Mar 18 16:54:35 2009 From: svnnotify ¡÷ sourceforge.jp (svnnotify ¡÷ sourceforge.jp) Date: Wed, 18 Mar 2009 16:54:35 +0900 Subject: [PhoeniOS-SVN] [Commit] [73] Message-ID: <1237362875.077269.8367.nullmailer@users.sourceforge.jp> Revision: 73 http://svn.sourceforge.jp/view?root=phoenios&view=rev&rev=73 Author: litesystems Date: 2009-03-18 16:54:35 +0900 (Wed, 18 Mar 2009) Log Message: ----------- Modified Paths: -------------- PhoeniOS/trunk/build.txt PhoeniOS/trunk/system/Makefile PhoeniOS/trunk/system/asmhead.nas PhoeniOS/trunk/system/int.cpp PhoeniOS/trunk/system/main.cpp PhoeniOS/trunk/system/mouse.cpp PhoeniOS/trunk/system/mouse.h PhoeniOS/trunk/system/phoenios.h PhoeniOS/trunk/system/phoenios.sys Added Paths: ----------- PhoeniOS/trunk/system/keyboard.cpp PhoeniOS/trunk/system/keyboard.h -------------- next part -------------- Modified: PhoeniOS/trunk/build.txt =================================================================== --- PhoeniOS/trunk/build.txt 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/build.txt 2009-03-18 07:54:35 UTC (rev 73) @@ -1 +1 @@ -256 \ No newline at end of file +269 \ No newline at end of file Modified: PhoeniOS/trunk/system/Makefile =================================================================== --- PhoeniOS/trunk/system/Makefile 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/Makefile 2009-03-18 07:54:35 UTC (rev 73) @@ -1,4 +1,4 @@ -OBJS_BOOTPACK = main.obj background.obj bootinfo.obj color.obj descriptor.obj drawing.obj fifo.obj int.obj palette.obj mouse.obj \ +OBJS_BOOTPACK = main.obj background.obj bootinfo.obj color.obj descriptor.obj drawing.obj fifo.obj int.obj keyboard.obj palette.obj mouse.obj \ hankaku.obj \ nask_dsc.obj nask_int.obj nask_io.obj Modified: PhoeniOS/trunk/system/asmhead.nas =================================================================== --- PhoeniOS/trunk/system/asmhead.nas 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/asmhead.nas 2009-03-18 07:54:35 UTC (rev 73) @@ -18,7 +18,7 @@ ; 0x105 : 1024 x 768 x 8bit ; 0x107 : 1280 x 1024 x 8bit -VBEMODE EQU 0x103 ; VBE??? +VBEMODE EQU 0x105 ; VBE??? ; BOOTINFO CYLS EQU 0x1000 ; ?????????? Modified: PhoeniOS/trunk/system/int.cpp =================================================================== --- PhoeniOS/trunk/system/int.cpp 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/int.cpp 2009-03-18 07:54:35 UTC (rev 73) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: int.cpp */ -/* Update: 2009/03/13 */ +/* Update: 2009/03/17 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS????????W? */ /* ????????? */ @@ -9,8 +9,6 @@ #include #include "phoenios.h" -extern System::FIFO::FIFO8 keyfifo; - using namespace System::Graphic; using namespace System::Information; @@ -39,21 +37,22 @@ /* PS/2???????????? */ void Handlers::Handler21(int *esp) { unsigned char data; - io_out8(PIC0_OCW2, 0x61); /* IRQ-01?????PIC??? */ + io_out8(PIC0_OCW2, 0x61); /* IRQ-01?????PIC0??? */ data = io_in8(PORT_KEYDAT); keyfifo.Put(data); + return; } /* PS/2?????????? */ void Handlers::Handler2c(int *esp) { - BootInfo binfo; - Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 0, 0), 0, 0, 32 * 8 - 1, 15); - Drawing::PutFonts(binfo.vram, binfo.scrnx, 0, 0, Color::RGB24To8(255, 255, 255), (unsigned char *) "INT 2C (IRQ-12) : PS/2 Mouse"); + unsigned char data; + io_out8(PIC1_OCW2, 0x64); /* IRQ-12?????PIC1??? */ + io_out8(PIC0_OCW2, 0x62); /* IRQ-02?????PIC0??? */ + data = io_in8(PORT_KEYDAT); + mousefifo.Put(data); - for (;;) { - io_hlt(); - } + return; } }; }; Added: PhoeniOS/trunk/system/keyboard.cpp =================================================================== --- PhoeniOS/trunk/system/keyboard.cpp (rev 0) +++ PhoeniOS/trunk/system/keyboard.cpp 2009-03-18 07:54:35 UTC (rev 73) @@ -0,0 +1,37 @@ +/* --------------------------------------------------------- */ +/* File: keyboard.cpp */ +/* Update: 2009/03/17 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ????????? */ +/* --------------------------------------------------------- */ + +#include "phoenios.h" + +System::FIFO::FIFO8 keyfifo; +unsigned char keybuf[32]; + +namespace System { +namespace Keyboard { + void Keyboard::Initialize(void) { + Wait(); + io_out8(PORT_KEYCMD, KEYCMD_WRITE_MODE); + Wait(); + io_out8(PORT_KEYDAT, KBC_MODE); + + keyfifo.Initialize(32, keybuf); + + return; + } + + void Keyboard::Wait(void) { + for (;;) { + if ((io_in8(PORT_KEYSTA) & KEYSTA_SEND_NOTREADY) == 0) { + break; + } + } + + return; + } +} +} Added: PhoeniOS/trunk/system/keyboard.h =================================================================== --- PhoeniOS/trunk/system/keyboard.h (rev 0) +++ PhoeniOS/trunk/system/keyboard.h 2009-03-18 07:54:35 UTC (rev 73) @@ -0,0 +1,28 @@ +/* --------------------------------------------------------- */ +/* File: keyboard.h */ +/* Update: 2009/03/17 */ +/* License: GNU General Public License v3 */ +/* Description: PhoeniOS????????? */ +/* ???????????? */ +/* --------------------------------------------------------- */ + +#define PORT_KEYDAT 0x0060 +#define PORT_KEYSTA 0x0064 +#define PORT_KEYCMD 0x0064 +#define KEYSTA_SEND_NOTREADY 0x02 +#define KEYCMD_WRITE_MODE 0x60 +#define KBC_MODE 0x47 + +extern System::FIFO::FIFO8 keyfifo; + +#ifdef __cplusplus +namespace System { +namespace Keyboard { + class Keyboard { + public: + static void Initialize(void); + static void Wait(void); + }; +}; +}; +#endif Modified: PhoeniOS/trunk/system/main.cpp =================================================================== --- PhoeniOS/trunk/system/main.cpp 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/main.cpp 2009-03-18 07:54:35 UTC (rev 73) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: main.cpp */ -/* Update: 2009/03/13 */ +/* Update: 2009/03/17 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???? */ /* --------------------------------------------------------- */ @@ -8,19 +8,17 @@ #include #include "phoenios.h" -extern "C" { - void Main(void); -}; - using namespace System::Descriptor; using namespace System::FIFO; using namespace System::Graphic; using namespace System::Information; using namespace System::Interrupt; +using namespace System::Keyboard; using namespace System::Mouse; -FIFO8 keyfifo; -unsigned char keybuf[32]; +extern "C" { + void Main(void); +}; void Main(void) { @@ -31,11 +29,13 @@ Descriptor::Initialize(); PIC::Initialize(); - io_sti(); - + Keyboard::Initialize(); + Mouse::Initialize(); Palette::Initialize(); Background::Draw(); + io_sti(); + mx = (binfo.scrnx - 16) / 2; my = (binfo.scrny - 28 - 16) / 2; Cursor::Initialize(mcursor, Color::RGB24To8(0, 64, 128)); @@ -43,21 +43,27 @@ sprintf(s, "CursorPosition:(%d, %d)", mx, my); Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 48, COL8_FFFFFF, (unsigned char *) s); - keyfifo.Initialize(32, keybuf); - io_out8(PIC0_IMR, 0xf9); /* PIC1?????????(11111001) */ io_out8(PIC1_IMR, 0xef); /* ??????(11101111) */ for (;;) { io_cli(); - if (keyfifo.Status() == 0) { + if (keyfifo.Status() + mousefifo.Status() == 0) { io_stihlt(); } else { - i = keyfifo.Get(); - io_sti(); - sprintf(s, "%02X", i); - Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 8, 72, 23, 87); - Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 72, Color::RGB24To8(255, 255, 255), (unsigned char *) s); + if (keyfifo.Status() != 0) { + i = keyfifo.Get(); + io_sti(); + sprintf(s, "%02X", i); + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 8, 72, 23, 87); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 8, 72, Color::RGB24To8(255, 255, 255), (unsigned char *) s); + } else if (mousefifo.Status() != 0) { + i = mousefifo.Get(); + io_sti(); + sprintf(s, "%02X", i); + Drawing::FillRectangle_8(binfo.vram, binfo.scrnx, Color::RGB24To8(0, 64, 128), 40, 72, 55, 87); + Drawing::PutFonts(binfo.vram, binfo.scrnx, 40, 72, Color::RGB24To8(255, 255, 255), (unsigned char *) s); + } } } } Modified: PhoeniOS/trunk/system/mouse.cpp =================================================================== --- PhoeniOS/trunk/system/mouse.cpp 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/mouse.cpp 2009-03-18 07:54:35 UTC (rev 73) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: mouse.cpp */ -/* Update: 2009/03/01 */ +/* Update: 2009/03/17 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS??????? */ /* ????????? */ @@ -8,8 +8,22 @@ #include "phoenios.h" +System::FIFO::FIFO8 mousefifo; +unsigned char mousebuf[128]; + namespace System { namespace Mouse { + void Mouse::Initialize(void) { + System::Keyboard::Keyboard::Wait(); + io_out8(PORT_KEYCMD, KEYCMD_SENDTO_MOUSE); + System::Keyboard::Keyboard::Wait(); + io_out8(PORT_KEYDAT, MOUSECMD_ENABLE); + + mousefifo.Initialize(128, mousebuf); + + return; + }; + void Cursor::Initialize(char *mouse, char bc) { static char cursor[16][17] = { //"*...............", @@ -78,16 +92,3 @@ } }; }; - - -void putblock8_8(char *vram, int vxsize, int pxsize, - int pysize, int px0, int py0, char *buf, int bxsize) -{ - int x, y; - for (y = 0; y < pysize; y++) { - for (x = 0; x < pxsize; x++) { - vram[(py0 + y) * vxsize + (px0 + x)] = buf[y * bxsize + x]; - } - } - return; -} Modified: PhoeniOS/trunk/system/mouse.h =================================================================== --- PhoeniOS/trunk/system/mouse.h 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/mouse.h 2009-03-18 07:54:35 UTC (rev 73) @@ -1,14 +1,23 @@ /* --------------------------------------------------------- */ /* File: mouse.h */ -/* Update: 2009/03/01 */ +/* Update: 2009/03/17 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS??????? */ /* ???????????? */ /* --------------------------------------------------------- */ +#define KEYCMD_SENDTO_MOUSE 0xd4 +#define MOUSECMD_ENABLE 0xf4 + +extern System::FIFO::FIFO8 mousefifo; + #ifdef __cplusplus namespace System { namespace Mouse { + class Mouse { + public: + static void Initialize(void); + }; class Cursor { public: static void Initialize(char *cursor, char bc); @@ -17,13 +26,3 @@ }; }; #endif - -#ifdef __cplusplus -extern "C" { -#endif -void init_mouse_cursor8(char *mouse, char bc); -void putblock8_8(char *vram, int vxsize, int pxsize, - int pysize, int px0, int py0, char *buf, int bxsize); -#ifdef __cplusplus -}; -#endif Modified: PhoeniOS/trunk/system/phoenios.h =================================================================== --- PhoeniOS/trunk/system/phoenios.h 2009-03-13 05:41:30 UTC (rev 72) +++ PhoeniOS/trunk/system/phoenios.h 2009-03-18 07:54:35 UTC (rev 73) @@ -1,6 +1,6 @@ /* --------------------------------------------------------- */ /* File: phoenios.h */ -/* Update: 2009/03/13 */ +/* Update: 2009/03/17 */ /* License: GNU General Public License v3 */ /* Description: PhoeniOS???????????? */ /* --------------------------------------------------------- */ @@ -13,6 +13,7 @@ #include "drawing.h" #include "fifo.h" #include "int.h" +#include "keyboard.h" #include "mouse.h" #include "palette.h" Modified: PhoeniOS/trunk/system/phoenios.sys =================================================================== (Binary files differ)