Skip to content

Touch command attempt#23

Open
shivas wants to merge 1 commit into
Zeal8bit:mainfrom
shivas:touch-command
Open

Touch command attempt#23
shivas wants to merge 1 commit into
Zeal8bit:mainfrom
shivas:touch-command

Conversation

@shivas

@shivas shivas commented Jan 23, 2024

Copy link
Copy Markdown

Can you point me to what would be the cause that the returned error code is not printed, it's 0xEE (looking at the emulator)

@shivas shivas changed the title WIP version Touch command attempt Jan 23, 2024
@Zeal8bit

Copy link
Copy Markdown
Owner

The OPEN syscall returns the negated error on failure (As documented here https://github.com/Zeal8bit/Zeal-8-bit-OS/blob/main/kernel_headers/z88dk-z80asm/zos_sys.asm#L208)

So in your case you should use neg instruction in your label _touch_error. As such when it returns 0xEE, the returned error is ERR_READ_ONLY (0x18).

Seems like you tried to use touch on a file on the romdisk 😉

@shivas

shivas commented Jan 25, 2024

Copy link
Copy Markdown
Author

ok, then it's expected, as I was indeed doing that on romdisk

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

Successfully merging this pull request may close these issues.

2 participants