Chapter 4 — Reading the Memory Map and Building a Physical Page Allocator

Chapter 4 — Reading the Memory Map and Building a Physical Page Allocator
This entry is part 4 of 4 in the series Writing A Linux Style Operating System From Scratch

Before we add paging, a heap, processes, filesystems, or user programs, the kernel must answer a basic question: Which physical 4 KiB pages of RAM are safe for me to use? Right now, our kernel can boot, print text, catch CPU exceptions, and receive timer/keyboard interrupts. But it still cannot safely allocate memory. This chapter

Chapter 2 — GDT, IDT, and Surviving Your First Kernel Crash

Chapter 2 — GDT, IDT, and Surviving Your First Kernel Crash
This entry is part 2 of 4 in the series Writing A Linux Style Operating System From Scratch

In Chapter 1, we got control of the machine: Now we need something more important than printing text: we need the CPU to call our code when something goes wrong. Right now, if the kernel executes an invalid instruction, divides by zero, touches unmapped memory later, or faults during setup, the machine may reset, hang,

Writing a Linux-style Operating System From Scratch

Writing a Linux-style Operating System From Scratch
This entry is part 1 of 4 in the series Writing A Linux Style Operating System From Scratch

Today, we are beginning a new article series: “Writing a Linux-Style Operating System From Scratch.” In this series, we will walk step by step through the process of creating our own operating system from the ground up. Many operating system tutorials stop shortly after the system boots and prints a simple message on the screen.

Building the i686-elf-gcc Cross-Compiler

Together, these tools allow us to assemble, compile, link, inspect, and transform kernel binaries without using the host operating system’s normal compiler target.

Developing an Open Hardware Device Programmer

This entry is part 1 of 1 in the series Open Universal Device Programmer

Introduction As an electronics enthusiast with over 50 years of experience, I’ve had the privilege of witnessing the dramatic evolution of computing systems. From the early days of 4 and 8-bit machines with minimal RAM to today’s powerful 64-bit computers with terabytes of storage, the progress has been nothing short of extraordinary. The same transformative

Understanding Unicode: A Deep Dive into Universal Text Encoding

Understanding Unicode: A Deep Dive into Universal Text Encoding

Unicode is a universal encoding standard designed to support every language and symbol in use today. This article provides an in-depth look into how Unicode works in application development, exploring the challenges of string comparison, normalization, and the multiple ways that the same visual character can be represented. Learn how to handle Unicode strings in Python, JavaScript, and C, and discover how normalization can resolve issues when comparing visually identical characters.

An Introduction to C for Arduino Users

Explore the essentials of C programming tailored for Arduino users. This comprehensive guide covers variables, data types, control structures, functions, arrays, and pointers, with practical code examples to help you harness the full potential of the Arduino platform.

Implementing Command Parsers on Arduino Over Serial

Introduction Command parsers are essential in embedded systems for receiving and interpreting commands from a host device, such as a computer or another microcontroller. In this article, we will explore how to implement command parsers on an Arduino over a serial connection, focusing on memory management, text buffer creation and use, string formatting, and handling

Understanding Modbus, SCPI, and GPIB Protocols and Their Implementation in Embedded Systems

Understanding Modbus, SCPI, and GPIB Protocols and Their Implementation in Embedded Systems
Control-Bus Image

A Beginners Guide Introduction Communication protocols are vital for enabling embedded devices to interact effectively. Three prominent protocols, Modbus, Standard Commands for Programmable Instruments (SCPI), and General Purpose Interface Bus (GPIB), stand out due to their widespread adoption in various industrial and testing environments. Recently, I had the opportunity to work on an embedded project

An Introduction to C–: A Dive into an Intermediate Language for Compiler and Language Research

Explore the evolution of C– – an intermediate language designed for compiler and language research. Delve into its origins, syntax, and the significance it holds in the realm of programming languages and compiler development.