Skip to content

Universal PS/2 & COM (Serial) Mouse Driver - #122

Open
ehedjjs987-jpg wants to merge 1 commit into
PRoX2011:devfrom
ehedjjs987-jpg:dev
Open

Universal PS/2 & COM (Serial) Mouse Driver#122
ehedjjs987-jpg wants to merge 1 commit into
PRoX2011:devfrom
ehedjjs987-jpg:dev

Conversation

@ehedjjs987-jpg

Copy link
Copy Markdown

Changes:

  • Upgraded the mouse driver to support Microsoft Serial Protocol via COM ports.
  • Added auto-detection logic: attempts to initialize PS/2 first, then falls back to COM1 (0x3F8, IRQ4), and finally COM2 (0x2F8, IRQ3).
  • Implemented UART initialization, 1200 baud 7N1 setup, and 'M' byte identification for serial mice.
  • Added com_interrupt_handler to decode 3 byte serial packets and unify the coordinate logic with the existing PS/2 cursor system.
  • Code Standards: Refactored function and variable names to snake_case to follow CONTRIBUTING.md.

Testing:

  • Tested in 86Box and Qemu emulator.
  • Verified PS/2 mouse functionality (no regressions).
  • Verified Serial Mouse initialization and movement on COM1 and COM2.
  • Screen boundaries, visual selection, and button clicks work flawlessly.
  • Note: I used an AI assistant to help generate the assembly syntax and standard boilerplate, but I fully controlled the logic and thoroughly tested the hardware behavior in the emulator to ensure stability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant