What is Memory Mapped I/O? (16-Bit VM in JavaScript 005)

preview_player
Показать описание
This this episode we implement memory mapped I/O, where the address space is utilised as common bus for components to communicate.

=[ ℹ About ℹ ]=

This series is all about building a powerful virtual machine in JavaScript with the following features:

- A flexible, extensible, register-based virtual machine
- Support for signed, unsigned and floating point operations
- A call stack
- Interrupt capabilities
- Ability to do memory mapping for IO
- An assembly language with macro and module support
- A higher level, C like language. We'll use and expand the library from the parser combinators from scratch series
- And finally, to be able to take the whole thing into the browser and exend it to create a sort of fantasy console - an emulator for a machine that never existed

=[ 🔗 Links 🔗 ]=

Рекомендации по теме
Комментарии
Автор

A few years ago i was working on a toy PS1 emulator. I had to stop working on it after a while because it got to be too much to come home from working as a software engineer, to work on software engineering projects. It just made me start to hate my hobby that I've loved since i was a teen.

Anyhow, I just stumbled on this playlist earlier this year and finally sat down to watch it tonight, and I'm really happy to see that my approach to handling devices and memory mapping wasn't completely insane.

Granted, I was writing my VM in C11, so maybe it was still a little insane. But still, I feel slightly vindicated.

Awesome work, and thanks for sharing.

garrettbates
Автор

I'm taking a senior class where we are implementing a VM and I chose javascript (node) as my language. This series has helped me get my head around where to start, keep it up!

eebilu
Автор

Love it, can't wait for the ASM to be done so we can get on with writing a game

mladjo
Автор

Man, this is so exciting. I don't remember when was the last time that I followed along with a coding tutorial with this excitement. It's been a while since I haven't learned that many new things in a tutorial as condensed as this one. Tutors must get inspiration from your way of tutoring because nowadays I feel like every video tutorial is just beating around the bush.
I'm also learning the Zig language with this great project, using another language while following JavaScript also shows the problematic solutions JavaScript offers! I can't thank you enough

cagataykaydr
Автор

I was having so much trouble understanding what was actually going on with the code... Especially for debugging. Now I ended up using VSCode's debugger and it helped me tremendously. Great videos! thanks a lot for them <3

giuxbr
Автор

Huh, this will take me some time to process this video and I think after finishing VM I'll re-watch all videos from first to make sure that I really got the idea behind it. Also, idea of visualization looks so handy, that I think I'll try to do it on my own

EvilFlipTV
Автор

How would multithreading be implemented in the vm? Just by starting up a new Cpu class instance?
Looking forward to the next episodes :)

-P
Автор

dude... your channel is really flippin' cool. you mentoring anyone?

meekmtck
Автор

Ok, why i didn't discover this channel earlier ?

frankeke
Автор

Are you alive ? Can't wait for the next episode

frankeke
Автор

the memory mapper is in charge of communicating with different devices like gpu, keyboard, mouse, hard drive... right? In case of a hard drive, how would that work? imagine you have a 1gb ram, and your hard drive is 100gb, how would you be able to map 100gb addresses into the 1gb ram?

jordixboy
Автор

nice series i like it. :)
 
but a question, in your createScreenDevice class the methode setUint16 uses modular and div for the x and y coordinates. is it not a bit inefficient, i think for a 16x16 screen an and and a bit shifting is a bether idea. like so ''' int x = (addr & 0xf0) >> 8; int y = (addr & 0x0f); . what do you think about it? idk to much about java but for me its a bit clearer to understand what it makes and i think it is a bit faster.

hecatonecles
Автор

Great contents! But one question, while migrate to MM, the setUint8 method -- which is overridden by screen device -- updates the view only, how is the data written back to memory? Thank you again!

carnivionhan
Автор

Would it be possible to bump up the code font size for better readability? Love your content!

ErikShestopal
Автор

There's no link to escape codes in the description as you mentioned around 10:30

tomster
Автор

Someone tried this in Java, i don't understand this episode.

devhonking
welcome to shbcf.ru