I need to know more about computers

Programming, for all ages and all languages.
User avatar
konacake
Member
Member
Posts: 27
Joined: Wed Jul 02, 2014 2:10 am

Re: I need to know more about computers

Post by konacake »

Windows Registry doesn't really have anything to do with anything, it's just a (really dumb and vulnerable) way Windows keeps up with programs.

If you want to learn how computers work, I'd start by reading lots of Wikipedia articles. You don't need to know how to program to know how computers work. I'd start with pages like Random-Access Memory, the Von Neumann architecture (the architecture pretty much all moder computers follow (not exactly, I know it's modified, but you know)), how a CPU works, and also I'd even advise to read up on computer history, since old computers don't hide anything from you, so they go into a lot of detail about how they work. Models like the UNIVAC, PDP-11, Altair 8800, and any other old machines you can find. You'll pick up on what they're trying to say in due time. Like someone else recommended, I'd also recommend installing GNU/Linux. From that you'll learn all the packages that are installed, like your init system and display server, and thus learn what those things are.

If you want to program, I'd start with training yourself on how to program. You can't write anything past "hello world" because I'm assuming your mind isn't trained to think like a programmer. I'd start really basic, like using Scratch or RPG Maker, some drag-and-drop logic system that trains you how to think in simple steps to make an automation. After you can get some sprites dancing around the screen, then I'd say you can learn a real language. Maybe JavaScript or Python, since they result in the most immedate output. Or if you like Minecraft, install the ComputerCraft mod and give Lua a whirl. And lastly, I recommend lurking communities that are into programming, like here, or maybe 4chan's /g/ or reddit (both places are awful but if you're a total beginner why not)

But I think you're certianly far away from writing an OS. This doesn't mean it'll take you a long time to know how to make an OS, but it will take a lot of learning before you can try it. When you can fluently read C and C++ (or any language, since knowing how to program means you can pick up any language with not too much trouble), and thus can read the source code of other OSes, then I think you're sufficently capable of beginning. Best of luck to you!
User avatar
KemyLand
Member
Member
Posts: 213
Joined: Mon Jun 16, 2014 5:33 pm
Location: Costa Rica

Re: I need to know more about computers

Post by KemyLand »

It's completely true that he needs to learn 2^1024+ unsigned chars of documentation, tutorials, and bloated GDB output/commands 8) . That means he's not ready, but has (some strange type of) motivation. I remember I started programming the same way. Just that I didn't knew the OSDev forums :oops: . I forgot the idea one week later, but I continued to learn programming. Started with Java, then learned some HTML/CSS/Javascript/PHP, then moved to C, some Python and x86 assembly by the way, and finally C++. That took me ~3.5 years. This time varies a lot as per individual. After that time, the OSDev'ing idea was reborn on my mind. I find this site. I failed! 6 months later I retried and other (mostly succesful) 6 months had past from then.

Look at the description of this site: "The Place to Start for Operating System Development". It's not "The Place to Start for Computer Programming and Operating System Development". As far as I know, chase (the site admin), created this site with the objective of centralizing the web's OSDev'ing communites. Most of them where fusioned in here. Strangely enough, this community is made of ~10,000 registered users, plus the unregistered ones, which are usually a lot (see the Guests Online stuff in the main page, they're usually more of those online than registered ones!). You should LEARN and DEVELOP programming abilities before any attempt. Otherwise, you'll end cracking your head over the keyboard :P
Happy New Code!
Hello World in Brainfuck :D:

Code: Select all

++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.
[/size]
mac
Member
Member
Posts: 144
Joined: Tue Sep 23, 2014 6:12 pm

Re: I need to know more about computers

Post by mac »

Well, thank you for the kind motivation.
mac
Member
Member
Posts: 144
Joined: Tue Sep 23, 2014 6:12 pm

Re: I need to know more about computers

Post by mac »

