Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
c159d55
GEMDRIVE: report write and program-load errors instead of looping or …
diegoparrilla Dec 2, 2026
f9490eb
GEMDRIVE: report running out of memory or handles as such
diegoparrilla Dec 2, 2026
96fcfb6
GEMDRIVE: accept Fforce of a standard handle onto its files
diegoparrilla Dec 2, 2026
4c957e9
GEMDRIVE: answer only the directory searches it started
diegoparrilla Dec 2, 2026
3a58a37
GEMDRIVE: a finished listing leaves the program's buffer alone
diegoparrilla Dec 2, 2026
7ffc155
GEMDRIVE: decide Pexec by the program, not the current drive
diegoparrilla Dec 2, 2026
aa49adf
GEMDRIVE: a directory search leaves the current drive alone
diegoparrilla Dec 2, 2026
df6f6f8
GEMDRIVE: Fattrib in set mode answers with the attributes it was given
diegoparrilla Dec 2, 2026
b5e40f1
GEMDRIVE: starting a program from a program no longer bombs TOS 1.00
diegoparrilla Dec 2, 2026
3aa9428
GEMDRIVE: a search ends with the process that started it
diegoparrilla Dec 2, 2026
b1a9e58
GEMDRIVE: a program gets the memory its header asks for
diegoparrilla Dec 2, 2026
ea20efb
GEMDRIVE: p_flags from GEMDOS $1700 on, as TOS's own loader
diegoparrilla Dec 2, 2026
87b2e0b
Trap hooks: a user-mode call is read where it is, on a 68030 too
diegoparrilla Dec 2, 2026
5d15c6f
Senders: a 68030's instruction cache is cleared after the wait loop's…
diegoparrilla Dec 2, 2026
a2bdf57
Senders: the instruction-cache clear never runs on a 68000
diegoparrilla Dec 2, 2026
058b248
Drivers: a read into memory clears a 68030's instruction cache
diegoparrilla Dec 2, 2026
47f772e
GEMDRIVE: find a name the way GEMDOS cuts it to 8.3
diegoparrilla Dec 2, 2026
5cd40d7
emu_check.py: TOS 1.00 and 1.02 setups on request
diegoparrilla Dec 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
230 changes: 189 additions & 41 deletions rp/src/gemdrive.c

Large diffs are not rendered by default.

201 changes: 101 additions & 100 deletions rp/src/include/devops_acc.h

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions rp/src/include/gemdrive.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
#define GEMDRIVE_CMD_FSEEK_CALL (0x42 + GEMDRIVE_APP)
#define GEMDRIVE_CMD_FATTRIB_CALL (0x43 + GEMDRIVE_APP)
#define GEMDRIVE_CMD_DGETPATH_CALL (0x47 + GEMDRIVE_APP)
#define GEMDRIVE_CMD_FFORCE_CALL (0x46 + GEMDRIVE_APP) // Fforce of a standard handle
#define GEMDRIVE_CMD_PEXEC_CALL (0x4B + GEMDRIVE_APP)
#define GEMDRIVE_CMD_PTERM_CALL (0x4C + GEMDRIVE_APP)
#define GEMDRIVE_CMD_FSETDTA_CALL (0x1A + GEMDRIVE_APP)
Expand Down Expand Up @@ -89,6 +90,14 @@
#define GEMDRIVE_DTA_F_FOUND_OFFSET 0x10A4 // 4 bytes (0 = found)
#define GEMDRIVE_DTA_TRANSFER_OFFSET 0x10A8 // 44 bytes (DTA_SIZE)
#define GEMDRIVE_DTA_TRANSFER_SIZE 44
// Written into the DTA GEMDRIVE fills, at offset 2 (inside the area TOS uses
// for the search pattern, where no file name can produce these bytes). It is
// what tells an Fsnext apart from a TOS search: TOS keeps "directory position |
// drive" at offset 12, which a TOS search on a drive with our number, at
// position 0, would leave looking exactly like the drive number GEMDRIVE used
// to write there.
#define GEMDRIVE_DTA_MAGIC 0xAA555344u
#define GEMDRIVE_DTA_MAGIC_OFFSET 2

// Write-side state. All status words are signed GEMDOS error codes
// (0 = ok, negative = error). FCREATE_HANDLE returns a new file handle
Expand Down Expand Up @@ -134,6 +143,13 @@ void gemdrive_setWriteStall(uint16_t chunks, uint16_t deciseconds);
#define GEMDRIVE_FDATETIME_DATE_OFFSET 0x1620 // 4 bytes (DOS date)
#define GEMDRIVE_FDATETIME_TIME_OFFSET 0x1624 // 4 bytes (DOS time)
#define GEMDRIVE_FDATETIME_STATUS_OFFSET 0x1628 // 4 bytes
#define GEMDRIVE_FFORCE_STATUS_OFFSET 0x1634 // 4 bytes, after EXEC_PD
// Standard handles (0-5) forced onto GEMDRIVE files with Fforce: per standard
// handle, the GEMDRIVE handle (0 = not forced) and the basepage of the process
// that forced it. The ST reads it to route Fread/Fwrite/Fseek on a standard
// handle without asking the RP.
#define GEMDRIVE_FORCED_OFFSET 0x1638 // 6 x 8 bytes
#define GEMDRIVE_FORCED_COUNT 6

// Shared variable for the PE_GO restoration trampoline (TOS 1.00/1.02
// hack — see source's gemdrive.s for the rationale).
Expand Down
515 changes: 258 additions & 257 deletions rp/src/include/target_firmware.h

Large diffs are not rendered by default.

Loading
Loading