Clock
OS in Rust
Your Task
- Implement a clock.
- Somehow track ticks from the timer.
- Set the initial time from the keyboard.
- Provide hours, minute, seconds.
- Don’t worry about overly testing, put test at least seconds.
- You don’t have to get the clock ticks exact, approximate is fine.
Requirements
- On boot, display a prompt requesting current time.
- Accept 6 decimal digits of a well-formatted time.
- Delineate however you like - just include it in the prompt.
- I used
SpaceBarto separate hours, minutes, seconds and also terminate.
- Once the 6 decimal digits are input, clear the screen and display a single line of
- Six decimal digits.
- You can format it or whatever, up to you.
- Even use colors I guess.
- It should start at the input time and increase (roughly) every one second.
Aside
- I think you’ll want to diverge significantly from your baseline OS for this, so when you make a new crate and copy things over, you’ll probably want to do any improvements to your OS first, or at least keep anything you learn in mind going into next week.