-
Notifications
You must be signed in to change notification settings - Fork 1
About TLVC
TLVC is a Linux based OS for vintage PCs - a fork of ELKS 0.6.0 with a different focus: Efficiency and speed more than wide compatibility and applications. A small (even floppy based if desired), efficient, configurable tool for testing, diagnosing, understanding and playing with vintage PCs: IBM PC compatibles with ISA bus from the 5150 (original 8088 PC) to the 386. Later generations are OK too, but running the 486 and up in 16 bit mode may not make much sense.
What we have here is a platform for learning, experimenting, mastering, having fun with old computers: Getting them to run, check out hardware components, find and fix problems, see what they can (and cannot) do, push them, becoming impressed with what the old clunkers with a few hundred Kbytes of RAM and a 4 or 12MHz processor can deliver. And not the least, to develop software to improve on and add to the system. No graphics, no gaming, just text/terminal I/O which is what this age of hardware is suited for.
A key difference from ELKS is BIOS independence. While TLVC - like any other PC operating system - uses the BIOS to boot, that's where the BIOS dependency ends. This makes the system faster and more responsive. It also allows for experimentation with protected mode if you're so inclined and have a 286 or newer system.
Important documents: Getting Started with TLVC - Configure and Build TLVC - TLVC Networking Guide - TLVC and Emulators
Linux started its life on 32 bit computers, initially the Intel 386 and compatibles. So Linux has always been a 32 bit (these days 32 and 64 bit) operating system. This excluded older, less powerful systems from running Linux. At some point in the mid 90s, Linus Torvalds and few others got the idea to create a smaller Linux for 16 bit systems. The embedded market was expanding fast and in many cases preferred the less expensive and much simpler 16 bit processors - like the 80186 in SOC chips. Thus ELKS and its name - 'Embedded Linux'.
The project died quickly, to be revived after a few years and then die again repeatedly over the years. Finally, around 2016 a new set of developers and a new target - vintage computers - got the project into motion towards becoming a useable OS platform, a stable and useful Linux system.
As of 2021 and version 0.5.0, ELKS was a reasonably stable and quite complete system with a decent set of Unix/Linux standard tools, TCP/IP networking and a very powerful and efficient GCC based gcc-based cross development platform. (Check the Wikipedia article on ELKS for more details).
As of version 0.6.0 (early 2023), actually almost 0.7.0, ELKS had 'grown up' – with a lot of interesting capabilities, tools and features – even games, a minimal windowing (X-windows) implementation, Basic, Japanese PC98 support and more. That's where TLVC started.
Common to most IA16 based systems is limited resources. Limited memory, segmented memory model, slow processors, floppy disks, low res displays etc. This inevitably requires tough choices to be made, clear priorities to be set in order to stretch the limited resources to the maximum. ELKS – and TLVC – both have many quirks and limitations resulting from such choices. For example, running the TCP/IP stack as a user process is less than optimal in many ways, speed included, but adding the implementation to the kernel would force a number of other components out - literally. Another example is the limited process table which allows a limited concurrent processes on the system. As of late 2024 the number of tasks is runtime configurable, between 12 and 20 is reasonable depending on the hardware and resources available). A tough limitation for a Unix/Linux based system which is inherently process-oriented: Many small processes connected via pipes. The limited process space makes it advantageous to some times break with the Unix philosophy and add functionality to a program even though there is a separate tool that could do it. Similarly you will notice that the default filesystem layout is very flat compared to Linus and Unix. This saves space on constrained media (floppies) and saves memory (inode table) in a running system.
Buffering is another example. TLVC allows the user to specify the number of IO buffers to allocate, but a higher number (faster system) will limit the memory available for user programs. Lots of details about this in other Wiki documents.
While on the issue of buffers - and more specifically, file system buffers: Support for Extended Memory (XMS), added to ELKS by Greg Haerr in 2021, helps a lot, but is available only on 'newer' systems, notably 386 based machines and some 286 systems. Using XMS buffers, TLVC can have up to 2950 1k byte buffers in extended memory, which for floppy based systems exceeds the size of the root file system and effectively works as an invisible RAM-disk!
Using lots of buffers is tempting because it's fast, but there is a caveat: In order to reduce the damages in case of a system crash or hang, modified buffers must be 'synced' to disk at reasonable intervals, like every 20 or 30 seconds. With many buffers and slow disk IO (floppy in particular), the syncing (in Unix parlance known as update) will be quite noticeable to the user. This is, however, much less of a problem with TLVC than ELKS because of TLVC's direct IO (as opposed to BIOS based IO) which manages to almost hide this process completely. More about this particular issue below – it serves as a great illustration of the advantages of disconnecting from BIOS-based low level functions.
Vintage computing is on a roll. Young people are becoming interested in yesteryear's computers - how they worked, what could they do, 'I found this old computer in the attic, does it work' etc. ELKS has come a long way to address this demand. But ELKS is now focusing less on the OS and more on applications and games, with less focus on the many remaining weaknesses of the OS.
The fact is that - as of 0.6.0 with its reliance on BIOS IO - slow block-IO is ELKS' trademark. Old (and new, but that's a different story) computers were interrupt driven for a reason: It was (and is) the only way to get decent performance from tiny resources.
And decent performance is important because it's inspiring, it lets you do more, it allows the computer to work more of the time instead of wait. Regardless of age, we get inspired by performance - as in 'gee, this old clunker can really do that?'. It works for me, it may work for you.
The primary goal with TLVC is to create an efficient and flexible tool to gain understanding of your old computer, to figure out what it can do. A more or less complete system on a single floppy that will tell you as much as possible about the machine you found at the flea market or pulled out from the attic/garage - or found on eBay. Help you diagnose the parts that don't work and get you up and running when DOS let you down. The minimal system requirements are just that - minimal. A 1982 PC or PC/XT with a 360K floppy drive and 256K RAM is limited, but useable. If you have a 386 with 20MB RAM, that's fine too. Or an emulator - like QEMU, 86Box, VirtualBox, etc. if you don't have the hardware and just what to see what the system is like.
The starting point for TLVC was ELKS 0.6.0 (January 2023) with games and a lot of other stuff removed. A set of bootable floppies packed with as many useful tools as the space permits. Even a 360k floppy will deliver a workable system. If the tools needed in your particular case aren't on the floppy images, you can download, configure and create your own special configuration (take a look at the booting and configuration Wikis for details). You can also - if you're an experienced Unix/Linux user – mount the images and change them 'manually', one by one. Again, check the docs for more details.
A 'big' 1.2M or 1.44M floppy can contain a full system except manual pages. 'The system' being a small Unix-like operating system with origins back to the early beginning of Linux and many similarities with Berkeley Unix from the mid-80s. Including quite a few basic GNU/Linux/Unix command line tools.
The knowledge you need in order to use TLVC is a basic understanding of the Unix/Linux command line, the shell and the most basic commands. Take a look at the 'booting' chapter in the Getting Started Wiki to see how just booting TLVC will tell you a lot about your system - what hardware you have, what works and what doesn't. Just getting a few characters on the screen from the first level boot program provides a lot of information. Then comes the kernel boot messages, identifying each driver and checks for hardware to attach to, becomes very informative.
When you get to a shell prompt and the keyboard works, it's time to pop the cork: The major functions are working.
At the OS level, the major difference between ELKS and TLVC is that the latter is disconnected from the PC BIOS and on its way to become completely interrupt driven. This is - as alluded to above - important for several reasons, the most important being efficiency/response times. ELKS has slow IO because most IO is running via the system BIOS. This saves kernel memory, simplifies a lot of things and adds compatibility, but at a significant cost. When ELKS does block IO (floppy, hard disk), the OS (and thus the system) stops completely while the BIOS controls the devices. This is particularly annoying when running off of floppies, but very noticeable when running from hard disks too. How bad became clear when the TLVC direct drivers for floppies and hard disks replaced them. All of a sudden block IO is overlapping with other activities and even floppy activity becomes transparent to other processes than the ones actually doing (and waiting for) the IO. Case in point, the SYNCing of buffers mentioned above as a significant pain because the system appears to die for several seconds twice a minute or so, is gone - even when syncing to floppies. Instead of spending time idle-looping in the BIOS, the OS is doing normal work while IO is going on.
This is one of many side effects of becoming interrupt driven. Another is that network traffic is much more smooth with fewer retransmissions and practically no lost connections. The fact that the ethernet drivers are now completely interrupt driven too helps. Not necessarily higher transmission speeds on an idle system but a more stable, smooth and error free performance and visibly better utilization of the old machine's resources.
Some of enhancements int TLVC since ELKS 0.6.0 (check the readme file on the front page for a more updated list)
- Numerous bug fixes in the kernel
- Many fixes and enhancements to utilities
- Ethernet drivers have optional IO buffering which enables them to be completely interrupt driven: Increased stability and performance
- Many enhancements and bug fixes in
ktcp, the TCP/IP implementation. - New 'direct' drivers replace the BIOS hd/floppy driver, making block IO completely interrupt driven.
- The cross development system has been fixed to run on Apple M platforms.
- Command history has been added to the main shell (ash).
- Raw/char drivers have been added for disk/floppy IO, an important enhancement for both diagnostics and system utilities.
- Support for XT-IDE and XT-CF disk/CF/SSD interfaces
- Support for MFM disk drives
- New and updated Ethernet drivers, includes the Intel EtherExpress 16 and AMD LANCE based interfaces
- A new
meminfoutility which paints memory usage using ascii graphics (-Mand-Poptions) - Expanded XMS support with kernel in HMA, network buffers in XMS, ...
- UMB support
- Unlimited
bootoptsfile size and many new runtime configuration options - XT class systems may now boot off of 720 floppies
... and much more.
- … plug and play: You're expected to have some technical proficiency and experience with basic command line tools and development tools, like running menuconfig and familiarity with the make command.
- … covering all PC variants. TLVC is continuously being tested on many hardware platforms and emulators, but there will always be holes. Contributions are welcome.
- … a gaming platform. Graphics support is not a priority in TLVC, consider it a text/terminal/command line system.
Like many Open Source projects, TLVC is constantly moving, evolving - via contributions from the community. While there is an overall goal, there are always many ways to get there, and priorities change. Your thoughts, questions and contributions are important.
Thank you!
TLVC: Tiny Linux for Vintage Computers