X16 Dos?

Tutorials and help articles.

(Posts require approval. See pinned post.)
Forum rules
Post guides, tutorials, and other instructional content here.

This topic area requires approval, so please be patient while we review content to make sure it fits the expectations for this topic area.

Tech support questions should be asked in Hardware or Software support.
Post Reply
User avatar
TampaPete
Posts: 5
Joined: Sun Nov 24, 2024 11:51 pm

X16 Dos?

Post by TampaPete »

Hi,

Can anyone recommend a reference for using the X16 variant of DOS? I never had a Commodore machine, so I'm not familiar with the commands, and the Apple stuff doesn't really port over :)

Thanks!
Pete
TomXP411
Posts: 1785
Joined: Tue May 19, 2020 8:49 pm

Re: X16 Dos?

Post by TomXP411 »

There is actually a quick ref in the reference guide, which you can download with the emulator or read online at https://github.com/X16Community/x16-docs

Short version: you can issue a CMDR-DOS command by using the DOS WEDGE (Typing > or @ and following that with a command), or the DOS BASIC command.

Examples:

Using the > DOS wedge:
>CD:/GAMES
will change to the /GAMES directory.

>S0:FOO.BAS
will delete the file named "FOO.BAS"

Using the @ DOS wedge behaves exactly the same (It's just easier to type on some keyboards):
@$
Display the files in the current directory.

@MD:TOOLS
created a TOOLS directory

and the DOS wedge also lets you quickly load and run files:
/HELLO.BAS
loads "HELLO.BAS" into memory.

↑HELLO.BAS
Load and run HELLO.BAS.

Finally, some DOS command examples:
DOS "$" DOS "CD:/" DOS "C:NEW_FILE=OLD_FILE" (copy a file)
User avatar
ahenry3068
Posts: 1144
Joined: Tue Apr 04, 2023 9:57 pm

Re: X16 Dos?

Post by ahenry3068 »

TampaPete wrote: Mon Nov 25, 2024 1:14 pm Hi,

Can anyone recommend a reference for using the X16 variant of DOS? I never had a Commodore machine, so I'm not familiar with the commands, and the Apple stuff doesn't really port over :)

Thanks!
Pete
If your interested in doing them programmatically you can also send them as a File Name to the Command Channel and use Open

PRINT ">";
LINPUT C$
OPEN 15,8,15, C$
INPUT# 15, F, F$, T, S
CLOSE 15
PRINT F;",";F$;",";T;",";S

The above code would accept a DOS cmd on the prompt and then execute it.
and print the code after just like DOS at the BASIC prompt.
User avatar
TampaPete
Posts: 5
Joined: Sun Nov 24, 2024 11:51 pm

Re: X16 Dos?

Post by TampaPete »

Thanks for the info. I've been digging through the docs and found the section on CMDR-DOS shortly after posting my question. I think the fact that the commands are issued as basic statements is throwing me off - need to get my head around that.
TomXP411
Posts: 1785
Joined: Tue May 19, 2020 8:49 pm

Re: X16 Dos?

Post by TomXP411 »

TampaPete wrote: Mon Nov 25, 2024 6:29 pm Thanks for the info. I've been digging through the docs and found the section on CMDR-DOS shortly after posting my question. I think the fact that the commands are issued as basic statements is throwing me off - need to get my head around that.
Yeah, unlike Apple ProDOS, CP/M, or MS-DOS, the "DOS" in a Commodore-ish computer is built into the disk drive, rather than being part of the computer's operating system. Commodore 8-bit computers also don't have a Command Line Interface (ie: DOS Prompt, or Command Processor).

If you just use > or @, however, it's easy enough to treat CBM-DOS like a first-class operating system. Just type @ or > first, then the rest of the disk command. (Hence things like >$ to get a directory or >CD:/GAMES to change directories.)

Until you get used to it, keeping a copy of the DOS Wedge and the basic CMDR-DOS commands handy will help remind you what does what. For most of us, however, we only need to remember 3 commands:

@CD:/PATH/TO/GAME /GAME RUN
kelli217
Posts: 532
Joined: Sun Jul 05, 2020 11:27 pm

Re: X16 Dos?

Post by kelli217 »

/GAME
loads the file "GAME", but
↑GAME
loads it and runs it, automatically.

Also... the ↑ key is usually accessed by the same key combination you would use to get a ^ character.
mortarm
Posts: 302
Joined: Tue May 16, 2023 6:21 pm

Re: X16 Dos?

Post by mortarm »

TomXP411 wrote: Mon Nov 25, 2024 5:15 pm >S0:FOO.BAS
will delete the file named "FOO.BAS"
How did "S0" come to mean "Delete"? Not very mnemonic.
DragWx
Posts: 345
Joined: Tue Mar 07, 2023 9:07 pm

Re: X16 Dos?

Post by DragWx »

"S" means "scratch" (as in, scratch it out by squiggling a line through it), and the "0" means "Drive #0", which is a leftover from the two-disk-drives-in-one-device PET days. Look up the 1541 or the 1571 user guide if you want to see it in context.

I don't know anyone who says "scratch it out", I knew it as "cross it out" or "scribble it out" or "erase it". :P
TomXP411
Posts: 1785
Joined: Tue May 19, 2020 8:49 pm

Re: X16 Dos?

Post by TomXP411 »

I don't think you actually need the 0 in S0:. I'm just used to typing it that way, because some commands didn't work right on Commodore
drives if you didn't include the drive number. So I just made a habit of always adding the 0.

So >S:FOO.DAT should also delete the file named "FOO.DAT".
Post Reply