{"id":23586522,"url":"https://github.com/doctorwkt/fuzemsys","last_synced_at":"2025-11-03T10:30:38.972Z","repository":{"id":230485231,"uuid":"779511977","full_name":"DoctorWkt/Fuzemsys","owner":"DoctorWkt","description":"FUZIX Compiler Kit Emulators with Syscall Support","archived":false,"fork":false,"pushed_at":"2024-05-16T05:25:51.000Z","size":1184,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-12-27T04:11:56.534Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DoctorWkt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-03-30T02:41:45.000Z","updated_at":"2024-06-05T17:10:33.000Z","dependencies_parsed_at":"2024-04-28T01:57:27.057Z","dependency_job_id":"67b15bc9-3566-4fd3-a6a9-47990fea419c","html_url":"https://github.com/DoctorWkt/Fuzemsys","commit_stats":null,"previous_names":["doctorwkt/fuzemsys"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DoctorWkt%2FFuzemsys","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DoctorWkt%2FFuzemsys/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DoctorWkt%2FFuzemsys/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DoctorWkt%2FFuzemsys/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DoctorWkt","download_url":"https://codeload.github.com/DoctorWkt/Fuzemsys/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239412451,"owners_count":19634016,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-27T04:11:29.377Z","updated_at":"2025-11-03T10:30:38.939Z","avatar_url":"https://github.com/DoctorWkt.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Fuzemsys\n\nThis is a spin off of the emulators in the\n[Fuzix Compiler Kit](https://github.com/EtchedPixels/Fuzix-Compiler-Kit);\nI am adding\nFUZIX system call support to them. Eventually (hopefully) the changes will\nget merged back into the Fuzix Compiler Kit.\n\n## Usage\n\nFirstly get:\n\n+ https://github.com/EtchedPixels/Fuzix-Bintools\n+ https://github.com/EtchedPixels/Fuzix-Compiler-Kit\n\nCompile Bintools and install into `/opt/fcc`, then compile the compiler kit\nand install there as well.\n\nDo a `make; make install` here to build the 6809 and Z80 emulators and install\nthem into `/opt/fcc/bin/`. This will also install the 6809/Z80 include files\nand the 6809/Z80 libraries.\n\n## Tests\n\nWith the emulators installed, change into the `tests` directory and do a\n`make -f Makefile.6809` to build the 6809 test executables. Now, for example, you can run:\n\n```\n$ emu6809 test001\n```\n\nand you should see \"Hello world\" written to standard output. There is a `Makefile.z80`\nas well for the Z80 test executables.\n\nThere is a `runtests` script in `tests/` that runs the executables using\na specific emulator and checks that they behave as expected. Example:\n\n```\n$ ./runtests 6809    (or ./runtests z80)\ntest001.c: OK\ntest002.c: OK\ntest003.c: OK\n...\ntest032.c: OK\n```\n\n## Commands\n\nThere are some commands in the `cmds/` directory which will run under the\nemulator. Use the appropriate `Makefile` for the CPU that you wish. See below about emulated filesystems.\n\n## Emulator Usage\n\nThe `emu6809` and `emuz80` emulators have support for map files and include a built-in monitor.\nHere are the usage details for `emu6809` (the same as `emuz80`):\n\n```\nUsage: emu6809 [-M] [-d logfile] [-m mapfile] [-b addr] executable \u003carguments\u003e\n\n\t-d: write debugging information to logfile\n\t-m: load a mapfile with symbol information\n\t-M: start in the monitor\n\t-b: set breakpoint at address (decimal or $hex)\n\n\tIf the FUZIXROOT environment variable is set,\n\tuse that as the executable's root directory.\n```\n\nand here are the monitor instructions:\n\n```\nMonitor usage:\n\ns, step \u003cnum\u003e             - execute 1 or \u003cnum\u003e instructions\nx, exit                   - exit the monitor, back to running\nq, quit                   - quit the emulation\ng, go \u003caddr\u003e              - start execution at address\np, print \u003caddr\u003e [\u003caddr2\u003e] - dump memory in the address range\nd, dis \u003caddr\u003e [\u003caddr2\u003e]   - disassemble memory in the address range\nw, write \u003caddr\u003e \u003cvalue\u003e   - overwrite memory with value\nb, brk [\u003caddr\u003e]           - set instruction breakpoint at \u003caddr\u003e or\n                            show list of breakpoints\nwb, wbrk \u003caddr\u003e           - set a write breakpoint at \u003caddr\u003e\nnb, nbrk [\u003caddr\u003e]         - remove breakpoint at \u003caddr\u003e, or all\n\nAddresses and Values\n\nDecimal literals start with [0-9], e.g. 23\nHexadecimal literals start with $, e.g. $1234\nSymbols start with _ or [A-Za-z], e.g. _printf\nSymbols + offset, e.g. _printf+23, _printf+$100\n```\n\n## Emulated Filesystems\n\nThe emulators have the concept of an emulated filesystem. Go into\nthe `cmds` directory and do a `make install`. This will create two\ndirectories, `build/6809/` and `build/z80/` at the top level of the\nrepository. Each one contains a `bin/` directory with the available\napplication binaries.\n\nNow set the `FUZIXROOT` environment to one of the \"build\" directories, e.g.\n\n```\nexport FUZIXROOT=\u003cmumble\u003e/build/z80\n```\n\nYou can now `cd $FUZIXROOT` and start an emulated shell up:\n\n```\ncd $FUZIXROOT\nemuz80 bin/sh\n$\n```\n\nThe `$` sign is the emulated shell prompt. From here you can explore\nthe emulated filesystem, e.g.\n\n```\n$ ls -l\ndrwxr-xr-x   2 1000     1000         4096 May 08 03:56 bin\n$ cd bin\n$ ls -l\n-rwxr-xr-x   1 1000     1000        23970 May 08 03:56 ar\n-rwxr-xr-x   1 1000     1000        10551 May 08 03:56 banner\n-rwxr-xr-x   1 1000     1000         5669 May 08 03:56 basename\n-rwxr-xr-x   1 1000     1000         7781 May 08 03:56 cal\n-rwxr-xr-x   1 1000     1000         1931 May 08 03:56 cat\n-rwxr-xr-x   1 1000     1000         5453 May 08 03:56 cmp\n-rwxr-xr-x   1 1000     1000        29256 May 08 03:56 cpp\n-rwxr-xr-x   1 1000     1000        10849 May 08 03:56 cut\n-rwxr-xr-x   1 1000     1000         8933 May 08 03:56 date\n...\n-rwxr-xr-x   1 1000     1000        10203 May 08 03:56 sh\n-rwxr-xr-x   1 1000     1000        18139 May 08 03:56 sort\n-rwxr-xr-x   1 1000     1000        13611 May 08 03:56 tail\n-rwxr-xr-x   1 1000     1000        11693 May 08 03:56 tsort\n$\n```\n\nFilenames starting with `/` are translated to start with `$FUZIXROOT`.\nThe exception are emulated binaries that don't exist. For example,\nthere is no `vi`. From within the emulator, if you try to run `/usr/bin/vi`\nfrom the shell then:\n\n - the exec of `$FUZIXROOT/usr/bin/vi` fails\n - instead, we try to exec `/usr/bin/vi` which succeeds\n\nThis allows you to run native binary executables from within the emulators\nas well as the emulated binary executables.\n\nThe emulated shell has an implicit `PATH` which is `/bin:/usr/bin`.\nSo you can simply type in `vi` and the shell will run the native `vi`\nwhich lives in `/usr/bin`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdoctorwkt%2Ffuzemsys","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdoctorwkt%2Ffuzemsys","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdoctorwkt%2Ffuzemsys/lists"}