Skip to content

Voxion-Labs/RedTerminal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

10 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

RedTerminal logo

RedTerminal

A lightweight systems-level C project demonstrating operating systems concepts, process lifecycle management, and simulated CPU scheduling.

Live Web Demo | Repository


✨ Overview

RedTerminal is a C-based process simulator and interactive CLI designed to explore fundamental OS concepts. It features strict process state transitions, thread-safe asynchronous logging, background thread scheduling, and includes a stunning Vanilla JS web-based terminal emulator that brings the OS concepts to a modern browser interface.


What Is RedTerminal?

RedTerminal acts as a playground and educational tool for developers who want to understand the inner workings of an operating system's process manager.

At the technical level, RedTerminal acts as:

  • an interactive REPL shell environment
  • a background CPU time scheduler simulator using POSIX threads
  • a robust Process Control Block (PCB) manager
  • a thread-safe asynchronous event logger
  • a visually striking web-based terminal emulator for browser deployment

Problem It Solves

Learning about operating systems often involves massive codebases like the Linux kernel, making it hard to focus on fundamental concepts in isolation:

  • real OS kernels are overwhelmingly complex
  • theoretical concepts are hard to visualize
  • typical student projects lack professional structure or modern interfaces

RedTerminal solves that by giving users a clean, isolated environment to explore:

  • how processes transition between RUNNING, STOPPED, and TERMINATED states
  • how background schedulers simulate CPU time without blocking user input
  • how concurrency is handled with thread-safe mutex locks
  • how these backend concepts can be visualized in a modern web dashboard

πŸ”— Links


Latest Project State

RedTerminal currently ships with:

  • a C-based interactive shell with robust command parsing
  • commands for start, kill, pause, resume, ps, and logs
  • an asynchronous pthread based scheduler simulating CPU execution
  • strict process lifecycle management up to 256 concurrent processes
  • a fully integrated Vanilla JS web demo that mirrors the OS logic visually
  • comprehensive test suites for core modules
  • complete build automation via Makefile

🌌 Core Highlights

  • polished web demo with glassmorphism UI and OS-style boot sequence
  • real-time terminal input history and custom typing animations in the browser
  • fully decoupled background scheduler in C using POSIX threads
  • thread-safe logging infrastructure using mutexes
  • interactive CLI interface that handles edge cases and state validation gracefully
  • lightweight footprint requiring only gcc and make to compile locally

Project Surface

C Application Experience

  • interactive REPL environment built directly on standard I/O
  • deterministic process lifecycle handling (RUNNING, STOPPED, TERMINATED)
  • automated background logging of all critical system events
  • detailed process table (ps) outputting active state and CPU time

Web Demo Experience

  • premium boot screen sequence for OS startup simulation
  • live updating telemetry sidebar tracking CPU load, Memory, and Uptime
  • custom blinking cursor and typing animations mimicking real terminal behavior
  • full command history accessible via arrow keys

πŸ–ΌοΈ Demo Gallery

RedTerminal Boot
1. System Boot & Initialization
The web version features a polished glassmorphism UI that boots into a ready state with zero active processes and a clean telemetry sidebar.
RedTerminal Active Processes
2. Active Process Simulation
Once processes are spawned, the terminal tracks states in real-time, displaying PID allocations while the telemetry sidebar graphs synthetic CPU and memory load.

Why RedTerminal

RedTerminal is built around a simple educational promise:

  • take complex OS concepts
  • distill them into readable C code
  • provide an interactive interface to test them
  • visualize the outcome beautifully

That promise shapes the module structure, the threading model, the data structures used, and the accompanying web demo layer across the project.


πŸ› οΈ Tech Stack

Core Systems (Backend)

  • C11 Standard
  • POSIX Threads (pthreads)
  • GNU Make

Web Demo (Frontend)

  • HTML5
  • CSS3 (Custom Properties, Flexbox, Animations)
  • Vanilla JavaScript (ES6+)

🧱 Project Structure

RedTerminal/
β”œβ”€β”€ Makefile                # Build system configuration
β”œβ”€β”€ README.md               # Project overview and instructions
β”œβ”€β”€ LICENSE                 # MIT License
β”œβ”€β”€ .github/workflows/      # CI/CD pipelines
β”œβ”€β”€ demo/                   # Technical documentation & assets
β”‚   β”œβ”€β”€ architecture.md     # Module layout and thread model
β”‚   β”œβ”€β”€ commands.md         # CLI reference guide
β”‚   └── screenshots/        # Demo gallery assets
β”œβ”€β”€ include/                # Public C header files (API contracts)
β”œβ”€β”€ src/                    # C source implementations
β”œβ”€β”€ tests/                  # Automated C test suite
└── docs/                   # Vanilla JS Browser Simulation
    β”œβ”€β”€ app.js
    β”œβ”€β”€ index.html
    └── style.css

πŸ—οΈ Architecture

Systems Responsibilities

  • Process Manager: Handles Process Control Blocks (PCBs) and strict state transitions. Safely manages memory and active limits.
  • Scheduler: Utilizes POSIX threads to simulate CPU time allocation in the background, fully decoupled from the shell blocking IO.
  • Logger: Asynchronously writes structured system events to redterm.log using mutex locks.
  • Shell: The primary entry point providing a robust REPL interface.

Data Flow

  1. User enters command via the shell interface.
  2. The shell parses arguments and delegates to the Process Manager.
  3. The Process Manager updates the global PCB array securely.
  4. The background Scheduler thread continuously polls the PCB array, granting CPU time to RUNNING processes.
  5. All critical state changes invoke the thread-safe Logger to record events.

βœ… Validation Snapshot

The current repo state includes:

  • modular C code separated clearly into src and include headers
  • a tests directory containing assertion-based tests for logger, process, and scheduler
  • automated testing execution available through make test
  • functional web demo deployable to static hosting

πŸ“¦ Key Capabilities

  • simulated CPU scheduling and multi-process lifecycle tracking
  • robust state validation preventing illegal transitions (e.g., killing an already terminated process)
  • fully interactive browser-based simulation matching the C application feature-set
  • live telemetry tracking simulated CPU load, memory usage, and uptime
  • CI/CD ready structure with GitHub Actions workflows

Current Scope

RedTerminal is currently positioned as a functional systems simulator and web demo with:

  • an interactive C CLI application
  • a complete web-based terminal simulator
  • background thread simulation
  • thread-safe logging infrastructure
  • comprehensive documentation on architecture and commands

Local Setup

Prerequisites

  • A POSIX-compliant environment (Linux / macOS / WSL)
  • gcc compiler
  • make utility

Compile the Application

make

Run the Application

./redterm
# OR
make run

🏁 Build Commands

Start Application

make run

Run Test Suite

make test

Clean Build Artifacts

make clean

🌐 Deployment

Web Demo Deployment

Deployment profile

  • lightweight browser-first frontend located in the docs/ folder
  • no external dependencies or build tools required for the web demo

πŸ“„ License

RedTerminal is protected under the MIT License.

The full license text is available in LICENSE.

License summary:

  • copyright Β© 2026 Rudranarayan Jena
  • permission is granted to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software
  • provided "as is", without warranty of any kind

πŸ‘¨β€πŸ’» Author

Rudranarayan Jena

Crafted by Rudranarayan Jena

Founder @ Voxion Labs

Focused on building polished systems applications, interactive terminal emulators, and educational software experiences.

GitHub: liambrooks-lab


About

RedTerminal is a lightweight systems-programming project written in C that simulates process lifecycle management, scheduling, state transitions, and command-line interaction. It demonstrates modular architecture, logging, process control, and interactive shell design.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors