Skip to content

[cmds] Display mouse port being opened on mouse command#2226

Merged
ghaerr merged 1 commit intomasterfrom
mouse
Feb 15, 2025
Merged

[cmds] Display mouse port being opened on mouse command#2226
ghaerr merged 1 commit intomasterfrom
mouse

Conversation

@ghaerr
Copy link
Copy Markdown
Owner

@ghaerr ghaerr commented Feb 15, 2025

As discussed in ghaerr/microwindows#106 with @toncho11, the mouse command will now display the mouse port being used when started.

In addition, Nano-X will display the mouse port on startup. Properly configured, this "message" will display on either /dev/ttyS0 when running on QEMU, or /dev/console otherwise. Because nano-X clears the screen to graphics mode, the mouse message may be erased quickly and not be seen (along with any other error or informative messages). For this reason, it is recommended that emulators set the mouse port to /dev/ttyS1 (along with MOUSE_PORT=/dev/ttyS1) and console output to /dev/ttyS0 so that messages can be seen.

Here's a pre-built image with both fixes for testing.
fd2880.img.zip

@ghaerr ghaerr merged commit fc3f9e0 into master Feb 15, 2025
@ghaerr ghaerr deleted the mouse branch February 15, 2025 00:47
@toncho11
Copy link
Copy Markdown
Contributor

So /dev/ttyS1 should be COM2 on windows? My emulator uses COM1, COM2 ...

@ghaerr
Copy link
Copy Markdown
Owner Author

ghaerr commented Feb 15, 2025

So /dev/ttyS1 should be COM2 on windows? My emulator uses COM1, COM2 ...

I'm not sure your question here, but the general idea is to map "COM1" (/dev/ttyS0) to the host Terminal, and "COM2" (/dev/ttyS1) to the emulator MS mouse. Then set MOUSE_PORT=/dev/ttyS1. If it is not possible to attach COM1 to the host terminal, that is still OK, you can still attach the emulator mouse to COM2, right?

@toncho11
Copy link
Copy Markdown
Contributor

toncho11 commented Feb 15, 2025

mouse says /dev/ttyS0
I can not change it with MOUSE_PORT=/dev/ttyS1
If I set COM2 in the emulator mouse does not work (because it is not ttyS1)
I can not figure it out.

@toncho11
Copy link
Copy Markdown
Contributor

MOUSE_PORT=/dev/ttyS1
or
export MOUSE_PORT=/dev/ttyS1

does not work.

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.

2 participants