34 ms·
Show HN: Windows 98 in browser
- ank_the_elder 11y agoThat's amazing - do you have any info on the underlying implementation?
- g3 11y agoIt's a fully emulated PC: CPU, memory, hard drive, … The CPU especially took me very long to get right with all the details to run Windows 98. The code is here: https://github.com/copy/v86 https://github.com/copy/v86
- ank_the_elder 11y agoThanks for that
- unixhero 11y agoIncredibly impressive. Greetings and high fives from the intertubes.
- Someone1234 11y agoDo you worry that Microsoft might threaten you for the Windows 98 image? I don't think they make a cent from it anymore, but big companies and common sense aren't common bedmates.
- TazeTSchnitzel 11y agoSo far Microsoft haven't even sent me a C&D for https://win95.ajf.me/ https://win95.ajf.me/, and that site got media attention!
- zx2c4 11y agoNSA backdoor! https://github.com/copy/v86/commit/159f565de4dd99bff9b46c45aa7998ef35aa7168 https://github.com/copy/v86/commit/159f565de4dd99bff9b46c45a... Nope, Windows 98 undefined instruction.
- monocasa 11y agoYep! https://blogs.msdn.microsoft.com/oldnewthing/20041215-00/?p=37003 https://blogs.msdn.microsoft.com/oldnewthing/20041215-00/?p=...
- winter_blue 11y agoThis is amazing. Really great work. Thanks for building this.
- yitchelle 11y agoThis is the most impressive part! Well done! So in theory, we can run anything that a real PC can run, albeit a Win98 speced PC. Any takers to get the next generation in the Windows series to run on it. WinXP? I think. PS: Just came across the HN discussion around the said x86 emulator. https://news.ycombinator.com/item?id=6567967 https://news.ycombinator.com/item?id=6567967
- somecoder 11y agoBest part, it comes with scmpoo.
- livatlantis 11y agoDoesn't seem to work too well on Windows 10. It might be missing some DLLs. /s Super cool! (I really can't get it to click on anything though)
- triplem 11y agoYou can use the Lock mouse button. You will be able to click on what you want.
- michaelmior 11y agoThe Lock mouse button helped with my first problem which was that the emulated cursor seemed to be scaling its position based on the side of my browser window instead of the size of the emulated window. Locking the mouse fixed the position issue but I'm still unable to click on anything though.
- pan69 11y agoOnce you go into fullscreen mode it seems it work fine, but it took me a while to figure this out...
- livatlantis 11y agoAh right, thanks! Ctrl+R, regedit Now only if we had a version that could connect to the internet. Right now it tells me that it can't find a modem and that I should call MSN Technical Support! Cute.
- deleted 11y ago[deleted]
- jhauris 11y agoAmazing work.
- latenightcoding 11y agosheep.exe, hello old friend
- collinmanderson 11y agoI _totally_ remember it.
- apetresc 11y agoThe network interface doesn't seem to be configured – when I try to open the browser it wants me to install a modem. Is the VM just not configured for that, or do I need to do something? Would love to see what today's web looks like on '98 IE :)
- copy 11y agoIt's possible, Windows 98 has drivers for the NE2000 network card we're emulating (https://github.com/copy/v86/blob/master/src/ne2k.js https://github.com/copy/v86/blob/master/src/ne2k.js). However, currently the emulation isn't accurate enough, Windows 98 refuses to use it.
- duskwuff 11y agoThe bigger problem would be what to connect it to, and how. You can't make arbitrary outbound connections from Javascript.
- copy 11y agoWe're using this proxy script: https://github.com/benjamincburns/websockproxy https://github.com/benjamincburns/websockproxy
- iso-8859-1 11y agoI have a barely working HTTP proxy in client-side-JavaScript here: https://github.com/ysangkok/browser-http-proxy https://github.com/ysangkok/browser-http-proxy This allows you to connect to CORS enabled sites without using the WebSocket proxy. It talks HTTP on the serial port. I want to add SNI support to tlstunnel so that I can tunnel to google.com by navigating to https://google.com.mydomain/ https://google.com.mydomain/ and having the snitunnel tunnel to http://google.com http://google.com by reading the bottom-level domain names using SNI. Using this with browser-http-proxy, it would be possible to tunnel to HTTP sites on a request-based level (making it easier to scale) and without relying on tun/tap on the server. Also it could serve as a fallback for non-CORS enabled hosts.
- 11y ago
- fsiefken 11y agoWhat a coincidence, I was just thinking about how nice it would be if I could start a minimal javascript linux with toybox and start spacemacs with it (< 64M) and a small mounted filesystem somewhere. Win 3.11 in the browser would be nice too, there is a whole ecosystem of apps. Windows95b would be slower, but still faster and smaller then Windows98. I wonder how fast civ1 would run on freedos here.
- TazeTSchnitzel 11y ago95 in the browser has already been done (by me): https://win95.ajf.me/ https://win95.ajf.me/ That uses Em-DOSBox, which is more limited than v86 (which the OP uses) in some respects. I think v86 is loading hard disk sectors on-demand, which is pretty amazing compared to Em-DOSBox which has to download a massive disk image. On the other hand, Em-DOSBox has sound support! The Internet Archive has 3.11 in the browser: https://archive.org/details/win3_stock https://archive.org/details/win3_stock (there's also various 3.x games as well) This also uses Em-DOSBox.
- zero-g 11y agoWhere does one start with such thing? I mean, where do I read how to emulate CPU (or at least how CPU works, so I would be able to come up with how to emulate it by myself), how does PS/2 work, how to boot an image from BIOS?
- mtharrison 11y agoYeah, I always feel the same when I see similar things. How do you even start?
- khedoros 11y agoPersonally, I had some courses on computer architectures, and those covered the theory of how CPUs are constructed, how they run programs, etc. I decided to write an NES emulator. So: - Find Wikipedia articles, and learn that it used a variant of the MOS Technology 6502, which was used in a lot of computers in the 80s. - Find some digitized assembly programming manuals from the time (I think the one I used was distributed with the Commodore 64, and ended up having several typos introduced by OCR). - Write a tool to recognize, decode, and print out an operation when you feed it a little data - You basically need to set up a loop of fetching instructions, interpreting them, then doing what they say. An actual CPU runs in a similar loop, and it generally doesn't stop until power is removed, I think that after the classes I took, I read a lot of what other emulator writers said. This article is a basic look at the structure of an emulator, the theory behind them, and some different designs: http://fms.komkon.org/EMUL8/HOWTO.html http://fms.komkon.org/EMUL8/HOWTO.html
- TheOtherHobbes 11y agoOne of my friends at uni wrote a Z80 emulator/assembler in PDP-10 assembler as a hobby project - and he was studying chemistry, not CS... I don't understand why a basic understanding of CPU architectures isn't a CS fundamental everywhere. Even if you have no interest in emulating a CPU or an OS, you really do need to know what registers are, how caches work, what interrupts do, and how basic IO happens. At the very least it's a practical demonstration of one particular kind of VM, and - if you want to - you can generalise from that to VMs of your own design. For web apps, not understanding these things can get expensive. Cycles, even cloud cycles, aren't free, and if you take zero interest in optimisation and efficiency you're literally throwing money away.
- bchjam 11y agooh the irony, Win98 was the MS "internet as desktop" release. Least favorite OS ever Awesome project though!
- Someone1234 11y agoWindows ME was my most disliked OS (too buggy, even after service packs). I think the level of complexity finally hit the wall given the 9x series lack of good memory/file protections. My favorite 9x OS is 98 SE (which was a stand-alone release, not a service pack). But 98 "first edition" did add substantial features to 95: IE 4, multi-monitor support, sfc was added (which was useful because 9x got corrupted a LOT), ACPI support, better plug and play, and better hardware support overall. 98 SE just added USB support out of the box (which was a big deal for those of us trying to use USB mice), IE 5, WebDAV, Windows Explorer improvements, ICS, improved WMP, and all of 98 "first editions" hotfixes and updates. You could make 98 "first edition" into 98 SE more or less, but 98 SE was a nice thing to "just install" and have everything work. My 1990s/early 2000s OSs looked like this: 3.1, 95, 98, 98 SE, ME, back to 98 SE, and then 2000, XP SP1, and beyond. Skipped XP pre-SP1 as it was a pretty shoddy release compared to 2000 at the time, and ran away from ME screaming.
- fsiefken 11y agoDos6+Win 3.11, OS/2 2 and 3, Win98se were the best, XPsp3 as well. Win ME had one good thing going for it: window transparancy and alpha blending! For that reason I used it with a HMD, backstrapped laptop and webcam.
- baq 11y agoME lasted about 30 mins from installation to BSOD in my case. never tried again. my god that was ages ago.
- Joeri 11y agoI ran all of those windows versions as well, but my favorite remains NT4. I stuck with that for a long time, until the lack of drivers forced an upgrade. It was incredibly fast (smooth on a 66 mhz 486), rock-solid (uptimes of weeks with daily use), light-weight (32 MB RAM was doable, 128 MB was multi-tasking heaven). It's nice that MS is trimming down windows lately, but I keep thinking that it's a bit like seeing someone who has let themselves go get back on a diet. If they hadn't put on the weight in the first place, they would have never needed to lose it.
- fsiefken 11y agoHow would v86 compare to jslinux speedwise? http://bellard.org/jslinux/ http://bellard.org/jslinux/ ELKS in javascript would be nice as well, you would get the ultimate speedy portable unix ecosystem in the browser. https://github.com/jbruchon/elks https://github.com/jbruchon/elks
- copy 11y agoPoorly, see https://github.com/s-macke/jor1k/wiki/Benchmark-with-other-emulators https://github.com/s-macke/jor1k/wiki/Benchmark-with-other-e... Primarily due to the use of asm.js. I intend to implement a JIT similar to QEMU's tcg as soon as Web Assembly supports it: https://github.com/WebAssembly/design/blob/master/FutureFeatures.md#platform-independent-just-in-time-jit-compilation https://github.com/WebAssembly/design/blob/master/FutureFeat...
- s-macke 11y agoGreat work on your emulator. I am also looking forward to use webassembly for my emulator when available. However, I don't expect much speed improvement. I guess you can speed up your emulator significantly by putting in some '|0' noops to prevent deoptimizations into double precision.
- TazeTSchnitzel 11y agoHow does this compare to Em-DOSBox (e.g. https://win95.ajf.me/ https://win95.ajf.me/) in terms of speed?
- icoder 11y agostart->command->fail (command as in command.com)
- clock_tower 11y agoThis is awe-inspiring. I don't know what to say -- except that, if it was faster, I'd try to run Windows 98 in the browser of Windows 98 in the browser.
- Smushman 11y agoI am really impressed by this. I am sure you put a lot of labor into this project. You also seeded lots of ideas... Thank you.
- xhrpost 11y agoIt's stuff like this that makes me wish I had unlimited side project time. I think this could be fun to work on but my assembly/C level programming skills would need some serious ramp-up. Great work though!
- Smushman 11y agoAny suggestions on how to upload software? Could I use kermit, xmodem, ymodem, zmodem through com 1?
- vanattab 11y agoAre there license issues around this project? I doubt Microsoft would care to put the resources into enforcement of windows 98 licenses but I am just curious about the legality.
- mollmerx 11y agoEssentially you are being given a copy of a VM that has a copy of Windows pre-installed. It's unlikely (but possible) that Microsoft has granted a license for this. I imagine this is technically not legal, but as you say, unlikely to matter much.
- orionblastar 11y agoMicrosoft does not seem to bother with older software. It is because they don't support and upgeade it anymore. Microsoft only goes against piracy of software they still support and upgrade. They don't bother with the old software because it isn't worth it to sue or send a c&d letter because they don't earn an income with it anymore. So they don't lose income if someone pirates software they no longer sell. In fact they gave away the source code to an early MS-DOS and MS-Word as part of their own open source license. It is good PR for them if someone emulates their old software in the web browser and gives them free publicity.
- deleted 11y ago[deleted]
- deleted 11y ago[deleted]
- dheera 11y agoAnd here's me fighting with running Android ARM code on x86 ... I wish I had more time.
- andrewchambers 11y agoAnyone tried to make a plan9 in browser?
- dmitrygr 11y agoIt breaks horribly if you click start->run, type "command" and press enter
- copy 11y agoYep, unfortunately it seems to be a driver issue, because I'm having the same problem in QEMU. These are the drivers: http://www.navozhdeniye.narod.ru/vbe9x.htm http://www.navozhdeniye.narod.ru/vbe9x.htm
- agentultra 11y agoThis is actually really useful to me. I've been working on-and-off re-implementing Comic Chat using HTML5. It's nice having a working copy again to reference. The paper is great but it omits some details.
- yolesaber 11y agoComic Chat, like the program used to make jerkcity comics? Would be amazing to have a web version, best of luck!
- Theodores 11y agoThat is brilliant. Little things like being able to change the screen resolution and waste time on Solitaire - what more could one want!!! Works amazingly. Also it is quite a historical artefact, things like Active Desktop were truly cool back in the day. Plus the simplicity of the Win98 UI is a joy to return to. Congratulations!
- mbrock 11y agoThe start menu is pretty nice, compared to the awful "launch pad" style full-screen app menus that are now in OS X, GNOME, and Windows...
- nickysielicki 11y agoIs this legal? I'm surprised MS hasn't open-sourced NT 3.x already.
- fokinsean 11y agoThis blows my mind.
- runn1ng 11y agoDoesn't work on my Android phone, in Chrome. But I didn't expect it to :) Edit: for what it's worth, FreeDOS boots there. No way to put in keyboard input though.
- jasonlingx 11y agoWorks on my iPhone!
- zxexz 11y agoInstall Hacker Keyboard from fdroid (or the Play Store...). There's an option for a persistent notification that you can click, which will enable the keyboard wherever.
- bcook 11y agoBooted and works fine on my Nexus 9 running Chrome and Android Marshmallow (CyanogenMod 13).
- kaitnieks 11y agoRunning con\con works, too. Just like I remember it :)
- olavgg 11y agoHaha! That was the first thing I tried, had a good laugh again :-) I still remember you could crash remote computers by going into a public forum and post an image that linked to c:\con\con
- jhallenworld 11y agoBut is the A20 gate being properly emulated? :) I know a verification engineer who left AMD because he was tired of dealing with the ancient testbench which checked the ancient hardware. The browser should run in the hypervisor and provide a real hardware virtual machine. Provide both ARM and x86, one is emulated and one is real.
- copy 11y agoIt's not. I haven't come across any software that relied on it.
- striking 11y agoSomewhat infamously, GRUB failed on Intel Macs (in 2006?) because it tried to use the A20 gate, and Apple refused to emulate it. It's fixed now, though.
- userbinator 11y agoVery old (as in pre-386, or even pre-286) DOS software, written for the PC and only the PC, might depend on it. If I remember correctly, archive.org has a whole section devoted to ancient DOS software, so you might find something in there.
- deleted 11y ago[deleted]
- normac 11y agoThis is such a great demonstration of both how fast JS engines have become in the browser, and how much less efficient native software has become overall. Running on top of an x86 emulator in JavaScript, it's still faster to pop open a file browser and click around than it is on some modern smartphones.
- tkinom 11y agoI agree it is a very cool demo. Is there anyway I can find out the call flow of this JS program? Like to see the actual dynamic call flow graph instead of just simple static flow analysis output.
- tomc1985 11y agoThat's because the Win98 code is that much simpler. It has less to do with speed and more to do with complexity. Your phone is doing all sorts of weird shit behind your back as you poke about. Stuff that it's not supposed to be doing if app-makers were actually respectful of their users... On that note, why does that crap take so long on smartphones anyway?
- lukeadams 11y agoOne tweak that made my G2 feel much more responsive is simply turning down the UI animation length in Dev Settings. That's not to say that app developers don't love their non-native webview apps crammed to the brim with ads, though...
- tomc1985 11y agoUI animations have a lot to do with it, but I'm more referring to UI jank over simple stuff like 'enumerating a list of sharing targets' or 'swiping to the next page of the launchboard' when the phone is otherwise idle. Or, my favorites: the multi-second pause from unlocking my phone during a phone/skype call, or the taking of an actual eternity just to answer said fucking Skype call, of which half the time the call has already hung up once my phone is finally responding...
- laretluval 11y agoHow does it compare to Windows RG? http://www.deanliou.com/WinRG/ http://www.deanliou.com/WinRG/
- sangnoir 11y agoAny tips on how I can reliably trigger a BSOD? For old time's sake.
- Analemma_ 11y agoOpen the Run panel and try to go to "C:\con\con". Instant BSOD. (This was an old trick I used to do as a bratty kid when people left their computers unlocked. Nice to see that it still works!)
- agentgt 11y agoYou can also just shutdown (ie click start and then select shutdown) that caused a BSOD for me. I found this very ironic.. It died while trying to die.
- tomc1985 11y agoThe mouse cursor doesnt work.... my system's real cursor is still onscreen and the emulator is doing a very poor job of tracking my movements, and its not intercepting clicks or anything like that either. None of the toy 'show HN' emulators that have popped up have a properly working mouse cursor....
- darryl42 11y agoIt worked after clicking on lock mouse. Using the latest firefox.
- tomc1985 11y agoThat works. Chromium 47 here
- boyaka 11y agoDid you try the lock cursor button? A lot of times in Windows VMs I have to go disable mouse acceleration, but it doesn't seem this version of Windows 98 has that option.
- te_platt 11y agoVery nice. Although opening IE and trying to go to http://copy.sh/v86/?profile=windows98 http://copy.sh/v86/?profile=windows98 gave an error. Go figure...
- nandhp 11y agoSomeone needs to port SLiRP to JavaScript+CORS.
- EwanG 11y agoSo pulled this up from my Chromebook - rather interesting to have Chrome running Windows rather than the other way around. Of course the big leap will come when it gets Win XP up and running and then folks will have an answer for their legacy systems...
- kelvin0 11y agoRespect! This and Fabrice Bellard's emulator have me in awe. http://www.bellard.org/jslinux/ http://www.bellard.org/jslinux/ It's even more painful when I know that technically I should be able to do the same, but have not yet done it ...
- tomc1985 11y agoHow bad is it that Windows 98, running in a ^%%^@#!ing emulator, in my browser no less, runs better than the latest versions of Android OR iOS?
- vkou 11y agoI'm on a beefy 12-core 'nix box with 64 GB of RAM, and this emulator is extremely sluggish for me. Perhaps because it doesn't run well for everyone?
- tomc1985 11y agoOh, I wouldn't call this emu fast... but its still faster than a lot of smartphones I encounter
- rtpg 11y agouhh it doesn't? Maybe it runs way better than the android or iOS emulators but you have to have a pretty messed up install of recent Android to make it run as slow as this.
- Mizza 11y agoThe inclusion of eSheep is an absolute stroke of genius.
- deleted 11y ago[deleted]
- toyg 11y ago"My Briefcase" could have been Dropbox, 10 years earlier, if only 1) it could work decently, which it never did, and 2) had an option to sync to MS servers. Bandwidth was an issue at home, back then, but for offices it would have been fine.
- Spooky23 11y agoIn the age of 4.3 GB drives that cost $750, unlikely.
- toyg 11y agoIt was also the age of the average file being 20kb though. You could have provided 50mb per user and the world would have gone "woah".
- ManlyBread 11y agoI remember how amazing it was when the email accounts went from 20mb max size to something like 500mb, it blew my mind and gave rise to many services that capitalized on this huge amount of space (mostly peer-to-mail and an application that turned gmail accounts into a dropbox kind of thing).
- rhplus 11y agoMicrosoft spun its wheels a lot with file-syncing in the mid-2000s. Aside from the stuff coming from Office (Groove, etc) and Windows (folder-shadowing, BITS, etc), there was a slew of inter-related products in the consumer space starting with the acquisition of FolderShare. By the time DropBox launched, it had become Mesh.com, with PC-to-PC syncing and online storage, but thanks to internal competition and constant rebranding/repositioning, it slowly became deprecated and subsumed by SkyDrive/OneDrive. https://en.wikipedia.org/wiki/Windows_Live_Mesh https://en.wikipedia.org/wiki/Windows_Live_Mesh
- hanief 11y agoMinesweeper! Ah, the nostalgia. A note: the mouse position and acceleration seems to not be mapped correctly. It is often separated away from my local desktop mouse position. Maybe because the screen resolution is different?
- tempestn 11y agoI'm having the same issue. It makes it difficult to do anything, because I would need to move my actual mouse pointer past the edge of my monitor to get to any of the icons or start menu with the virtual mouse.
- gwbas1c 11y agoYou gotta lock the mouse. Most likely, something's emulating a physical mouse input, which is inexact.
- Svenskunganka 11y agoClick the lock mouse button
- z1mm32m4n 11y agoMy first laptop was a 10 year old hand me down Windows 95 laptop (literally, as old as me) that I used just to play Space Cadet Pinball. I can't believe they took it out of Windows 98; what a great game haha
- danjayh 11y agoWindows before 30 years of updates that were created with a need to maintain backwards compatibility feels so cohesive. I mean, that control panel is just so clean. Also, would be interested in seeing the orginal Win 95 (before OSR2). It was way way faster than win 98.
- TazeTSchnitzel 11y agoThe control panel in newer versions could still be that clean if Microsoft hadn't tried to reinvent it three times (XP, Vista, 8). Of course, the 9x control panel is, in a way, a reinvention of the 3.x control panel. It's just a very clean one, because the 3.x control panel was a window full of icons, and the 9x control panel is an Explorer window full of icons.
- executesorder66 11y agoThis reminded me of www.windows93.net
- w84t1me 11y agoIt would be fun to see the BSOD in my browser just for nostalgia.
- fibo 11y agoAwesome, it works also on my Windows phone browser ( that is Internet Explorer :)
- 72deluxe 11y agoThis is really impressive, and also brings back waves of nostalgia as I used to use Windows 98 (and 95 and 3.11 before that) as my daily driver. I like how the cloud icons at the side of Explorer when not in classic mode still are drawn with a white background even if you change the colour scheme. On a real machine, when I look at this old system I realise how little we have moved on in UI terms or the basic needs and requirements of a computer. You could do 99% of what you need to do on an old computer, other than duff website rendering and horrible security and power usage.
- tomkin 11y agoDude, I'm just trying to align text in CSS, and you're all like "here's an OS in js."
- chdir 11y agoLet's see, now I can browse : IE in Win98 in Chrome in Ubuntu in VMWare in Win7