VOGONS


First post, by James_Richards

User metadata
Rank Newbie
Rank
Newbie

As asked, can the Z drive contents be replaced? Or bypassed somehow?
The only thing I can find on VOGONS is this : Writable Z Drive
I am no coder and wouldn't know how to go about it on my own. I was using DOSBox-X, but it proved to have some odd glitches that went away when I moved to DOSBox and DOSBoxECE. In fact, I have pretty much stayed on DOSBoxECE and am enjoying some of its enhancements until a newer version of main DOSBox comes around.

What my aim is; I am trying to replace certain commands with files from my DOS install disks. As an example:
In DOSBOX-X, I was able to run PROMPT to change the style of my prompt and even and some color to it.
In DOSBox and DOSBoxECE, this is not doable. I get "Illegal command: PROMPT" I tried putting a DOS folder in my mounted folder and set a PATH for it, but that doesn't work. I even put a copy of COMMAND.COM in the root of the mounted C drive and I still cannot get to using PROMPT. I cna only assume that the COMMAND.COM in Z: is overriding everything else in PATH.

Any advice on this? I have a game launcher I made way-back-then that uses PROMPT as well, and it mostly breaks now when using DOSBox

I have explored using things like Virtualbox and PCem, but last time I tried games were either too slow or not working with no acceleration on 2D or 3D, and in the case of PCem, I think the only way I could get Wing Commander to be playable was trying to install a thing like moslow. I like the convenience that DOSBox provides.

Also, my daily use computer is now running Linux. Has been for over half a year now and I am still learning. If I have to code something, I'll try but my confidence in that area is currently very low, especially as my platform has changed. Any advice or pointing into the right direction would be appreciated!

...this could be fun...

Reply 1 of 7, by zirkoni

User metadata
Rank Member
Rank
Member
James_Richards wrote on 2022-04-10, 05:08:

I tried putting a DOS folder in my mounted folder and set a PATH for it, but that doesn't work. I even put a copy of COMMAND.COM in the root of the mounted C drive and I still cannot get to using PROMPT. I cna only assume that the COMMAND.COM in Z: is overriding everything else in PATH.

Did you set the new path first and then append the old path: SET PATH=C:\PATH;%PATH%
Then it should find the binary from C:\PATH first.
The other way it will find the binary from Z:\ first: SET PATH=%PATH%;C:\PATH

James_Richards wrote on 2022-04-10, 05:08:

in the case of PCem, I think the only way I could get Wing Commander to be playable was trying to install a thing like moslow.

You can select different emulated systems in PCem. If you setup it for a 286 then it should limit the CPU to 286 speeds. You probably selected some faster CPU.

https://www.youtube.com/user/zirkoni88

Reply 2 of 7, by James_Richards

User metadata
Rank Newbie
Rank
Newbie

I probably did hit a higher speed CPU. I might play with PCem some more.

As for the path, I entered in the [autoexec] section of the conf:
SET PATH=C:\WINDOWS;C:\DOS;C:\QB45;Z:\;C:\

You are saying I should just use
SET PATH=C:\;C:\DOS;%PATH%
or
SET PATH=C:\;C:\DOS;Z:\ ?
(yeah, removing some things as I was tinkering with an old QB game I made back in the day)

I don't remember much of my DOS days, but I am guessing from left to right is the priority? And when putting this in my autoexec, I should just have %PATH% in place of what is default in DOSBox?

Even if I wrote under [autoexec]
SET PATH=C:\;C:\DOS;%PATH%, it still will not seem to reference the COMMAND.COM I have at C:\ or C:\DOS

Here is what I have under [autoexec]