So I understand: The CPU retrieves data from memory (RAM) in a specific address or location with a sequence of numbers, breaks it down into instructions and performs the execution of the instructions. Operations performed are arithmetical and control operations. Is this right? Feel free to correct me or add.
no92
Member
Member
Posts: 307
Joined: Wed Oct 30, 2013 1:57 pm
Libera.chat IRC: no92
Location: Germany
Contact:

Re: I need to know more about computers

Post by no92 »

You forgot about the CPU pipeline. :D

Keep in mind that the number of bits retrieved is the "bitness" of the target machine (e.g. on an 80386, you will always get 32bits/4 bytes when reading from memory). I will not get more detailed than that here as I want you to learn coding first.

A lot of people aren't understanding the name RAM: the random does not mean which data/location is accessed, but the time. No more detail, as above.

It's really not that easy, first learn programming and then move on to OSdeving. You'll need a minimum of 2 years for that.

tl;dr: Learn programming. See you in ~2 years.
Antti
Member
Member
Posts: 923
Joined: Thu Jul 05, 2012 5:12 am
Location: Finland

Re: I need to know more about computers

Post by Antti »

no92 wrote:OSdeving is the most advanced and complicated thing you can do in computer science.
That statement does not make any sense. Any application could be as advanced and complicated. Besides, when looking at an avarage hobby OS, it is a vast exaggeration to think writing it was the "most advanced and complicated thing you can do in computer science". And yes, writing that simple hobby OS is operating system development.

Of course, creating an OS could end up being the most advanced and complicated thing. Actually, if it is too complicated (at implementation level), maybe there is something wrong with the design? If creating a good system (TM), you should not need be very intelligent when implementing it. You should be intelligent when designing it. Implementation should be a straighforward process.
User avatar
SpyderTL
Member
Member
Posts: 1074
Joined: Sun Sep 19, 2010 10:05 pm

Re: I need to know more about computers

Post by SpyderTL »

SeanMc wrote:So I understand: The CPU retrieves data from memory (RAM) in a specific address or location with a sequence of numbers, breaks it down into instructions and performs the execution of the instructions. Operations performed are arithmetical and control operations.
Basically, yes. Modern CPUs are very complex machines, but all you really need to know, at this point, is the following:
  • The CPU executes one instruction at a time.
  • It has a register, called IP, which points to the address of the next instruction to be executed, in system memory (RAM).
  • It has a small amount of internal memory to keep track of the current "state" of the CPU. This includes several "registers" that are used to perform simple math operations. (Add, subtract, multiply, divide). These operations are integer operations, so no decimals or fractions
  • The CPU can change its internal memory state based on the instruction that it is currently executing, but it has very little control over system RAM or other components. It really only has two outputs and two inputs.
  • Inputs are the CPU clock, which tells the CPU when to execute the next instruction, and an interrupt line that is used to notify the CPU of an external event. When this line is activated by an external component, the CPU saves the current value of IP in system memory and then sets IP to the address of the first instruction that is responsible for "handling" the external event.
  • The outputs are to either system memory or an I/O device. Most instructions cause the CPU to read or write to system memory, but a few instructions cause the CPU to read or write to an I/O device. In reality, however, both of these are connected to the motherboard, and it decides what the CPU is really connected to. So writing a value to system memory may not actually write a value to system memory if the motherboard intercepts the data and sends it somewhere else. The CPU really has no control over this, directly.
These are the key points to keep in mind while you are designing an operating system. All of your code will be run on the CPU, but the CPU relies on many external components to actually perform most operations, like reading files from a CD, or writing text to the screen.

Let us know if you have any specific questions, and we'll try to help where we can.

Good luck!
Project: OZone
Source: GitHub
Current Task: LIB/OBJ file support
"The more they overthink the plumbing, the easier it is to stop up the drain." - Montgomery Scott
User avatar
konacake
Member
Member
Posts: 27
Joined: Wed Jul 02, 2014 2:10 am

Re: I need to know more about computers

Post by konacake »

