Converting software from Q-emuLator to QLAY

Discussion and advice about emulating the QL on other machines.
User avatar
Dave
SandySuperQDave
Posts: 2765
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: Converting software from Q-emuLator to QLAY

Post by Dave »

Oh alright! I'll stop!

I never did figure out how to get the QL Zip onto the QL because I needed a zip program on the QL to unzip Zip. I tried unzipping Zip on the PC VM on my Mac, but then it didn't work on the QL.

Not a huge problem, except that I could never get a compiler onto my QL.

Difficulty: I have Q-Emulator


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

Re: Converting software from Q-emuLator to QLAY

Post by tofro »

Dave,

read here:
http://www.dilwyn.me.uk/arch/index.html

Especially the paragraphs on "QemuLator Unzip " and/or "Unzip 5.41 as a BASIC program"

It's all there ;)

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
dilwyn
Mr QL
Posts: 2753
Joined: Wed Dec 01, 2010 10:39 pm

Re: Converting software from Q-emuLator to QLAY

Post by dilwyn »

tofro wrote:Dave,

read here:
http://www.dilwyn.me.uk/arch/index.html

Especially the paragraphs on "QemuLator Unzip " and/or "Unzip 5.41 as a BASIC program"

It's all there ;)

Tobias
Thanks Tobias, should have mentioned that myself.

And, just to please Tobias, Mark and Dave especially, an 11,624 line BASIC solution to getting the zip program into an emulator is now on the same page... :ugeek:

Now I should really get slagged off for overkill on the online chat tonight - will probably be on about 9pm UK time for the slaughter...see you all there :cry:

Actually, the logic behind this is extremely simple, despite the size of the program, so simple I wish I'd thought of it years ago (well, actually I did, back in 2011 IIRC).

One of the QL file formats which survive Windows and almost any other operating system is (you've guessed it) a QL BASIC program. So I wrote a QL BASIC program called Job2Bas_bas which simply converts a QL executable program (in simple words, a QL executable is a QL program or "job" you can start with an EXEC or EXEC_W command) into a QL BASIC program! You just transfer this to the emulator, run it, and it recreates the original program, bypassing the entire issue of lost headers.

So, to transfer a program file, run it through Job2bas, transfer it to the emulator, run the program on the emulator, program rebuilt, job done.

And in case you're wondering where the 11,624 lines of BASIC come in...

Job2Bas works by converting the original program into DATA statements in a BASIC program. When you run zip22_bas (or whatever) a long series of POKEs rebuild the original program for you.

So never let it be said that you can't solve a little problem without nearly 12,000 lines of BASIC :mrgreen:


User avatar
Dave
SandySuperQDave
Posts: 2765
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: Converting software from Q-emuLator to QLAY

Post by Dave »

Did you disable smilies, Dilwyn?

Also, yes, the chatroom has definitely shown the character of some of the people in our community in a way that even the forum has failed to do - great personalities and humour there.


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

Re: Converting software from Q-emuLator to QLAY

Post by dilwyn »

1024MAK wrote:Hmm, well Mr_Navigator opened the door a little, I pushed it open to see what the noise was, then dilwyn comes in and blows the house down!
I specialise in that! Maybe not knocking the house down, but certainly knocking the PC down when my QPC programming goes wrong :oops:
1024MAK wrote:Having worked out his frustration, next he's laying bricks for a new building!
Err, no, I was playing with my Lego set actually ;)
1024MAK wrote:
I wrote:So why the flip did the QL zip files not end up with a nice "qip" or "qlp" extension? Would have saved a lot of confusion...
By this I meant, if container systems that contained QL files complete with the important QL file information (the zip) had a different extension, but otherwise were exactly the same, yes, people would still ask, what do I need to open XYZ.qip, they may even still click on it (and some OS's like Linux, would still appear to open or extract it without problems, at least until they move said files to a QL...), but I think the learning curve would be shorter. As now it would be easier to see which files are okay to unpack on your Window$/Liniux/Mac OS and which files are intended only to be unpacked on a QL or emulator. Of course, getting everyone used to this and getting all stored files to comply with this would take time and effort...
I slightly misinterpreted this. Assuming QL Zip and Unzip will work with _zip files simply renamed to _qip files or whatever (e.g. program_zip becomes program_qip or program.qip) there's no harm in this at all. I must emphasize I haven't actually tried this to test if it works or not. Qemulator 'qlpak' files are like renamed zip files IIRC.
1024MAK wrote:
I also wrote:Did anyone ever try to set a universal standard for the QL?
This was suppose to be a past tense question... As in was it attempted before now.
As is normal in the computing world, each new system (be it hardware or software) often ends up with features that favour custom file formats. With a small community, it would indeed be very hard work to try to move away from the current situation.
However, in the longer term, if the QL, QL type machines and QL emulators are going to be usable in the long term, we need to find a better way. Floppy disks are not going to last forever and Microdrives are dying. It looks like SD cards are currently the best forward looking option.
However people coming back to the QL, or people discovering the QL for the first time (especially if they have experienced how easy it is to use CF or SD cards with other retro computers) are going to be put off with the current situation of many incompatible file systems.
Yes, in many cases, it is not practical to rewrite old emulator code, let alone modify old hardware/firmware.
The QL community is a shrinking community, do we really want to keep it that way, or do we want to ensure it survives? We could do with returning members and new blood staying ;)
I do not know the full answer. But I would like to see a common standard file format if only for archiving / digital preservation, which can then be converted to the most used QL, QL type machine and QL emulator formats.

