• 0 Posts
  • 385 Comments
Joined 1 year ago
cake
Cake day: June 12th, 2023

help-circle











  • Windows is historically a “single user OS” whereas Linux is historically a multi-user OS. They’re both multi-user now but the philosophy of these backgrounds results in what you see today.

    So under Windows you login “as an admin” and don’t need passwords for many things - similar to (but very much not the same as) running Linux as root.

    Under Linux you login “as a user” and need to elevate permissions for things which can affect other users on the same system. Typically with sudo these days.

    These lines are very much blurring so you can do many things under Linux without a password and some things on Windows require “running powershell as an admin”.



  • I guess i am still skipping on how real time kernel address the pause? it just never pauses or it no longer needs to be paused?

    When hardware has data ready for a program it generates an interrupt that lets the OS know that there is data ready for an application. My understanding is that real-time OSs give high priority to interrupts so that they’re processed quickly - usually within a fixed period of time (e.g. they may have a max time between interrupt and processing).

    as a side note, is this similar technology they use in high precision manufacturing?

    In those cases it may be more likely they use a micro-controller that doesn’t run any OS at all - at least not a multi-tasking one. If you’re just running a single program you don’t need to worry about latency due to other applications running.


  • So, contrary to what it seems a single CPU core can only execute a single “thing” at a time. Modern operating systems do something called “preemptive multitasking” to give the illusion that more than one things are running at a time. The OS will start your task, then after a while save its state and start another task running, then switch back. It does this fast enough that each job seems to be running concurrently.

    Now if you’re running on a RaspberryPI your program might be waiting for input from a GPIO pin. And when you get that input you want to turn on some switch. Maybe an important switch. BUT It could be that your application is in the “paused” state when that pin gets input which will cause a delay between when the pin is trying to send you input and when you actually process it.

    A real-time OS minimizes such delays (latency) so that you can respond quickly.