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

Technical questions #1

Open
maksimKorzh opened this issue Sep 25, 2021 · 1 comment
Open

Technical questions #1

maksimKorzh opened this issue Sep 25, 2021 · 1 comment

Comments

@maksimKorzh
Copy link

maksimKorzh commented Sep 25, 2021

Hi Keyhan!

I'm very impressed with this project!
I've developed my own tiny OS inspired by bootos.
The only 'development environment' it supports is a hex editor that allows to input machine codes directly into memory.
I then run those commands via a far jump.
Now the problem is that hand assembling is quite painful and I was looking for a way to come up with a tiny assembler,
but since the size of apps for my OS is limited to 512 bytes it seemed impossible to find an assembler of that size but then
I eventually found your project. Could you please kindly answer a couple of tech questions?

  1. Do I understand correctly that asm source file is loaded from floppy image?
  2. If so - what's the address for that and can I point SI there to make assembler processing what I've typed from keyboard?
  3. And instead of writing machine codes back to floppy I'd like to write to memory (for later execution)

Is it possible?
If so and if I'm smart enough can I use 0asm in my OS project? (it's not commercial obviously and I'm running it for youtube video purposes)

THANKS IN ADVANCE!

@maksimKorzh
Copy link
Author

Hooray! I've managed to adopt 0asm to work interactively under my own OS!
Here's the video demonstrating how 0asm works like a charm under GameOS:
https://www.youtube.com/watch?v=a4N-RAPSnAg

What I've changed in 0asm:

  1. Source code is entered from the tiny code editor I made and stored from 0x0000_1a000 and up to 0x0000_4000, so no more limitation of 512 bytes for a source
  2. 0asm now points SI to 0x1a00 directly without loading source from file
  3. It then copies the bytes from 0x0000_6d00 to 0x0000_0500 (+ offset if specified) which is the scope of a hex editor on GameOS
    I can then store the bytes and run in a boot sector!
    I'm very grateful for your work!
    Thanks for creating 0asm!

Sources (in case if you're interested):
GameOS: https://github.com/maksimKorzh/GameOS
Adopted 0asm: https://github.com/maksimKorzh/GameOS/blob/main/src/GameOS-dev-pack/assembler.asm
(see 'CMK:' labeled comments for changes)

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

No branches or pull requests

1 participant