MOUNT C ~/DOSBOX/C/ -freesize 870400
SET PATH=C:\;C:\DOS;%PATH%
PROMPT [1;36m$Q$Q [1;37m$p[1;32m$g [0m

This works under DOSBox-X, but not DOSBox or ECE version (latest from AUR)
I still get "Illegal command: PROMPT" before I see the normal "C:\>" ($p$g) prompt

...this could be fun...

Reply 3 of 7, by jmarsh

User metadata
Rank Oldbie
Rank
Oldbie

You won't be able to change the prompt like that for DOSBox. It's running its own built-in version of COMMAND.COM (the DOS shell/command interpreter) and you're trying to use unsupported commands from MSDOS.
If you want to run real MSDOS in DOSBox, set up a HDD image and install MSDOS on it.

Reply 4 of 7, by James_Richards

User metadata
Rank Newbie
Rank
Newbie

Maybe I misunderstand your statement "...and you're trying to use unsupported commands from MSDOS."
PROMPT is an internal command in COMMAND.COM and CMD.EXE in all versions of MS-DOS, Windows 9x all thru Windows 11.
My implementation is adding ANSI codes to manipulate color and add more data to the string (VOGONS doesn't show the escape characters before the open brackets)

My thinking was by replacing the COMMAND.COM in Z: I can accomplish what I can in say a virtual machine running MS-DOS. I am fully aware that DOSBox is only a DOS emulator with a limited feature set than that of real machine running MS-DOS. I am guessing it isn't as simple as replacing COMMAND.COM. My understanding of the differences between main DOSBox and something like DOSBox-X is limited, and I don't know how a command interpreter like COMMAND.COM is implemented to begin with.

I am trying to stick with DOSBox for its ease of use, convenience and ability to change the contents of the "harddrive" on the fly.

Besides booting from a bootable image with MS-DOS installed, and loosing things like MOUNT and IMGMOUNT from DOSBox, any tips or tricks to attempt getting to where I would like to be? Or just give up, switch back to DOSBox-X and seek support on their forums?

...this could be fun...

Reply 5 of 7, by jmarsh

User metadata
Rank Oldbie
Rank
Oldbie

They're internal commands because they modify the internal state of the command interpreter program. You can't expect a completely different COMMAND.COM to be able to change anything about the currently running shell.

Reply 6 of 7, by ripsaw8080

User metadata
Rank DOSBox Author
Rank
DOSBox Author

You have to *execute* an alternate shell (command interpreter) in order to replace DOSBox's internal shell, and I don't see you doing that in your example.

You can use the COMMAND.COM from MS-DOS 5.0 or 6.22, but to use the one from 6.22 you must first use the command "VER SET 6 22" to change the reported version of DOS or the shell will refuse to load. Note that the SVN version of DOSBox has some improvements so that the DIR command of the MS-DOS shell is displayed more correctly.

The 4DOS shell is an alternate choice of shell that provides even more features than the original DOS shells, such as colorization of DIR output.

The above options allow the PROMPT command to work as expected but note that you will also need to set the COMSPEC environment variable in order for some software to be able to execute the preferred shell. Also, placing the shell in the root directory of the emulated C: drive helps in a few cases where software does not use COMSPEC as it should. In the following examples using your autoexec commands the shell program is located in the root of the emulated C: drive:

MOUNT C ~/DOSBOX/C/ -freesize 870400
SET PATH=C:\;C:\DOS;%PATH%
SET COMSPEC=C:\COMMAND.COM
C:
COMMAND.COM
PROMPT [1;36m$Q$Q [1;37m$p[1;32m$g [0m
MOUNT C ~/DOSBOX/C/ -freesize 870400
SET PATH=C:\;C:\DOS;%PATH%
SET COMSPEC=C:\4DOS.COM
C:
4DOS.COM
PROMPT [1;36m$Q$Q [1;37m$p[1;32m$g [0m

Reply 7 of 7, by James_Richards

User metadata
Rank Newbie
Rank
Newbie
jmarsh wrote on 2022-04-11, 06:08:

They're internal commands because they modify the internal state of the command interpreter program. You can't expect a completely different COMMAND.COM to be able to change anything about the currently running shell.

That is helpful. To a point, and I guess the next statement makes it even more clear

ripsaw8080 wrote on 2022-04-11, 12:40:
You have to *execute* an alternate shell (command interpreter) in order to replace DOSBox's internal shell, and I don't see you […]
Show full quote

You have to *execute* an alternate shell (command interpreter) in order to replace DOSBox's internal shell, and I don't see you doing that in your example.

You can use the COMMAND.COM from MS-DOS 5.0 or 6.22, but to use the one from 6.22 you must first use the command "VER SET 6 22" to change the reported version of DOS or the shell will refuse to load. Note that the SVN version of DOSBox has some improvements so that the DIR command of the MS-DOS shell is displayed more correctly.

The 4DOS shell is an alternate choice of shell that provides even more features than the original DOS shells, such as colorization of DIR output.

The above options allow the PROMPT command to work as expected but note that you will also need to set the COMSPEC environment variable in order for some software to be able to execute the preferred shell. Also, placing the shell in the root directory of the emulated C: drive helps in a few cases where software does not use COMSPEC as it should. In the following examples using your autoexec commands the shell program is located in the root of the emulated C: drive:

MOUNT C ~/DOSBOX/C/ -freesize 870400
SET PATH=C:\;C:\DOS;%PATH%
SET COMSPEC=C:\COMMAND.COM
C:
COMMAND.COM
PROMPT [1;36m$Q$Q [1;37m$p[1;32m$g [0m
MOUNT C ~/DOSBOX/C/ -freesize 870400
SET PATH=C:\;C:\DOS;%PATH%
SET COMSPEC=C:\4DOS.COM
C:
4DOS.COM
PROMPT [1;36m$Q$Q [1;37m$p[1;32m$g [0m

I Tried the example you provided, and I am getting closer, but I think I'll need to run a new batch command for PATH and such. In order of commands in the [autoexec] section, I get to it calling COMMAND.COM, reports version 6.22 still, this is good, but it stops there. Processing nothing after calling COMMAND.COM. In limited testing I can play a game or two. It allowed for mounting disc images and everything seems fine so far. So, a short batch file with the PROMPT setup and calling a personalized game launcher works so far.

From here on, it is testing what else needs work. Definitely closer to what I am looking for. Thank you for the pointers!

...this could be fun...