Live data from Hacker News

Run Windows 1.01 in your browser

jsmachines.net

41–50 of 93 posts

Re: Run Windows 1.01 in your browser

#46
post #27

As there seems to be a lot of interest in emulators in the browser, here's my effort: I ported an emulator for classic Mac and IBM PC to the browser. Mac System 7 Demo: http://jamesfriend.com.au/pce-js/ Windows 3.0 Demo: http://jamesfriend.com.au/pce-js/ibmpc-win/ IBM PC doesn't have mouse support... Yet. For Mac OS it's writing the mouse position directly into memory, but I've yet to add that hack for Windows.

Pretty cool, any chance they might end up on Github?

Yeah, I'll put it up on GitHub once I've had time to clean up the build process to separate the new code from the dependencies (which I've had to hack extensively). In the meantime here's a dump of the source: http://jamesfriend.com.au/pce-js/pcejs20131028.zip

Re: Run Windows 1.01 in your browser

#47
post #29

Every time I see an emulator like this on HN, my mind is blown. Can someone explain to me and any other run-of-the-mill hackers reading this, how an emulator like this is made? I wouldn't even know where to start.

First you need to port x86(or any other) instruction set. This can also be done by compiling (part of)Bochs/PCE using emscripten. Then you need to port IO (floppy,HD etc.). Then monitor and graphics card. And if you really want to be cool there are hosts of other things to port like touchscreen, networking, USB etc.

Re: Run Windows 1.01 in your browser

#48

There is some issue with the mouse. When I click on terminal.exe and try to click on "File", the mouse is coming out of the emulator. You would probably want to create an interface like a VM, where the mouse comes out of the emulator only when you press some combination of keys.

[deleted]

Re: Run Windows 1.01 in your browser

#49

Even better, Zork: http://jsmachines.net/disks/pc/games/infocom/zork1/ And it appears to save your state between runs, which is nice.

So that's:

1. Zork

2. running in the Infocom Virtual Machine

3. running in an IBM PC emulator

4. running in Javascript

6. running in x86 machine code

and x86 maintains backwards compatibility with that original IBM PC through

7. hardware instruction set translation

It's nice to know all those transistors aren't sitting idle.

Re: Run Windows 1.01 in your browser

#50

As there seems to be a lot of interest in emulators in the browser, here's my effort: I ported an emulator for classic Mac and IBM PC to the browser. Mac System 7 Demo: http://jamesfriend.com.au/pce-js/ Windows 3.0 Demo: http://jamesfriend.com.au/pce-js/ibmpc-win/ IBM PC doesn't have mouse support... Yet. For Mac OS it's writing the mouse position directly into memory, but I've yet to add that hack for Windows.

Awesome, can play gorillas in qbasic :D
Post reply on HN