upvote
It was common knowledge, though not for most of those (with some exceptions like legacy gaming fans) coming into the PC world much after the early 2000s.

Terminate but Stay Resident was the original DOS function call to allow a utility program to exit but stay in memory waiting for interrupt signals (it will have hooked into those interrupts before calling TSR) to respond to. Utilities that operated in this manner (mouse drivers, and many other useful things) became collectively known as TSR programs and then just TSRs.

reply
DOS programs generally were like command line apps today (but simpler, obviously). They did a thing, then exited. Or they showed their "TUI" (as we'd call it today), and when you told it to exit, you got back to the DOS prompt to start the next program.

TSRs were a special kind of program, that instead of telling DOS "I'm done, here's my memory back", said "I'm done for now, but don't unload me", so their memory stayed allocated/used. And you got your command prompt back immediately to continue your work.

TSRs usually hooked into an interrupt like the keyboard interrupt, intercepting a hotkey to re-activate the program (so you could browse your address book while you were in your (text mode) word processor; "kind-of" multitasking), or they offered a service to other programs (like the mouse and CD-ROM drivers).

There were all kinds of things that ran as TSRs. Virus scanners (hooking into disk write/reads), modem tools (showing "RING" in the corner of the screen when the modem detected an incoming call), note-taking apps, address books, you name it.

reply
TSR stands for Terminate and Stay Resident, a distinct behaviour for DOS era programs, which would usually run to completion and exit.
reply
To expand upon this - the TSR programs stayed in memory after being loaded. Typical use were drivers, for example mouse driver. It loaded, hooked itself in the interrupt table and then exited back to DOS prompt. And this gave you mouse support for other programs.

Wikipedia has some details, if you are interested: https://en.wikipedia.org/wiki/Terminate-and-stay-resident_pr...

reply