Author Topic: KnightOS  (Read 186957 times)

0 Members and 2 Guests are viewing this topic.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55942
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: KnightOS
« Reply #105 on: August 04, 2010, 11:46:14 pm »
Sounds promising. Btw I forgot: What was the max size of programs? Is it the total RAM size (or close)?
Now active at https://discord.gg/cuZcfcF (CodeWalrus server)

SirCmpwn

  • Guest
Re: KnightOS
« Reply #106 on: August 05, 2010, 12:10:00 am »
Most of RAM, yes.  There is a little bit that the OS uses.  You can't go past C000h, though, that's a hardware constraint.
« Last Edit: August 05, 2010, 12:10:22 am by SirCmpwn »

Offline thepenguin77

  • z80 Assembly Master
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1594
  • Rating: +823/-5
  • The game in my avatar is bit.ly/p0zPWu
    • View Profile
Re: KnightOS
« Reply #107 on: August 05, 2010, 12:40:18 am »
While things are still in the very early stages, what if you used page 83 instead of page 80 for the second ram bank. This wouldn't be compatible with 83+, but it would allow code execution everywhere. Or at least swap 83 in when programs are executing. This way, you are already better than TI-OS in terms of program size.
zStart v1.3.013 9-20-2013 
All of my utilities
TI-Connect Help
You can build a statue out of either 1'x1' blocks or 12'x12' blocks. The 1'x1' blocks will take a lot longer, but the final product is worth it.
       -Runer112

SirCmpwn

  • Guest
Re: KnightOS
« Reply #108 on: August 05, 2010, 08:40:53 am »
Yeah, I may consider that.  I'm also experimenting with the idea of removing the execution restriction from page 80.
I also got kld and kcall to work last night.
« Last Edit: August 05, 2010, 08:43:25 am by SirCmpwn »

SirCmpwn

  • Guest
Re: KnightOS
« Reply #109 on: August 05, 2010, 08:57:26 am »
Update
KnightOS now supports relative loading, jumping, and calling within executing programs via the kld, kcall, and kjp macros.  This is how it works:
Before running, the code for kld hl, HelloWorld, assuming that HelloWorld is at 0015h, looks like this:
rst 08h
ld hl, 0015h
Now, KnightOS loads the program into RAM and executes it.  However, programs do not know where they will be loaded at runtime.  Let's assume that it is loaded into 8100h.  When rst 08h is executed, KnightOS changes the code to this:
nop
ld hl, 8115h
This way, it is much faster and it never has to execute the rst again.  The same method applies to kcall and kjp.

Offline nemo

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1203
  • Rating: +95/-11
    • View Profile
Re: KnightOS
« Reply #110 on: August 05, 2010, 09:17:08 am »
i know it's hard to set release dates, but do you think you'll release an early alpha version sometime before the new year? it'd be cool to use it during the school year  ;D regardless, nice progress. keep up the good work!


SirCmpwn

  • Guest
Re: KnightOS
« Reply #111 on: August 05, 2010, 09:26:50 am »
I can almost guarantee an alpha or a beta (or a release) by the end of this year.  Note the "almost."
I will probably have the full KnightKernel released by Sunday for programmers to build their own OSes on.

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: KnightOS
« Reply #112 on: August 05, 2010, 09:32:06 am »
What do you mean?  Users won't have access to the RAM, if that's what you mean.  That's just stupid, and TI should have never done it.  Put valuable user data in a place that is wiped everytime the calculator crashes or the power is lost?
* SirCmpwn smacks TI

So basically (in terms of the TI-OS), this means that everything's going to stored in archive and run from archive, right?

Update
KnightOS now supports relative loading, jumping, and calling within executing programs via the kld, kcall, and kjp macros.  This is how it works:
Before running, the code for kld hl, HelloWorld, assuming that HelloWorld is at 0015h, looks like this:
rst 08h
ld hl, 0015h
Now, KnightOS loads the program into RAM and executes it.  However, programs do not know where they will be loaded at runtime.  Let's assume that it is loaded into 8100h.  When rst 08h is executed, KnightOS changes the code to this:
nop
ld hl, 8115h
This way, it is much faster and it never has to execute the rst again.  The same method applies to kcall and kjp.

