Jump to content




Running CC on Linux?


23 replies to this topic

#1 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 24 February 2014 - 06:35 AM

Please don't understand the title wrong,
I got an old computer by my grandfather. I thought: "Let's install Linux!" :D
Now I'm asking if it's possible to "emulate" a CC computer on linux... Then I would have a real CC computer :)

Is that possible?

#2 Thib0704

  • Members
  • 93 posts
  • LocationgetServer().getPlayer("Thib0704").getLocation();

Posted 24 February 2014 - 06:40 AM

Do you mean running a CC shell, native on a linux based kernel? cause that would be AWSOME!!

#3 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 24 February 2014 - 07:32 AM

View PostThib0704, on 24 February 2014 - 06:40 AM, said:

Do you mean running a CC shell, native on a linux based kernel? cause that would be AWSOME!!
Yep.
For now my first problem is that I can't find a CD to write a debian iso on D: then, the hardest part would be to port some cc libs to modify the screen.
But the good thing about it is: more colors and SMALLER pixels :D

#4 Thib0704

  • Members
  • 93 posts
  • LocationgetServer().getPlayer("Thib0704").getLocation();

Posted 24 February 2014 - 07:55 AM

Now how would you make the screen....
Would you make it compatible with the 720/1080p :o
or just like a normal CC computer but scaled up?

EDIT: Btw if you have a USB stick, install debian on it, and then boot :P

Edited by Thib0704, 24 February 2014 - 07:59 AM.


#5 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 24 February 2014 - 08:03 AM

The computer's way to old to have USB xD
I can send you a pic of it if you want :D

#6 Thib0704

  • Members
  • 93 posts
  • LocationgetServer().getPlayer("Thib0704").getLocation();

Posted 24 February 2014 - 08:13 AM

Sure lol :D

#7 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 24 February 2014 - 08:31 AM

Yes, my room is messy D:

EDIT:
It's a Acrobat 486 DX2-66 Top-Tower

Attached Thumbnails

  • Attached Image: Picture 1.jpg

Edited by Freack100, 24 February 2014 - 08:33 AM.


#8 Thib0704

  • Members
  • 93 posts
  • LocationgetServer().getPlayer("Thib0704").getLocation();

Posted 24 February 2014 - 12:25 PM

I'm guessing the best way to make a native CC OS, would be to make a fullscreen CC emulator.
Adding it to a small linux based OS (ex puppy)
Then building the OS with the emulator to run on startup.
And then VOILA.

#9 6677

  • Members
  • 197 posts
  • LocationCambridgeshire, England

Posted 24 February 2014 - 12:28 PM

CC is just JLua which can be installed on linux easily. Then you just need to write some wrapper API's instead. Hell, you get the term and os API's as is.

As for computercraft running bare metal. ELua. Again, just wrapper API's needed.

#10 CherryPie

  • Members
  • 37 posts
  • Location3 Dimensions -> Void -> Universe -> Milky Way -> Cygnus Arm -> Sol -> Earth -> Nevada -> Area 51

Posted 24 February 2014 - 12:33 PM

I have been thinking on this just for Raspberry PI which also runs Linux :D

#11 Thib0704

  • Members
  • 93 posts
  • LocationgetServer().getPlayer("Thib0704").getLocation();

Posted 24 February 2014 - 12:38 PM

View Post6677, on 24 February 2014 - 12:28 PM, said:

CC is just JLua which can be installed on linux easily. Then you just need to write some wrapper API's instead. Hell, you get the term and os API's as is.

As for computercraft running bare metal. ELua. Again, just wrapper API's needed.

Yeah but we want to run it in fullscreen...

#12 gamax92

  • Members
  • 157 posts

Posted 24 February 2014 - 12:40 PM

Yeaaaaaaaah ... no.

You're not gonna get any where decent speed if you go with a JVM, LWJGL, Original CC, and a wrapper to bring it all together. Considering the speed of that processor is 66MHz.

I personally have a 66MHz machine from my father, Mesa (which i think would be needed for lwjgl) is slow.

It's definetly possible though. I tried to do this (but lazyness got to me) and one of the ideas was to just setup a 80x25 terminal, center the virtual CC terminal in the center of it.
Reprogram the console VGA fonts to look more like CC.
Change the palette of the text console to have CC colors.

Btw, slight important to what your options are, which linux distro did you put on that machine?

Offtopic:
Spoiler

Edited by gamax92, 24 February 2014 - 01:08 PM.


#13 6677

  • Members
  • 197 posts
  • LocationCambridgeshire, England

Posted 24 February 2014 - 02:11 PM

View PostThib0704, on 24 February 2014 - 12:38 PM, said:

View Post6677, on 24 February 2014 - 12:28 PM, said:

CC is just JLua which can be installed on linux easily. Then you just need to write some wrapper API's instead. Hell, you get the term and os API's as is.

