Concerning the Introductory Matter in the OSDev Wiki

All off topic discussions go here. Everything from the funny thing your cat did to your favorite tv shows. Non-programming computer questions are ok too.
Post Reply
User avatar
AceOfClubs
Posts: 5
Joined: Tue Feb 16, 2021 5:41 am
Location: Ontario, Canada

Concerning the Introductory Matter in the OSDev Wiki

Post by AceOfClubs »

Hi everyone, I know this post is technically about the wiki, but I thought General Ramblings might be a better thread to post in since the contents of this message are more philosophical than technical. I'm trying to understand why the beginning matter of the wiki must be written in such a discouraging tone. Here are some excerpts from the wiki to illustrate what I'm talking about:

"Writing an OS is not a beginner's task. In fact, writing an OS is usually considered the most difficult programming task. You will need above-average programming skills before even considering a project like this. Failure to comply will make you look silly." - From the Required Knowledge page

"No one who isn't already a seasoned developer with years of experience in several languages and environments should even be considering OS Dev yet. A decade of programming, including a few years of low-level coding in assembly language and/or a systems language such as C, is pretty much the minimum necessary to even understand the topic well enough to work in it." - From the Beginner Mistakes page

As much as I appreciate the strong word of caution (if you could call it that), even if I don't know a thing about computers or programming, say I do try to follow this tutorial. What's the worst that could happen? Maybe I spend a few months trying to work through something that I realize I don't like in the end. Will I have learnt something? Probably. What have I lost? Time. Could I have wasted my time in a less productive way? Absolutely. So why must this be written in such an unfriendly manner?

- AceOfClubs
Octocontrabass
Member
Member
Posts: 5517
Joined: Mon Mar 25, 2013 7:01 pm

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by Octocontrabass »

AceOfClubs wrote:What's the worst that could happen?
You could spam the forum with questions that are easily answered by your favorite search engine.

If you're actually willing to put in the months of work it would take to go from zero to understanding how and why the tutorial works the way it does, you can write an OS.
User avatar
AceOfClubs
Posts: 5
Joined: Tue Feb 16, 2021 5:41 am
Location: Ontario, Canada

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by AceOfClubs »

Octocontrabass wrote:You could spam the forum with questions that are easily answered by your favorite search engine.
I hear you. I appreciate that it can be quite difficult to prevent help vampires, as they are sometimes called, from taking over a forum and subsequently killing it. I don't blame the authors of the wiki for wanting to protect the forum from such activity, however I think there are probably better ways of accomplishing this. For example, the rules for posting here are made quite clear when creating an account and all content is filtered through the moderators. On the other hand, I don't have any experience running or moderating a forum, so I apologize if this assertion of mine is naïve or short sighted. Please inform me of any faults in my reasoning here.

Either way, my primary concern is that these types of messages will turn people away who are genuinely curious and interested in learning about operating system development, and who may not have such extensive knowledge and experience as is outlined in the wiki. I can speak to this personally. About a year ago, I became interested in learning about the inner workings and low-level details of operating systems. I also entertained the idea of writing my own operating system, mostly because I wanted to experience the challenge. Anyway, I was thinking about it recently and eventually arrived at the conclusion that it's always a good idea to think and ask questions about what other people tell you, and to use the information that you have in order to come to your own conclusions. Also, it is equally important to always be questioning your own ideas and understanding of things, and to be open to rethinking them as well as considering new information, ideas and perspectives. In other words, I've revisited operating system development and decided that the authors of this wiki are not going to stop me from learning about it, or at least giving it a shot.

I didn't mean for this to turn into a discussion about my philosophy of life, but to tie this back to what I was saying earlier, someone just like myself might abandon their interest in operating systems altogether, as I was very close to doing at one time, because they read some passages of text written by someone who is supposedly an expert telling them basically that they shouldn't even bother trying without certain prerequisites. To recommend prerequisites is fine, but I don't think that anyone who has the desire and is willing to put in the effort to actually learn about operating system development should be discouraged from doing so because they don't have the ideal knowledge or experience. At the end of the day, take my opinion for a grain of salt. My goal here is not to convince anyone that what I'm saying is right, but rather to present ideas and perspectives that may have been overlooked.

Thanks for listening.

- AceOfClubs
Last edited by AceOfClubs on Thu Feb 18, 2021 6:47 pm, edited 1 time in total.
User avatar
iansjack
Member
Member
Posts: 4689
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by iansjack »

