Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal
Bananasrawesome

Easier to understand?

Recommended Posts

I don't know how to program in Lua but I do know MS-DOS pretty well. I think an MS-DOS emulator in the game which installs the same way as open os and does the same thing would be easier for those who do not know Lua and might know Batch. Are their any add-ons that add this feature? If so, could someone provide a download link? The Minecraft version this is for is 1.7.10.

Link to post
Share on other sites

Unless I'm mistaken the OpenOS command line has some aliases for DOS commands by default, such as dir for ls. I doubt proper command.com/cmd.exe emulation will ever be a thing though. MS-DOS/Windows Batch lacks a number of useful features - it doesn't have functions, if and for are very limited compared to the Unix shell, variable expansion and quoting behave oddly, pattern expansion is not done by the shell but by the commands. And Windows's backward compatibility features would need to be emulated too, like 8.3 file names, case insensitivity, \ instead of / in paths, / instead of - for command line switches, etc.

 

If you want to write a cmd.exe emulator for OpenOS, go ahead. Though I assure you it will be much easier to learn Lua, which is for the most part a very nice and logical programming language with few surprising "pitfalls".

Link to post
Share on other sites

OpenComputers doesn't emulate any real CPU architecture and it's also not a virtualization environment like VirtualBox, so you can't directly install any "normal" operating systems or run Windows exe files or Linux/OSX binaries. The lowest level you can get is writing a custom BIOS on an EEPROM chip, but even that uses Lua. It is theoretically possible to write add-ons that add additional languages to write your BIOSes in, and there have been attempts to write such add-ons for real CPU architectures like ARM, but those are all in their "alpha" stages. Besides, in a Minecraft mod you do not have enough resources to run a proper operating system.

Link to post
Share on other sites

Besides, in a Minecraft mod you do not have enough resources to run a proper operating system.

MS-DOS is a proper operating system. Writing an x86 emu will be a pain in the arse, but there's enough resources to do it.

Heck, I got pretty close to getting Linux to mount root w/ OCMIPS.

I did have to modify the config to allow 8MB of RAM though, but allegedly you can *juuust* squeeze Linux into 4MB of RAM.

For extra fun, I managed to get Lua 5.3.2 (~350KB) to boot off a T1 stick of RAM (192KB) using a virtual memory microkernel.

I would argue that it's possible to emulate a C64 - probably not at full speed or accuracy - in Lua. The real thing has 64KB of RAM.

Technically it's a proper operating system.

those are all in their "alpha" stages.

OCMIPS is complete enough in the emulator department. It just lacks software.

Link to post
Share on other sites

MS-DOS is a proper operating system.

By "proper" I meant "current", regarding the question whether cmd.exe could run under OC. Yes, MS-DOS is a functional operating system. Not really a good candidate to run on OC though, because it's not freely available - you'd need to actually own a copy of MS-DOS, and a real working floppy drive to read it. The newest you could use is MS-DOS 1 or 2 available in source and binary form from here.

 

Link to post
Share on other sites

By "proper" I meant "current"

My Linux port attempt uses Linux 4.1.13 which is the same version I am using on this laptop to write this message. So it's very much current.

Yes, MS-DOS is a functional operating system. Not really a good candidate to run on OC though, because it's not freely available

Use FreeDOS. I have that on my 266MHz Celeron.

Heck, if you want something else that's "current", consider something like RTEMS. Or are you going to use the "not a desktop OS" excuse for that?

Link to post
Share on other sites

My Linux port attempt uses Linux 4.1.13 which is the same version I am using on this laptop to write this message. So it's very much current.

As I said, I was referring to running cmd.exe under OC. That would require something Windows-like (I assume cmd.exe cannot run on MS-DOS or a variant). Other than that, yes, Linux is probably the most logical OS to try to run under OC.

 

Maybe I should stop talking, I am kind of tired. If my posts make no sense or I sound rude, please don't take it personally.

Link to post
Share on other sites

Unless I'm mistaken the OpenOS command line has some aliases for DOS commands by default, such as dir for ls. I doubt proper command.com/cmd.exe emulation will ever be a thing though. MS-DOS/Windows Batch lacks a number of useful features - it doesn't have functions, if and for are very limited compared to the Unix shell, variable expansion and quoting behave oddly, pattern expansion is not done by the shell but by the commands. And Windows's backward compatibility features would need to be emulated too, like 8.3 file names, case insensitivity, \ instead of / in paths, / instead of - for command line switches, etc.

 

If you want to write a cmd.exe emulator for OpenOS, go ahead. Though I assure you it will be much easier to learn Lua, which is for the most part a very nice and logical programming language with few surprising "pitfalls".

 

I'm a bit late, but yes most are:

 

http://ocdoc.cil.li/basic_commands

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.