WIN extensions

A place to discuss general QL issues.
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: WIN extensions

Post by dilwyn »

Derek_Stewart wrote:Hi,

I have tried your TK2 on QEM & Minerva v1,98, which works great except for the MAKE_DIR which give a NOT IMPLEMENTED YET error message when trying to create a directory.

Any ideas on how to get this working...
There canbe an issue with drivers built into QemuLator when it comes to MAKE_DIR.

For example, you can't create a directory in a QXL.WIN, but you can read from and write to existing directories.

QDOS ROM images don't implement a MAKE_DIR command anyhow.

Even on SMSQ/E, MAKE_DIR won't create a directory on a QXL.WIN on QemuLator.


User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: WIN extensions

Post by dilwyn »

Silvester wrote:
Derek_Stewart wrote:Hi,
I have tried your TK2 on QEM & Minerva v1,98, which works great except for the MAKE_DIR which give a NOT IMPLEMENTED YET error message when trying to create a directory.
Any ideas on how to get this working...
I don't have a registered version, I could only try it in the demo 'Limited' (very slow) option.
IIRC I think MDV responds err_ni (not implemented) to MAKE_DIR whereas Trump card level 1 drivers (FLP,RAM) respond err_bp (bad parameter). Otherwise it may be QEMU driver.
I'll see if I can get a level 2 ramdisk driver working on QEMU and try MAKE_DIR on it.
Level 2 filing systems are only available on the registered QemuLator.

The inbuilt ramdisc is level 1, but can be disabled via the QL Configuration menu, devices tab (untick the RAM disk box). Then you can install a third party ramdisk driver via your boot program or as an extension EPROM image.

Unfortunately, I don't know of any PD ramdisk drivers with level 2 filing system - I'd be delighted to be proved wrong and add one to my site if you find (or make!) one.


Martin_Head
Aurora
Posts: 847
Joined: Tue Dec 17, 2013 1:17 pm

Re: WIN extensions

Post by Martin_Head »

dilwyn wrote: Unfortunately, I don't know of any PD ramdisk drivers with level 2 filing system - I'd be delighted to be proved wrong and add one to my site if you find (or make!) one.
The FDI2 floppy disk image program on Dilwyn's site supports level 2 drivers. I only had a quick play with it on Qemulator (shareware version). But I seem to remember that it was the same as Dilwyn said above,

"For example, you can't create a directory in a QXL.WIN, but you can read from and write to existing directories."

It should not be too difficult to to write a SuperBASIC, MAKE_DIR extension that takes the directory string and then calls the FS_MKDIR (or what ever its called) Trap #3

Martin Head


Silvester
Gold Card
Posts: 436
Joined: Thu Dec 12, 2013 10:14 am
Location: UK

Re: WIN extensions

Post by Silvester »

With the demo version of QEMU in 'Limited' mode I was able to create/delete directories if MDV slot was configured for a system directory. Everything worked as normal (file save/deletion OK and dir couldn't be deleted until empty, etc). I don't have FLP A/B so couldn't try that. (System was Unbuntu using Wine emulator.)

MAKE_DIR just calls driver through system trap as normal, I can only guess it is an issue with QEMU as mentioned above. Not unreasonable considering it is meant to closely mimic original QL for compatibility.


David
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: WIN extensions

Post by dilwyn »

Martin_Head wrote: It should not be too difficult to to write a SuperBASIC, MAKE_DIR extension that takes the directory string and then calls the FS_MKDIR (or what ever its called) Trap #3
Martin Head
Which obviously wouldn't work if the device driver doesn't support it, which I guess the QXL.WIN driver doesn't. Even with SMSQ/E (which has a MAKE_DIR) you can't.

It's not a question of does the 'slot' support it, depends on the driver for the device attached to the slot. You'd be able to MAKE_DIR a directory on the native drives but not necessarily with other types of devices attached to the mdv slots.

Dilwyn


User avatar
pjw
QL Wafer Drive
Posts: 1286
Joined: Fri Jul 11, 2014 8:44 am
Location: Norway
Contact:

Re: WIN extensions

Post by pjw »

Dilwyn writes:
Even on SMSQ/E, MAKE_DIR won't create a directory on a QXL.WIN on QemuLator.
It seems to work ok here, with a registered version of QemuLator and SMSQ/E

Per


Per
dont be happy. worry
- ?
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: WIN extensions

Post by dilwyn »

pjw wrote:Dilwyn writes:
Even on SMSQ/E, MAKE_DIR won't create a directory on a QXL.WIN on QemuLator.
It seems to work ok here, with a registered version of QemuLator and SMSQ/E

Per
QemuLator 3.1.4 registered, SMSQ/E Gold 3.06
(Win2_ is a QXL.WIN)
MAKE_DIR win2_test_
Not implemented.
*BUT* creates a FILE called WIN2_test (Type 0, minus the trailing underscore) in the QXL.WIN, not a directory. This has to be deleted with DELETE win2_test (not DELETE win2_test_) - any second attempt to create a directory before that spurious file is deleted will claim it already exists. Also, while DIR WIN2_TES will list the file created, DIR win2_test gives 'invalid parameter'

QemuLator 3.1.4 registered, SMSQ for Qemu 3.13
same results

This kind of unpredictability is the reason why I so rarely use QemuLator - too many things only work "sometimes".
makedir.jpg


User avatar
tofro
Font of All Knowledge
Posts: 2685
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: WIN extensions

Post by tofro »

That is not a Q-Emulator fault, IMHO.

If you load "ramprt" (The "old" QJump ramdisk driver) into SMSQ/E on QPC2, and try to create a directory in ram1_, the exact same thing happens ("not implemented", and a "normal" file is created).

This has to do with the implementation of a Level 2 device driver where QDOSSMSQ is different from many other OSs.

A directory is just a normal file (albeit with a specific file type, 255) that holds all the file headers of the files that should go into that directory. "making" a directory is simply creating that file, setting the file type to 255 and moving all the headers of the files that belong into it from the root directory into the new file (thus "removing" the files from the root directory). You could easily implement that operation outside a device driver, i.e. in a "normal" application, even on a level 1 device driver.

On the other hand, "DIR" and the file open/close commands (which are actually in the driver) need to "understand" the concept of directories (in the end all of those functions need to be able to parse a path name into a directory + file) - But that is partly spread into S*BASIC, partially in the OS itself, and some parts in the device driver. More or less related to the development history of QDOSSMSQ.

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
pjw
QL Wafer Drive
Posts: 1286
Joined: Fri Jul 11, 2014 8:44 am
Location: Norway
Contact:

Re: WIN extensions

Post by pjw »

Sorry Dilwyn, I was mistaken. MAKE_DIR on a QXL.WIN is not implemented, as you found. I dont often use QemuLator, so Id forgotten that Id swapped the *.WIN files for native Windoze directories. Probably for that very reason. I just double checked to ensure you were not merely experiencing the terrifying Dilwyn-effect (a by now a widely recognised, albeit poorly understood phenomenon..)

Per


Per
dont be happy. worry
- ?
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: WIN extensions

Post by dilwyn »

pjw wrote:...I just double checked to ensure you were not merely experiencing the terrifying Dilwyn-effect (a by now a widely recognised, albeit poorly understood phenomenon..)
Per
He he, even less well understood than the vagaries of all the various QL filing systems :D


Post Reply