If someone is going to be put off operating systems development by the suggestion that they need to do a little reading, and need to ensure that they are well-versed in the operation of the toolsets used, then they are almost certainly going to find it too frustrating. They are far more likely, in these circumstances, to shelve the whole idea than they would be if they followed the advice.

Put simply, beginners are being reminded that they need to learn to walk before they run. If that bothers you then there are plenty of other forums and plenty of other hobbies. To be brutally honest, the people who wrote that advice probably intended to discourage people who aren't prepared to do the necessary preparation - at the very least they certainly intended to discourage them from continually asking questions that are more than adequately answered elsewhere.
User avatar
AceOfClubs
Posts: 5
Joined: Tue Feb 16, 2021 5:41 am
Location: Ontario, Canada

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by AceOfClubs »

iansjack wrote:Put simply, beginners are being reminded that they need to learn to walk before they run.
Hi iansjack, thanks for explaining this to me.

You make a good point. When learning about anything, I have a bad habit of trying to jump ahead to more advanced topics when I should really be focusing on the fundamentals, and I have the feeling that's what I'm trying to do here. It used to drive my math teachers mad, haha. When I was in grade eleven, I wouldn't do my math homework on quadratics, and instead I'd go to the math office after school to try to get some poor teacher to explain integrals to me. It would probably be wise of me just to do the reading first.

The wiki also suggests that you should have at least a decade of professional programming experience. I can see how this would be helpful, but why is it considered a prerequisite?

Thanks again.

- AceOfClubs
User avatar
iansjack
Member
Member
Posts: 4689
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by iansjack »

AceOfClubs wrote: The wiki also suggests that you should have at least a decade of professional programming experience. I can see how this would be helpful, but why is it considered a prerequisite?
I'd say that that recommendation is over the top. There is nothing to prevent a self-taught amateur from being just as good, or better, at programming than a professional. The only caveat I would add to that is that an amateur is likely to overestimate their ability whilst a professional will have had it tested.

I know it's difficult to hear someone saying "this is really too difficult for you to attempt without adequate preparation", but some things in life just are. Swimming the English Channel? Probably a good idea to do quite a bit of preparation first.

It's true that wasting your time, and the time of others, in attempting OS programming when you are not prepared is unlikely to cause any harm (although I guess the answer to "what's the worst that could happen" is that you could be so frustrated by the failure that - if you are that sort of personality - you go out and buy a gun and massacre a shopping mall full of innocents; not that I suggest that is likely, just that it's the worst) but people here genuinely don't want people to be discouraged from OS development because they attempt it when they are not ready.
User avatar
AceOfClubs
Posts: 5
Joined: Tue Feb 16, 2021 5:41 am
Location: Ontario, Canada

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by AceOfClubs »

Hi iansjack, thanks for your message.
iansjack wrote:I know it's difficult to hear someone saying "this is really too difficult for you to attempt without adequate preparation", but some things in life just are.
Thanks for understanding. My initial intent behind this post was not to make it specific to my situation, but perhaps it would be helpful if I provided a bit of context as to where I am in my programming journey.

About three years ago, I took a class where I had my first introduction to the C programming language and most of its features. All of our projects were done on old desktop computers running GNU-Linux. We learned about the compilation process using the GNU development suite (the gcc toolchain, glibc, binutils), basic terminal I/O, developing small applications using the curses library, developing multithreaded applications using the pthread library, PWM control and basic (hardware) I/O using a parallel port and a system library, basic circuit design, the 555 timer, and some 7400-series chips including shift registers, seven-segment decoders, and 3 to 8 line decoders for multiplexing. This was all done within the environment of an operating system, of course.

A year after that, I took a course which built off of some of the material in the previous course, this time adding serial (RS232) communication between two computers (TX and RX swapped) using a system library, but most of the focus of this course was on microcontrollers. Using the PIC16F690, I learned a bit about microcontroller architecture including the different types of memories and how to use them, and the concept of using registers to change how the microcontroller operates and to do other stuff. I also learned how to program a microcontroller using a programmer, and wrote code both in assembly language and C to perform various tasks. The summative evaluation / culminating task was to write a basic CLI for an APATCO kit which was based around the WDC65C02 and I believe came with libraries for I/O manipulation. Unfortunately, I never got to do this project because that was when COVID-19 hit and the rest of the course had to be held online, which was very disappointing, as I was looking forward to this project.

