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

What to I need for a custom OS to run?

Question

4 answers to this question

Recommended Posts

  • 0

The print function is typically a wrapper over 'io.stdout', i.e 'io.write'. I'd look into how OpenOS handles this. Although this can become rather complex pretty quickly. If you plan on having unix like io then you might want to design your 'pipes' first and lay a convenient print function over them as it is more useful as a higher level function. Think about how your programs will run in your OS and then how your io will tie into the program environment. I think it would be really helpful for you to disassemble this aspect of OpenOS to better understand how you may want to design this. Am I making any sense??

Link to post
Share on other sites
  • 0

@Molinkois correct that these things become complex quickly, but I think it is a LOT of fun :) 

things like term.write, print, and io.write call io.stdout:write. (by default) io.stdout is the tty stream, and io.stdout:write is

https://github.com/MightyPirates/OpenComputers/blob/master-MC1.7.10/src/main/resources/assets/opencomputers/loot/openos/lib/tty.lua#L76

 

 

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
Answer this question...

×   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.