How low a level do you understand between 'SW' and HW?

Started by
12 comments, last by King Mir 9 years, 8 months ago

If you are interested to learn low level assembly language on the PC, the "easiest" way is probably to install DOS Box, which is a nice piece of software that you can use to run really ancient software on modern computers. Mac version is called Boxer. The thing with DOS Box is that it emulates the environment of old, old "IBM compatible" computers as it were back then, with BIOS, VESA graphics, sound blaster, and all. Another nice thing with good old dos, is that it ran in something called 'real mode', which basically is non-protected, segmented memory model. Translated to more understandable phrases, that means you can take over the whole computer, set any graphics mode you want, play audio at the "lowest" level, or take over all interrupts without the operating system protesting at all. Switching to a VESA graphics mode is fairly easy. It is just calling one interrupt that is set up by the BIOS. Then you can write directly into video memory to create all the graphics you want, all without the hassle to write a basic operating system yourself, with complex pre-loaders and loaders and kernel and hard drive interfacing and all those really hard, complex things. I think what I used back in the day, was masm.

If someone wanted to how software was run on a processor at a low level, I'd advice looking to a RISC processor assembly 1st, like MIPS. MIPS assembly is easy to understand (compared to intel), and the commands fit nicely into 32-bit machine code. SPIM is a nice MIPS simulator that you can use to practice assembly.

My Gamedev Journal: 2D Game Making, the Easy Way

---(Old Blog, still has good info): 2dGameMaking
-----
"No one ever posts on that message board; it's too crowded." - Yoga Berra (sorta)

Advertisement

I suggest you read CODE. I had the same questions you had, and this book does a great job of clarifying it. I don't think anyone here can explain this better than the author of that book.

I'm a game programmer and computer science ninja !

Here's my 2D RPG-Ish Platformer Programmed in Python + Pygame, with a Custom Level Editor and Rendering System!

Here's my Custom IDE / Debugger Programmed in Pure Python and Designed from the Ground Up for Programming Education!

Want to ask about Python, Flask, wxPython, Pygame, C++, HTML5, CSS3, Javascript, jQuery, C++, Vimscript, SFML 1.6 / 2.0, or anything else? Recruiting for a game development team and need a passionate programmer? Just want to talk about programming? Email me here:

hobohm.business@gmail.com

or Personal-Message me on here !

I looked everywhere to find the relationship between hardware and software, and nothing did it better than Carl Heralds series on Binary and C.

">


But first try Eli the Computer guy:

">


There is this electronics video saw also, but I can't find it right now, I will tomorrow.

They call me the Tutorial Doctor.

Where is the root point where we can start everything, does the hardware like mouse input have it's own firmware/software pre-built in that allow use it communicate with it?

Ultimately everything is built on analog circuits. But for where software starts, it's at a higher level. Micro controllers and CPUs are circuits that take machine code as part of their operation. This is what allows them to be so general purpose; if you don't need your computer operation to be mutable you can use an application-specific integrated circuit(ASIC). All software is compiled into machine code.

If an assembler is the most fundamental piece of software how would you load it onto the HD/memory in the first place?

Memory has a controller built into the CPU. Machine code has instructions for interacting with memory, and the CPU makes memory do the right thing.

A hard disk has a built in controller chip in the enclosure, quite possibly an ASIC. There is a protocol for talking to harddisks and other peripheral hardware (ie hardware that's not part of the CPU operation), usually by mapping certain memory addresses to talk to the device.

Machine code is bit code for assembler, and assembler is source code for machine code; one is efficiently packed, the other is human readable. All software in some form or other becomes machine code, although higher level languages may have an interpreter in the pipeline.


I think my real problem is that I just don't understand the complexity/structure and in built software of the hardware itself so I still can't make that connection between the 'software/text' that we see on the screen and the electronics themselves.

That's computers for you. Layers on layers of abstraction. In fact the point is that you don't need to just to write programs. How machine code is converted into the operations it specifies is the field of computer architecture, which basically describes in digital logic, the silicon in a CPU. Talking to peripherals is it's own field. So is the design of peripherals so that they can talk to the CPU.

This topic is closed to new replies.

Advertisement