no92 wrote:You'll need a minimum of 2 years for that.
Never tell a student they're useless for a set amount of time. It'll make them think they can't do anything until that time is up, and then when that time does roll around, they'll be confused as to why they don't suddenly know how to do things and get discourage.

OP, it's never too early to get into OS development. We don't think you're ready yet, but there's no reason you can't begin reading the material now. Maybe you won't understand it yet, and that's fine. Go learn a little bit about computers and programming, then try reading some OS material again. If you still don't get it, read a little bit more again. Just keep doing that until you've got it. It could take any amount of time, but don't worry about the time, just worry about the work. You're already doing a good job breaking down the parts of computers now.
User avatar
Muazzam
Member
Member
Posts: 543
Joined: Mon Jun 16, 2014 5:59 am
Location: Shahpur, Layyah, Pakistan

Re: I need to know more about computers

Post by Muazzam »

If you are unfamiliar with programming check out Javascript and Python tutorials at http://www.codecademy.com/. For OSDeving also check out document http://www.cs.bham.ac.uk/~exr/lectures/ ... os-dev.pdf and these youtube videos www.youtube.com/watch?v=Lgd5aV2LKrk.
no92
Member
Member
Posts: 307
Joined: Wed Oct 30, 2013 1:57 pm
Libera.chat IRC: no92
Location: Germany
Contact:

Re: I need to know more about computers

Post by no92 »

Learning from YouTube videos is bad. A lot of bad habits are getting told there all the time. If you want to learn something, use the manual/docs.
User avatar
konacake
Member
Member
Posts: 27
Joined: Wed Jul 02, 2014 2:10 am

Re: I need to know more about computers

Post by konacake »

Actually, if you ask me, the best way to learn to program is just pick a language and then search "how to do X in Y language". You start with really basic things like looking how to print strings, then maybe you want to make a simple text adventure game, so you look up how to do that, and learn several things though doing that, then maybe you want to make a roguelike, and learn about arrays and keyboard input and whatnot. Just slow steps, figuring out how to make something slightly more advanced than what you made before. I don't recommend (advanced/big/long) books (but really short ones like A Byte of Python are good) and I don't recommend videos. Just look up how to do basic things and look for stackoverflow threads about it. It's as simple as that.

I think a lot of people over-complicate programming. Learning it is a few simple steps, just like how a big program is only a few simple steps.
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: I need to know more about computers

Post by Brendan »

Hi,
SeanMc wrote:Alright, hard to explain here. Some of you may be shocked, but after 15 years of my life being into computers, I realized that I don't understand as much how they work on a technical level. :?
My advice is, get used to it. ;)

I started OS development before the original Pentium was released (about 20 years ago) and was programming (6502) assembly before that; and I still don't understand as much about how computers work as I'd like. There's always lower level details (from chipset signals all the way down the chemistry/physics chips are built on), and it seems like every year something new gets added (e.g. I still know very little about AVX).


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
no92
Member
Member
Posts: 307
Joined: Wed Oct 30, 2013 1:57 pm
Libera.chat IRC: no92
Location: Germany
Contact:

Re: I need to know more about computers

Post by no92 »

Brendan wrote:I still don't understand as much about how computers work as I'd like.
Wow - I'd consider Brendan and Combuster programming gods. I wouldn't have expected Brendan saying - well - that.
seuti
Member
Member
Posts: 74
Joined: Tue Aug 19, 2014 1:20 pm

Re: I need to know more about computers

Post by seuti »

no92 wrote:
Brendan wrote:I still don't understand as much about how computers work as I'd like.
Wow - I'd consider Brendan and Combuster programming gods. I wouldn't have expected Brendan saying - well - that.
If you know everything about something, you don't know it enough. :wink:
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Re: I need to know more about computers

Post by Combuster »

no92 wrote:
Brendan wrote:I still don't understand as much about how computers work as I'd like.
Wow - I'd consider Brendan and Combuster programming gods. I wouldn't have expected Brendan saying - well - that.
There's a graph for this phenomenon:

Image
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
Post Reply