Wow, that's great! Will it do that right after the program is called, but before the program actually starts?

i know it's hard to set release dates, but do you think you'll release an early alpha version sometime before the new year? it'd be cool to use it during the school year  ;D regardless, nice progress. keep up the good work!

What about the calculator's true purpose, though :D
« Last Edit: August 05, 2010, 09:40:42 am by Deep Thought »




Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: KnightOS
« Reply #113 on: August 05, 2010, 09:41:35 am »
Wow, that sounds neat!  Nice progress Sir. ;D

Offline nemo

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1203
  • Rating: +95/-11
    • View Profile
Re: KnightOS
« Reply #114 on: August 05, 2010, 09:43:03 am »
What about the calculator's true purpose, though :D

hmm... depends upon Knight's functionality then. I remember Sir did say that a CAS was something he hopes to implement. doubt it'll be in an alpha or beta though. hopefully enough math features will exist to get by. depends on how math-intense Trig will be for me as well.

Sir, will equation graphing and tables be implemented in the possibility of a beta?


Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: KnightOS
« Reply #115 on: August 05, 2010, 09:51:15 am »
What about the calculator's true purpose, though :D

hmm... depends upon Knight's functionality then. I remember Sir did say that a CAS was something he hopes to implement. doubt it'll be in an alpha or beta though. hopefully enough math features will exist to get by. depends on how math-intense Trig will be for me as well.

Sir, will equation graphing and tables be implemented in the possibility of a beta?

Wow, I actually totally forgot about graphing ... wait, this is a graphing calculator? :o

Graphing might actually be useful in certain places ;D




Offline thepenguin77

  • z80 Assembly Master
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1594
  • Rating: +823/-5
  • The game in my avatar is bit.ly/p0zPWu
    • View Profile
Re: KnightOS
« Reply #116 on: August 05, 2010, 09:59:59 am »
Sir, I was just thinking, how smart is your kld routine? I am just worried that if you had data like .db $45, $CD, $FF, $00, that kld would mess with it.
zStart v1.3.013 9-20-2013 
All of my utilities
TI-Connect Help
You can build a statue out of either 1'x1' blocks or 12'x12' blocks. The 1'x1' blocks will take a lot longer, but the final product is worth it.
       -Runer112

Offline jnesselr

  • King Graphmastur
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2270
  • Rating: +81/-20
  • TAO == epic
    • View Profile
Re: KnightOS
« Reply #117 on: August 05, 2010, 10:02:14 am »
So the start of an asm program will be .org 0000?

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: KnightOS
« Reply #118 on: August 05, 2010, 10:10:50 am »
So the start of an asm program will be .org 0000?

Oh yeah, about that: it'll still work with all the major assemblers, right?




Offline calc84maniac

  • eZ80 Guru
  • Coder Of Tomorrow
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2912
  • Rating: +471/-17
    • View Profile
    • TI-Boy CE
Re: KnightOS
« Reply #119 on: August 05, 2010, 10:17:54 am »
Update
KnightOS now supports relative loading, jumping, and calling within executing programs via the kld, kcall, and kjp macros.  This is how it works:
Before running, the code for kld hl, HelloWorld, assuming that HelloWorld is at 0015h, looks like this:
rst 08h
ld hl, 0015h
Now, KnightOS loads the program into RAM and executes it.  However, programs do not know where they will be loaded at runtime.  Let's assume that it is loaded into 8100h.  When rst 08h is executed, KnightOS changes the code to this:
nop
ld hl, 8115h
This way, it is much faster and it never has to execute the rst again.  The same method applies to kcall and kjp.
Nice, that's a great idea. It certainly removes the need for searching through the code manually and figuring out the difference between code and data. I assume the same rst routine is used for kld, kcall, and kjp? (btw, in the case of kjp, it might generate faster code to move the nop after the jump)

Edit: Also, are you making programs be loaded at memory addresses aligned to multiples of 256? This might be a good idea, because you will only have to modify one byte with this routine, and secondly programs can still have 256-byte-aligned lookup tables (which are very common in z80 asm)
« Last Edit: August 05, 2010, 10:32:16 am by calc84maniac »
"Most people ask, 'What does a thing do?' Hackers ask, 'What can I make it do?'" - Pablos Holman