Embedded Systems — question 9 of 10
Write a real answer. It is graded against the question's rubric, and the mastery movement is computed by the same engine the product uses. Scoring here is deterministic rather than model-written, so this page costs nothing to run and nothing is saved. In a track built from your own posting, the same rubric is graded by the model, which is what produces feedback about your reasoning rather than about coverage.
This is the canonical priority inversion scenario used to test whether a candidate understands scheduling interactions beyond simple priority ordering.
You have three tasks in an RTOS: a low-priority task that periodically takes a mutex to write to a shared log buffer, a high-priority task that also needs that same mutex briefly, and a medium-priority task that runs a CPU-heavy computation with no locking at all. In testing, you notice the high-priority task occasionally misses its deadline by tens of milliseconds even though its own work takes only microseconds. Explain what's happening and how you'd fix it.