Here is an example of my work (the sort of thing I do for fun :)
The Amstrad CPC was a popular 8-bit machine from the 1980s based on the Z80 CPU architecure. I decided to have a go emulating it a couple of years ago, firstly to learn how an emulator works and secondly to capture some nostalga.
I had to learn how to emulate the Z80 CPU, the CPC custom chip (gate array), the Motorola CRTC 6845, the keyboard controller, memory architecture, i/o controller chip and an old school cathode ray tube
So here is a classic game of 'Dizzy', using my emulator in a web-browser. Press the 'Spacebar' to start a game, and the use 'Space' to jump, 'Z' to go left, and 'X' to go right. Press 'Control', 'Shift' and 'Escape' together to reboot the machine into BASIC!
Here is the source code for your perusal. All code is licenced under the GPLv2.