Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web UI: basic SYSCALL support #1224

Open
1 of 2 tasks
lupino3 opened this issue Feb 9, 2025 · 2 comments
Open
1 of 2 tasks

Web UI: basic SYSCALL support #1224

lupino3 opened this issue Feb 9, 2025 · 2 comments

Comments

@lupino3
Copy link
Member

lupino3 commented Feb 9, 2025

partial SYSCALL support - no File I/O

  • fd 1 output via Web UI
  • fd 0 input via Web UI
@lupino3 lupino3 added this to the Web UI: Alpha Version milestone Feb 9, 2025
lupino3 added a commit that referenced this issue Feb 9, 2025
Contributes to Web UI: basic SYSCALL support #1224
lupino3 added a commit that referenced this issue Feb 9, 2025
* fix: add a simpler sample program

Fixes Web UI: load a simpler example by default #1227

* feat: implement stdout for Web UI

Contributes to Web UI: basic SYSCALL support #1224
@lupino3
Copy link
Member Author

lupino3 commented Feb 9, 2025

Standard Input will be more complicated than just having a prompt() call. The Java code runs in a web worker, which does not have access to the window object. I tried using prompt() and alert() and it fails miserably.

@lupino3
Copy link
Member Author

lupino3 commented Feb 9, 2025

We could add a new StdIn section with a text area, and as soon as a character is added to the text area it's sent to the worker as part of the stdin. Then when SYSCALL 3 happens to read from fd 0, it reads from that stdin buffer. This would remove the need for interactive input being triggered by the web worker.

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

No branches or pull requests

1 participant