rust-osdev / rust-osdev/ps2-mouse
Don't use callback functions
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 14
- Forks
- 9
- PR merge metrics
- No merged PRs in 30d
Description
Using callback functions can be complicated and inflexible. I think the way pc-keybaord does it is much better, where you give it a u8 and it will return an Option with the decoded event. https://docs.rs/pc-keyboard/0.8.0/pc_keyboard/struct.Keyboard.html#method.add_byte
I can make a PR for this.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the existing ps2-mouse input API and comparing its callback model with pc-keyboard 0.8.0's Keyboard::add_byte behavior. Determine the public API and event-decoding changes needed so callers provide a u8 and receive an Option containing the decoded event; done means the callback approach is replaced consistently and the library's tests or examples pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- embedded-iot
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100