As for computercraft running bare metal. ELua. Again, just wrapper API's needed.

Yeah but we want to run it in fullscreen...
Don't see your point considering linux normally runs without a desktop environment, ie has a full screen shell....

View Postgamax92, on 24 February 2014 - 12:40 PM, said:

Yeaaaaaaaah ... no.

You're not gonna get any where decent speed if you go with a JVM, LWJGL, Original CC, and a wrapper to bring it all together. Considering the speed of that processor is 66MHz.

I personally have a 66MHz machine from my father, Mesa (which i think would be needed for lwjgl) is slow.

It's definetly possible though. I tried to do this (but lazyness got to me) and one of the ideas was to just setup a 80x25 terminal, center the virtual CC terminal in the center of it.
Reprogram the console VGA fonts to look more like CC.
Change the palette of the text console to have CC colors.

Btw, slight important to what your options are, which linux distro did you put on that machine?

Offtopic:
Spoiler
eLua on that machine would be absolutely fine though. I have used it on an 80MHz ARM board without issue.
But it possibly wouldnt be 100% compatible with computercraft.

#14 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 25 February 2014 - 09:07 AM

View Postgamax92, on 24 February 2014 - 12:40 PM, said:

Yeaaaaaaaah ... no.

You're not gonna get any where decent speed if you go with a JVM, LWJGL, Original CC, and a wrapper to bring it all together. Considering the speed of that processor is 66MHz.

I personally have a 66MHz machine from my father, Mesa (which i think would be needed for lwjgl) is slow.

It's definetly possible though. I tried to do this (but lazyness got to me) and one of the ideas was to just setup a 80x25 terminal, center the virtual CC terminal in the center of it.
Reprogram the console VGA fonts to look more like CC.
Change the palette of the text console to have CC colors.

Btw, slight important to what your options are, which linux distro did you put on that machine?

Offtopic:
Spoiler
How should I get USB in a computer without a USB port?

#15 gamax92

  • Members
  • 157 posts

Posted 25 February 2014 - 09:10 AM

PCI USB Card if it has PCI slots, got mine for $3.

Edited by gamax92, 25 February 2014 - 09:14 AM.


#16 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 25 February 2014 - 10:44 AM

View Postgamax92, on 25 February 2014 - 09:10 AM, said:

PCI USB Card if it has PCI slots, got mine for $3.
Ohhh, now I got what you mean :D

BTW, first I will test in a VM before I "kill" my real computer :D

EDIT:
BTW, is there a way to draw stuff with the standard lua5.1 program you can find in linux?

2nd EDIT:
Just found out that debian is a bastard... can't get lua running there... Now switching to puppy

3rd EDIT:
Tested Puppy, I don't like it either... Anyone knows a good lightweight linux distro?

Edited by Freack100, 25 February 2014 - 11:39 AM.


#17 gamax92

  • Members
  • 157 posts

Posted 25 February 2014 - 11:55 AM

Standard lua? Ansi escape sequences. You can only get so far with the colors though, theres pink, magenta, and purple, and you only have magenta and bright-magenta to choose from. Blue will not have both colors used.

Ideally, you'd want to reprogram one of the colors to be different. could change bright-blue to be pink, then just use bright-blue in its place.

There's also the Graphical Buffer idea, you could use one of the Lua Graphical libraries and this would allow you to specify the exact colors you want and even have a good font. This would be slower than just using a text console, but not sure how much slower.

#18 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 25 February 2014 - 12:12 PM

View Postgamax92, on 25 February 2014 - 11:55 AM, said:

Standard lua? Ansi escape sequences. You can only get so far with the colors though, theres pink, magenta, and purple, and you only have magenta and bright-magenta to choose from. Blue will not have both colors used.

Ideally, you'd want to reprogram one of the colors to be different. could change bright-blue to be pink, then just use bright-blue in its place.

There's also the Graphical Buffer idea, you could use one of the Lua Graphical libraries and this would allow you to specify the exact colors you want and even have a good font. This would be slower than just using a text console, but not sure how much slower.

But how do I run lua on my machine? :D I "downloaded" lua5.1 and watched some "tutorials" where they said that I just have to download lua5.1 and do "lua <filepath>" to run the file as lua script. I'm feeling mad right now D:

#19 6677

  • Members
  • 197 posts
  • LocationCambridgeshire, England

Posted 25 February 2014 - 12:15 PM

just downloading lua wont do, you kinda need to install it....

#20 gamax92

  • Members
  • 157 posts

Posted 25 February 2014 - 12:40 PM

Thats a lie, it doesn't need to be installed at all. What matters is that you have a binary and that it runs.

Again, Freack100, do you actually have linux on that machine? From the previous posts it seems like you don't. I'm sorry if I'm treating you like you're an idiot, but you do need an OS to run lua (Except ELua, but lets not get into that)





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users