Mark
[/quote]
I largely agree. But also (and again in a past tense) we haven't had a good record with this in the past.

My list of QL hard disk formats frightened even me, plus I thought of a few additional less common ones such as Thor hard disks afterwards. So far, the two most common hard disk formats have been Qubide and QXL.WIN. If Qubide and Qx0 were able to handle QXL.WIN they would join a list of the most common systems able to handle this and it would become the de facto standard, probably what Tony Tebby intended. AFAIK, no current QL file system can be read directly anywhere outside the QL scene, so for long term archiving we have to rely on zip (or qip)

OK, I may have made a bit of a fool of myself with the Encopy/Decopy program, but at least it stirred up some controversy and discussion. And despite my reactions, I largely agree with what everyone has said.

The articles on using Zip, returning to QL, serial transfer and so on are all on my website, so what I'll do as I can't find my past scribblings on here is post a message later tonight with links to these dreaded subjects and hopefully vanpeebles or robheaton can post them as a sticky message or something like that to make them easy to find.


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

Re: Converting software from Q-emuLator to QLAY

Post by dilwyn »

Dave wrote:Did you disable smilies, Dilwyn?
Smilies? What are they? :?
Dave wrote:Also, yes, the chatroom has definitely shown the character of some of the people in our community in a way that even the forum has failed to do - great personalities and humour there.
He he, yes indeed. For anyone who wasn't there last night, we were taking turns to pick on one another in a friendly sort of way, interspersed with all of us appearing in quotes from the adventure game that vanpeebles is writing.

9pm tonight (UK time), everyone - click on the Online Chat link near the top of the home page of this Forum!


User avatar
M68008
Trump Card
Posts: 223
Joined: Sat Jan 29, 2011 1:55 am
Contact:

Re: Converting software from Q-emuLator to QLAY

Post by M68008 »

dilwyn wrote: (1) the qemulator modified executables need to be de-modified - "unmodify" these by copying them to a non-nfa drive in qemulator, such as ramdisk or floppy disk, zip them up using Jonathan Hudson QDOS zip, save that back to the nfa drive (which should now store the executable headers but without the QemuLator changes which prevent them working on anything else)
ZIP is probably the way to go, but no need to copy to ramdisk or floppy first, you can directly zip from the location where the files are to a Windows directory. The resulting .zip file can be transferred to other systems: Q-emuLator shouldn't add its special header to it as it's just a data file (not an executable).


Post Reply