Nightly update (ISO SHA-1 0b133ba)
This commit is contained in:
1 parent
e0f8448ed9
commit
0df0b26ee2
9 files changed
+94
-73
No files matched your search
Binary file not shown.
@@ -11,7 +11,7 @@ U0 LoadDocDefines()
|
|||||||
//This is cut and replaced when I generate a distro.
|
//This is cut and replaced when I generate a distro.
|
||||||
//See $LK,"DD_TEMPLEOS_LOC",A="FF:::/Demo/AcctExample/TOS/TOSDistro.HC,DD_TEMPLEOS_LOC"$.
|
//See $LK,"DD_TEMPLEOS_LOC",A="FF:::/Demo/AcctExample/TOS/TOSDistro.HC,DD_TEMPLEOS_LOC"$.
|
||||||
$TR-C,"LineRep"$
|
$TR-C,"LineRep"$
|
||||||
$ID,4$DefinePrint("DD_TEMPLEOS_LOC","119,749");
|
$ID,4$DefinePrint("DD_TEMPLEOS_LOC","119,767");
|
||||||
DefinePrint("DD_TEMPLEOS_LOC_OFFICIAL","81,933");
|
DefinePrint("DD_TEMPLEOS_LOC_OFFICIAL","81,933");
|
||||||
$ID,-4$
|
$ID,-4$
|
||||||
DefinePrint("DD_KERNEL","%08X",bfh);
|
DefinePrint("DD_KERNEL","%08X",bfh);
|
||||||
|
|||||||
Binary file not shown.
@@ -21,6 +21,7 @@ extern U0 StreamDir();
|
|||||||
public extern I64 StreamExePrint(U8 *fmt,...);
|
public extern I64 StreamExePrint(U8 *fmt,...);
|
||||||
public extern U0 StreamPrint(U8 *fmt,...);
|
public extern U0 StreamPrint(U8 *fmt,...);
|
||||||
public extern Bool Trace(Bool val=ON);
|
public extern Bool Trace(Bool val=ON);
|
||||||
|
|
||||||
#help_index "Compiler/Lex"
|
#help_index "Compiler/Lex"
|
||||||
#help_file "::/Doc/Lex"
|
#help_file "::/Doc/Lex"
|
||||||
extern U0 ClassMemberLstDel(CHashClass *c);
|
extern U0 ClassMemberLstDel(CHashClass *c);
|
||||||
|
|||||||
@@ -53,16 +53,16 @@ $ID,2$I64 best_score=175;
|
|||||||
$ID,-2$$TR,"OSTestSuite"$
|
$ID,-2$$TR,"OSTestSuite"$
|
||||||
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
||||||
progress3_tf=0.000;progress4_tf=228.734;
|
progress3_tf=0.000;progress4_tf=228.734;
|
||||||
$ID,-2$$TR,"Titanium"$
|
|
||||||
$ID,2$I64 best_score=16469;
|
|
||||||
$ID,-2$$TR,"XCaliber"$
|
$ID,-2$$TR,"XCaliber"$
|
||||||
$ID,2$I64 best_score=90;
|
$ID,2$I64 best_score=90;
|
||||||
I64 msg_flags=2;
|
I64 msg_flags=2;
|
||||||
$ID,-2$$TR,"Talons"$
|
$ID,-2$$TR,"Talons"$
|
||||||
$ID,2$F64 best_score=9999.0000;
|
$ID,2$F64 best_score=9999.0000;
|
||||||
|
$ID,-2$$TR,"Titanium"$
|
||||||
|
$ID,2$I64 best_score=16469;
|
||||||
$ID,-2$$TR,"TOSRegen"$
|
$ID,-2$$TR,"TOSRegen"$
|
||||||
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
||||||
progress3_tf=0.000;progress4_tf=200.498;
|
progress3_tf=0.000;progress4_tf=199.386;
|
||||||
$ID,-2$$ID,-2$$TR,"Once"$
|
$ID,-2$$ID,-2$$TR,"Once"$
|
||||||
$ID,2$$TR,"Adam"$
|
$ID,2$$TR,"Adam"$
|
||||||
$ID,2$$ID,-2$$TR,"User"$
|
$ID,2$$ID,-2$$TR,"User"$
|
||||||
|
|||||||
@@ -570,6 +570,8 @@ public U0 TOSPreRegen()
|
|||||||
Copy("D:/Home/Sup1/Sup1Blog/Bookmarks.html","C:/Home/Sup1/Sup1Blog");
|
Copy("D:/Home/Sup1/Sup1Blog/Bookmarks.html","C:/Home/Sup1/Sup1Blog");
|
||||||
Del("C:/Home/Sup1/Sup1Bin/*");
|
Del("C:/Home/Sup1/Sup1Bin/*");
|
||||||
Copy("D:/Home/Sup1/Sup1Bin/*","C:/Home/Sup1/Sup1Bin");
|
Copy("D:/Home/Sup1/Sup1Bin/*","C:/Home/Sup1/Sup1Bin");
|
||||||
|
Copy("D:/Home/Sup1/Sup1CodeScraps/Comm/TOSSocket*",
|
||||||
|
"C:/Home/Sup1/Sup1CodeScraps/Comm");
|
||||||
Copy("D:/Home/Sup1/Sup1Bin/God*","C:/Linux");
|
Copy("D:/Home/Sup1/Sup1Bin/God*","C:/Linux");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ $WW,1$$FG,5$$TX+CX,"Change Log"$$FG$
|
|||||||
|
|
||||||
Use $LK,"R",A="MN:R"$() to rename if I change a label.
|
Use $LK,"R",A="MN:R"$() to rename if I change a label.
|
||||||
|
|
||||||
|
$IV,1$----01/22/17 17:18:21----$IV,0$
|
||||||
|
|
||||||
$IV,1$----01/22/17 06:08:00----$IV,0$
|
$IV,1$----01/22/17 06:08:00----$IV,0$
|
||||||
* $BK,1$TempleOS version 5.02 Released$BK,0$
|
* $BK,1$TempleOS version 5.02 Released$BK,0$
|
||||||
* Changed polling of $LK,"KbdMsHndlr",A="MN:KbdMsHndlr"$() in $LK,"WinMgrSleep",A="MN:WinMgrSleep"$(), increased fifos.
|
* Changed polling of $LK,"KbdMsHndlr",A="MN:KbdMsHndlr"$() in $LK,"WinMgrSleep",A="MN:WinMgrSleep"$(), increased fifos.
|
||||||
|
|||||||
+84
-68
@@ -5,11 +5,6 @@ it in your start-up scripts.
|
|||||||
|
|
||||||
#help_index "Comm"
|
#help_index "Comm"
|
||||||
|
|
||||||
#define COM1_BASE 0x3F8
|
|
||||||
#define COM2_BASE 0x2F8
|
|
||||||
#define COM3_BASE 0x3E8
|
|
||||||
#define COM4_BASE 0x2E8
|
|
||||||
|
|
||||||
#define UART_THR 0
|
#define UART_THR 0
|
||||||
#define UART_RDR 0
|
#define UART_RDR 0
|
||||||
#define UART_BRDL 0
|
#define UART_BRDL 0
|
||||||
@@ -21,96 +16,117 @@ it in your start-up scripts.
|
|||||||
#define UART_LSR 5
|
#define UART_LSR 5
|
||||||
#define UART_MSR 6
|
#define UART_MSR 6
|
||||||
|
|
||||||
I64 comm_base[5]={0,0x3F8,0x2F8,0x3E8,0x2E8};
|
#define COMf_ENABLED 0
|
||||||
|
class CComm
|
||||||
|
{
|
||||||
|
I64 base,
|
||||||
|
flags;
|
||||||
|
CFifoU8 *RX_fifo;
|
||||||
|
CFifoU8 *TX_fifo;
|
||||||
|
} comm_ports[5];
|
||||||
|
|
||||||
CFifoU8 *comm_fifos[5]={NULL,NULL,NULL,NULL,NULL};
|
U0 CommHndlr(I64 port)
|
||||||
|
{
|
||||||
|
CComm *c=&comm_ports[port];
|
||||||
|
I64 b=0,stat;
|
||||||
|
if (Bt(&c->flags,COMf_ENABLED)) {
|
||||||
|
stat=InU8(c->base+UART_IIR);
|
||||||
|
if (stat & 4) //RX
|
||||||
|
FifoU8Ins(c->RX_fifo,InU8(c->base+UART_RDR));
|
||||||
|
if (stat & 2) { //TX
|
||||||
|
if (FifoU8Rem(c->TX_fifo,&b))
|
||||||
|
OutU8(c->base+UART_THR,b);
|
||||||
|
else
|
||||||
|
OutU8(c->base+UART_IER,1); //RX but no THR empty
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
interrupt U0 IRQComm3()
|
interrupt U0 IRQComm3()
|
||||||
{
|
{
|
||||||
I64 base=comm_base[2];
|
CommHndlr(2);
|
||||||
if (comm_fifos[2] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
CommHndlr(4);
|
||||||
FifoU8Ins(comm_fifos[2],InU8(base+UART_RDR));
|
|
||||||
|
|
||||||
base=comm_base[4];
|
|
||||||
if (comm_fifos[4] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
|
||||||
FifoU8Ins(comm_fifos[4],InU8(base+UART_RDR));
|
|
||||||
OutU8(0x20,0x20);
|
OutU8(0x20,0x20);
|
||||||
}
|
}
|
||||||
|
|
||||||
interrupt U0 IRQComm4()
|
interrupt U0 IRQComm4()
|
||||||
{
|
{
|
||||||
I64 base=comm_base[1];
|
CommHndlr(1);
|
||||||
if (comm_fifos[1] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
CommHndlr(3);
|
||||||
FifoU8Ins(comm_fifos[1],InU8(base+UART_RDR));
|
|
||||||
|
|
||||||
base=comm_base[3];
|
|
||||||
if (comm_fifos[3] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
|
||||||
FifoU8Ins(comm_fifos[3],InU8(base+UART_RDR));
|
|
||||||
OutU8(0x20,0x20);
|
OutU8(0x20,0x20);
|
||||||
}
|
}
|
||||||
|
|
||||||
IntEntrySet(0x23,&IRQComm3);
|
U0 CommInit()
|
||||||
IntEntrySet(0x24,&IRQComm4);
|
|
||||||
|
|
||||||
public U0 CommInit8n1(I64 port,I64 baud)
|
|
||||||
{
|
{
|
||||||
I64 base=comm_base[port];
|
MemSet(&comm_ports,0,sizeof(comm_ports));
|
||||||
|
comm_ports[1].base=0x3F8;
|
||||||
|
comm_ports[2].base=0x2F8;
|
||||||
|
comm_ports[3].base=0x3E8;
|
||||||
|
comm_ports[4].base=0x2E8;
|
||||||
|
IntEntrySet(0x23,&IRQComm3);
|
||||||
|
IntEntrySet(0x24,&IRQComm4);
|
||||||
|
}
|
||||||
|
CommInit;
|
||||||
|
|
||||||
|
public CComm *CommInit8n1(I64 port,I64 baud)
|
||||||
|
{
|
||||||
|
CComm *c=&comm_ports[port];
|
||||||
|
|
||||||
PUSHFD
|
PUSHFD
|
||||||
CLI
|
CLI
|
||||||
if (comm_fifos[port])
|
if (LBts(&c->flags,COMf_ENABLED)) {
|
||||||
FifoU8Del(comm_fifos[port]);
|
FifoU8Del(c->RX_fifo);
|
||||||
comm_fifos[port]=FifoU8New(256);
|
FifoU8Del(c->TX_fifo);
|
||||||
OutU8(base+UART_LCR,0); //Set for IER
|
}
|
||||||
OutU8(base+UART_IER,0); //Disable all IRQ
|
c->RX_fifo=FifoU8New(256);
|
||||||
OutU8(base+UART_LCR,0x80); //Enable baud rate control
|
c->TX_fifo=FifoU8New(256);
|
||||||
OutU8(base+UART_BRDL,(0x180/(baud/300)) & 0xFF); //LSB
|
OutU8(c->base+UART_LCR,0); //Set for IER
|
||||||
OutU8(base+UART_BRDH,(0x180/(baud/300)) / 256); //MSB
|
OutU8(c->base+UART_IER,0); //Disable all IRQ
|
||||||
OutU8(base+UART_LCR,3); // 8-none-1
|
OutU8(c->base+UART_LCR,0x80); //Enable baud rate control
|
||||||
|
OutU8(c->base+UART_BRDL,(0x180/(baud/300)) & 0xFF); //LSB
|
||||||
|
OutU8(c->base+UART_BRDH,(0x180/(baud/300)) / 256); //MSB
|
||||||
|
OutU8(c->base+UART_LCR,3); //8-none-1
|
||||||
|
|
||||||
InU8(base+UART_RDR); //read garbage
|
InU8(c->base+UART_RDR); //read garbage
|
||||||
InU8(base+UART_LSR);
|
InU8(c->base+UART_LSR);
|
||||||
|
|
||||||
OutU8(base+UART_MCR,4);
|
OutU8(c->base+UART_MCR,4);
|
||||||
OutU8(base+UART_IER,0); //Disable all IRQ
|
OutU8(c->base+UART_IER,0); //Disable all IRQ
|
||||||
OutU8(base+UART_MCR,0xA); //out2 and rts
|
OutU8(c->base+UART_MCR,0xA); //out2 and rts
|
||||||
OutU8(0x21,InU8(0x21) & (0xFF-0x18)); //Enable 8259 IRQ 3 & 4
|
OutU8(0x21,InU8(0x21) & (0xFF-0x18)); //Enable 8259 IRQ 3 & 4
|
||||||
OutU8(base+UART_IER,1); //Enable RX IRQ
|
OutU8(c->base+UART_IER,1); //RX but no THR empty
|
||||||
POPFD
|
POPFD
|
||||||
|
|
||||||
|
return c;
|
||||||
}
|
}
|
||||||
|
|
||||||
public U0 CommBusyPutChar(I64 port,U8 b)
|
public U0 CommPutChar(I64 port,U8 b)
|
||||||
{
|
{
|
||||||
I64 base=comm_base[port];
|
CComm *c=&comm_ports[port];
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
PUSHFD
|
||||||
Yield;
|
CLI
|
||||||
OutU8(base+UART_THR,b);
|
FifoU8Ins(c->TX_fifo,b);
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
OutU8(c->base+UART_IER,3); //RX and THR empty
|
||||||
Yield;
|
POPFD
|
||||||
|
Sleep(10); //!!! Remove this line!!! Linux echo_socket is too slow.
|
||||||
}
|
}
|
||||||
|
|
||||||
public U0 CommBusyPutS(I64 port,U8 *st)
|
U0 CommPutS(I64 port,U8 *st)
|
||||||
{
|
{
|
||||||
I64 b,base=comm_base[port];
|
I64 b;
|
||||||
while (b=*(st++)) {
|
while (b=*st++)
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
CommPutChar(port,b);
|
||||||
Yield;
|
|
||||||
OutU8(base+UART_THR,b);
|
|
||||||
}
|
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
|
||||||
Yield;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public U0 CommBusyWriteBlk(I64 port,U8 *buf,I64 count)
|
public U0 CommPutBlk(I64 port,U8 *buf,I64 cnt)
|
||||||
{
|
{
|
||||||
I64 base=comm_base[port];
|
while (cnt--)
|
||||||
while (count--) {
|
CommPutChar(port,*buf++);
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
|
||||||
Yield;
|
|
||||||
OutU8(base+UART_THR,*(buf++));
|
|
||||||
}
|
|
||||||
while (!(InU8(base+UART_LSR) & 0x20))
|
|
||||||
Yield;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#help_index ""
|
public U0 CommPrint(I64 port,U8 *fmt,...)
|
||||||
|
{
|
||||||
|
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||||
|
CommPutS(port,buf);
|
||||||
|
Free(buf);
|
||||||
|
}
|
||||||
@@ -38,7 +38,6 @@ char_bmp_zero_tab_cr_nl_cursor_dollar[16],
|
|||||||
char_bmp_macro[16], char_bmp_printable[16],
|
char_bmp_macro[16], char_bmp_printable[16],
|
||||||
char_bmp_displayable[16], char_bmp_safe_dollar[16],
|
char_bmp_displayable[16], char_bmp_safe_dollar[16],
|
||||||
char_bmp_filename[16], char_bmp_non_eol[16];
|
char_bmp_filename[16], char_bmp_non_eol[16];
|
||||||
|
|
||||||
#help_index "Char/Conversion"
|
#help_index "Char/Conversion"
|
||||||
public extern U8 *Char2KeyName(I64 ch,Bool include_ctrl=TRUE);
|
public extern U8 *Char2KeyName(I64 ch,Bool include_ctrl=TRUE);
|
||||||
public extern I64 Char2ScanCode(I64 ch,I64 sc_flags=0);
|
public extern I64 Char2ScanCode(I64 ch,I64 sc_flags=0);
|
||||||
@@ -761,4 +760,5 @@ public extern F64 tS(); //From SysTimerFreq.
|
|||||||
|
|
||||||
#help_index "Windows"
|
#help_index "Windows"
|
||||||
public extern Bool WinInside(I64 x,I64 y,CTask *task=NULL,I64 border=0);
|
public extern Bool WinInside(I64 x,I64 y,CTask *task=NULL,I64 border=0);
|
||||||
|
|
||||||
#help_index ""
|
#help_index ""
|
||||||
Reference in new issue
Block a user