I was incredibly captivated by both of these courses. In the second course, while I was working on a microcontroller project, someone took the microcontroller from my breadboard when I wasn't there. My teacher didn't have many of these PIC16F690 microcontrollers left to give out, but at the time, I knew that Arduinos were microcontroller-based, and my teacher had lots of Arduino Unos laying around (the version with the DIP microcontroller in the socket, so it could be removed with a tool and some effort). So, like an absolute Chad, instead of asking my teacher for a new PIC, I taught myself how to write and assemble AVR assembly language using Atmel Studio (now Microchip Studio), bought an AVRISP MKII programmer online and completed my project that way. At this time, I was also watching some of Ben Eater's videos on YouTube, mostly the videos covering his 8-bit breadboard computer, which I found extremely fascinating.

Nowadays, I write all of my microcontroller code in assembly language. I like the AVR architecture a lot more than the PIC architecture. It has a wealth of useful instructions, and a feature that allows you to write to the program memory during runtime (even though I haven't used it to this day, I thought it was cool and could be useful in some more advanced projects). I think the best part though, after having written assembly for the PIC, is having 32 (more than one) general-purpose registers and not having to waste half of your clock cycles on annoying register bank switches. For about a year, on and off, I've been working on some small microcontroller projects using the ATmega328P, like writing some data to an LCD or using a rotary encoder and a bi-directional shift register to scroll a binary sequence across a few LEDs.

Right now, I'm working on my first (relatively) big microcontroller project which is a multi-purpose time-keeping device, meant to function sort of like the clock app on your phone. It's going to feature multiple alarms, timer and stopwatch functions, and making it portable shouldn't be too difficult as long as I can find an appropriate buck-boost converter. It's going to be implemented using a 128*64 graphic LCD, a piezoelectric buzzer, and a rotary encoder for data entry and menus. I really want to have it synchronize periodically with a server on the internet, but that is unfortunately out of my reach. After this project, I want to try interfacing a PS/2 keyboard with my microcontroller and write a basic CLI that can perform various operations.

About halfway into my second course, I had this revelation that microcontrollers were essentially dumbed down versions of modern processors, and that most of the knowledge and experience that I'd gained from working with microcontrollers can be applied to modern processors. Then I started to think about programming modern processors and learning about operating systems. I found OSDev online while looking for tutorials and read a bit of the wiki, after which I became discouraged and decided that I'd come back to it at some other time. Quite recently, I picked it back up again and followed the first bit of a basic tutorial that I found online. From what I read, it covered some of the basics of the x86 architecture such as processor modes, memory models, the GPRs and a few processor instructions, a bit of NASM, the boot sector, using BIOS routines, addressing in real mode, writing a GDT, switching to protected mode, addressing in protected mode, using the video memory and text mode to display text to the screen, and that's where I stopped reading. Then I proceeded to read particular sections of the actual Intel x86 Software Developer's Manual, and that's where I am now.

Where would you recommend I go from here?
iansjack wrote:...people here genuinely don't want people to be discouraged from OS development because they attempt it when they are not ready.
I think that's great and definitely in the right spirit! I still think the wiki could be a little nicer about getting that across though. I mean, I'm noticing a significant discrepancy between what you're saying and how the wiki came across. "Failure to comply will make you look silly" sounds a bit menacing, wouldn't you agree?

- AceOfClubs
Last edited by AceOfClubs on Thu Feb 18, 2021 6:53 pm, edited 1 time in total.
User avatar
iansjack
Member
Member
Posts: 4689
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by iansjack »

AceOfClubs wrote:Failure to comply will make you look silly" sounds a bit menacing, wouldn't you agree?
Again, that's certainly not what I would have written. But it's a fine line between getting the message across that a certain level of knowledge is necessary and appearing discouraging or supercilious. Rest assured that (almost) everyone here is keen to encourage newcomers, but don't want the forum cluttered up with material that is better documented elsewhere.
User avatar
AceOfClubs
Posts: 5
Joined: Tue Feb 16, 2021 5:41 am
Location: Ontario, Canada

Re: Concerning the Introductory Matter in the OSDev Wiki

Post by AceOfClubs »

iansjack wrote:Rest assured that (almost) everyone here is keen to encourage newcomers, but don't want the forum cluttered up with material that is better documented elsewhere.
Yeah, I noticed that. After looking at that part of the wiki, I checked out the forums, and the tone was almost the opposite. Members seem quite eager to welcome and help other people, which is awesome. Another thing that I noticed is that people of all experience levels are posting on the forum, which is also good to see. I think that's it from me for now. Take care!

- AceOfClubs
Post Reply