| |
Krill
Registered: Apr 2002 Posts: 2982 |
Release id #209982 : Transwarp v0.82
General Q&A thread, also report problems and error logs here. |
|
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
Problem: how do we create a disk using that loader? :) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Answer: current cc1541, v3.3 or later. =) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
\o/ |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
Okay anyone have a linker/packer that will link a small basic program and a ml progra running at $4000 that won't knock out transwarp?
i need to get it down to 54 transwarp blocks for the two o f them, and after it unpacks and runs transwarp needs to remain active. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
How big is the program when not packed? Can you maybe just copy the ML portion to $4000 after RUN? |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
the ml part is 64 blocks by itself.
the basic program SYSes it, pokes some sid registers afterwards so it doesn't whine at you while unpacking the main program after, and loads the next program. The basic part is 1 block
i can exomize the two of them together using minimal compression, ad it ends up small enough, but it knocks out transwarp.
And it's stupid to eat an entire track with a basic program to do it in three files.
because i have 54 transwarp blocks to hold it in, I can't just memory save both at once. i need to both link and rle pack it. exomizer's decrunch table clobbers the vectors, which are the RESTORed after. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
just make custom depacker? |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
I didn't want to reinvent the wheel.
could you point me at writing linkers and depackers for dummies? :) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Try another small RLE packer, like Plush Packer =) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
i didnt mean to write your own packer - the source for the exomizer depacker is available, you can easily wrap it into your own mainloop and make it use other memory areas |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
hmm. plush packer specifies a jmp address. which won't start a basic program, will it? |
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
try $a7ae |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodhmm. plush packer specifies a jmp address. which won't start a basic program, will it? JMP to a routine like this. You probably won't need the part before the JSRs, though, these pointers should be in a good-enough state after loading. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
gah! i understood exomiser just fine. plush packer doesn't provide a sys line with the packed program, so i can't even get that far. i think a better approach would be hiding an assembler fragment just before or just after the logo something like
JSR $4000
LDA #00
STA $D400
STA $D401
STA $D407
STA $D408
STA $D40e
STA $D40f
JSR LOAD"COPYRIGHT 1985",8 ; need example here
JMP sysline of COPYRIGHT 1985 ; i can do this part myself
then i can just g-pack that and specify the new routine as the start address. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodplush packer doesn't provide a sys line with the packed program Save to $080d, then reset, then "2021 SYS2061", then load the packed program and save from $0801 to end of packed program. |
| |
Comos
Registered: May 2004 Posts: 73 |
Quoting Zaphodexomizer's decrunch table clobbers the vectors, which are the RESTORed after.
Exo's decrunch table starts by default @ $033C, so the vector table ($0314-$0333} is not touched during depack.You can also relocate the decrunch tabke via "-Di_table_addr=<address>" to suit your needs. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
it still touched the vectors, though. do you know how to tell it not to?
i know it's not the logo routine because if i tw load something, then monitor load both parts in, it works. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting ComosExo's decrunch table starts by default @ $033C, so the vector table ($0314-$0333} is not touched during depack. Transwarp has a bunch of routines north of $02a6 and up to $0400, minus the software vectors at $0300-$0334.
These routines are required to switch memory configuration etc., as most of the resident code lives somewhere at $d000 to end of RAM below the hardware vectors. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
okay, anyone know how the @$@ to write a filename into memory in the vice monitor? :) |
| |
Comos
Registered: May 2004 Posts: 73 |
Quoting Zaphodit still touched the vectors, though. do you know how to tell it not to?
i know it's not the logo routine because if i tw load something, then monitor load both parts in, it works.
Please then elaborate,what exactly happens.You mean just one vector is tampered or more of them? Normally if this would be happening, then none of the releases would work example on IDE64 or other carts which depend on their custom vectors regarding I/O. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
well te decrunch breaks tranwarp.
krill explains that this is because the decrunch table clobbers some of it's stuff.
anyway i thought i was beign clever with my lil asm, but of course the load overwrites my asm. which means i need to manually push an address ($080d) onto the stack and jmp into the load instead of JSR
so how do i do that? is it
lda #0d
pha
lda #08
pha
jmp $ffd5 |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
I recommend to do something like i did in the intros of the 3 dual-load games.
This is from the Giana Sisters intro:.C:0c20 A9 01 LDA #$01
.C:0c22 05 B9 ORA $B9
.C:0c24 85 B9 STA $B9
.C:0c26 A9 01 LDA #$01
.C:0c28 A6 BA LDX $BA
.C:0c2a D0 02 BNE $0C2E
.C:0c2c A2 08 LDX #$08
.C:0c2e A4 B9 LDY $B9
.C:0c30 20 BA FF JSR $FFBA
.C:0c33 A9 0D LDA #$0D
.C:0c35 A2 40 LDX #$40
.C:0c37 A0 01 LDY #$01
.C:0c39 20 BD FF JSR $FFBD
.C:0c3c A2 0C LDX #$0C
.C:0c3e BD 52 0C LDA $0C52,X; name
.C:0c41 9D 40 01 STA $0140,X
.C:0c44 CA DEX
.C:0c45 10 F7 BPL $0C3E
.C:0c47 A9 08 LDA #$08
.C:0c49 48 PHA
.C:0c4a A9 0C LDA #$0C; $080d - 1
.C:0c4c 48 PHA
.C:0c4d A9 00 LDA #$00
.C:0c4f 4C D5 FF JMP $FFD5 |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
i had that backwards.
i now have the file loading the next one and starting properly. this will load ANY packed main program, provided i has sys 2061 :)
and now to try and transwarp master. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
and g-packer broke the logo SOMEHOW.
it was fien before gpacker tried it.. hmmm...
yup. g-packer completely nurders it somehow. i can load it fine before packing it, and if i run the ml routine in the monitor, it works.
g-packer doesn't kill the transwarp either. but the graphics are corrupt, for no good reason.
i'll see if plush packer works... |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
plushpacker didn't break the logo, but broke the transwarp. i used the fast packer.
g-packer breaks the logo, but doesn't break the transwarp. WAAAAGGGGHHHH! |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
A word about the new challenge:
As the last one was so swiftly and throughly beaten, i decided to make an effort this time.
The key is now 232 bits (29 bytes) big, provided as a passphrase string in the 4th load parameter. LOAD"CHALLENGE",8,1,"SECRET KEY..." The passphrase itself isn't used as the key. There is some kind of 8-bit ghetto key hashing performed first, hoping that known parts of the key will not make it easier to find the other parts of the key and ultimately the passphrase.
Note that both the encryption routine (C) and the decryption routine (6502 assembly) are open-source.
Happy hacking! =) |
| |
Comos
Registered: May 2004 Posts: 73 |
Quoting Zaphodwell te decrunch breaks tranwarp.
krill explains that this is because the decrunch table clobbers some of it's stuff.
OK,understood,then try to relocate the decrunch table to $0500.You'll just see some garbage during depack,you can switch off the screen during that. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
ok i give up.
http://eunich.cochems.com/~zaphod/helpme.d64
two files on it
one is the logo, with my little ml routine i mentioned at the end of it.
the other is a 202 block monitor save of $08f0 to $D0A0, which is where the main vorpal file is.
my routine is as $7f3f
the logo must be called "koronis rift" and when transwarped must fit into tracks 19-21 (-r 19)
the main must be called "copyright 1985" and fit from tracks 16 to 7 (the docs do not say that -r counts backwards if it's under 18 for transwarp files) (-r 16)
no other space on the disk can fit transwarp files.
there should be no audio glitches, and the screen should bank after showing the logo (my routine does this)
transwarp itself can be fit anywhere else on the disk that's convenient (but not clobber anything else. i have a "blank" .d64 that has the blocks that should be allocated allocated, and the ones that should be free free.
JUST before 08f0 (08ed), there is a JSR $3187. this may or may not be used. it's easy enough to put back there. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11391 |
Quote:$08f0 to $D0A0
doesnt that destroy the resident part of the loader? |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
The loader can't load to $d000+ anyways. I guess the program would be minimally packed* to end below $d000. It uses its own loader anyways.
* Meaning to just copy those $a0 bytes from below $08f0 to $d000. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
that's why it's getting packed.
I was able to do that. the problem is when i use g-packer i ended up one block too big to fit it in track 16-6
if i use g packer to pack the logo intro, it breaks the graphics, for no good reason, but transwarp remains intact.
if i use plush packer, the logo intro works, but the transwarp is broken. it just runs off to track 22 where i had transwarp on disk, and replays the logo over and over again. (!)
if i use non transwarp versions of the files, things load properly.
I now have a gpacked main that loads properly and fits on the disk. :) but i still don't have a packed logo intro that doesn't knock out transwarp.
i managed to relocate the decrunch table with exomizer to $3400. But even with -C and -M 1 it still takes too damn long to decrunch. i wish i knew why g-packer breaks the graphics. it gets the data at the end with the routine just fine, but completely corrupt the logo. The disk finally works, though.
if i had a 21 block version of transwarp i could slap it into track 4, and it would probably load quicker than the current way it's spread across three tracks. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodthat's why it's getting packed. Do you need the space for the main file? Because as i said, no reason to pack it. Add SYS line and a small routine to copy the tail chunk from $0850-$0af0 back to to $d000 before running the main code.
Quoting ZaphodI was able to do that. the problem is when i use g-packer i ended up one block too big to fit it in track 16-6 What's the block allocation layout you need to work around? That is, after removing booter code, intro and main program from the original disk, leaving only the custom-format game data blocks, which gaps are left?
Quoting Zaphodif i use g packer to pack the logo intro, it breaks the graphics, for no good reason, but transwarp remains intact. A quick glance at the intro code reveals this:.C:4a64 AD 00 DD LDA $DD00
.C:4a67 25 FC AND $FC <- likely a bug, should probably be AND #$FC instead
.C:4a69 09 02 ORA #$02
.C:4a6b 8D 00 DD STA $DD00 Quoting Zaphodif i use plush packer, the logo intro works, but the transwarp is broken. it just runs off to track 22 where i had transwarp on disk, and replays the logo over and over again. (!) This is unexpected. If Transwarp is not installed while loading a Transwarp file from a program, the correct file should be loaded, but take a little longer due to having to load the booter stub and installing Transwarp again. Can you post the file?
Quoting Zaphodif i had a 21 block version of transwarp i could slap it into track 4, and it would probably load quicker than the current way it's spread across three tracks. For best speed, it's recommended to have the booter stub live on tracks 18 and 19, with no previously allocated blocks to work around.
As for a smaller version, you can disable these options in the sourceCRYPTO = 1
SOUND = 1
ERSTAT = 1
COMPAT = 1
INSTAL = 1 in any combination to reduce size, minimum is 17 blocks. You probably want INSTAL to remain set, though. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
User Comment
Submitted by Zaphod [PM] on 5 October 2021
Jars revenge glitches for me. Can only move diagonal forward and that on pal. Crashes on ntsc for me. Seems unlikely that the original would do that. It's a PAL only game. Do you have the same movement restriction when loading Transwarp itself, then loading the game, then reset, then SYS 2061?
Original is on Peiselgames . |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
As I said, the only two track blocks available are six to sixteen and nineteen to twenty one. Where the original two vorpal files were. They bled into part of the following tracks, 17 and 22, and overlapped with irq load data on them.
Logo must be packed and transwarp encoded to 19-21 and main must be packed and transwarp encoded to 16-6.
The issue is rle packing logo and having it not break transwarp after. I have tried two packers so far and both failed when the logo intro was transwarp encoded. Plush packer clobbered transwarp in a manner that it doesn’t detect and reset the vectors after, and g packer breaks the logo itself, but the main loads after.
Exomizer works, but is too slow to decrunch, even when I maximize speed and minimize crunching.
G packer must touch $FC, which breaks the intro. So I need to debug what actually gets written there. Does fixing that “bug” have the intro still work? |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
I intend to build the rest of the lucasfilm collection
Ballblazer loads two files and one goes under IO. This is fixed by linking and packing them. An unbranded one file that doesn’t show intro and repacks fast will fix it. Transwarp can go to the directory track and 19.
The eidolon will use the same intro but use a different main I have because it’s music sounds better. It uses a variant joe loader after that and has no hidden data. I should be able to master with no issues.
Rescue on fractalus writes high scores to 18.2 and uses drive code to do so. That is the only reserved sector. Assuming that this drive code is stored in main, there should be no issues mastering this because there is plenty of room.
What’s the smallest assembler I can use to rebuild transwarp?
I intend to transwarp remaster every vorpal v1 original I can find. :) I probably can’t do Barbie though |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodmain must be packed and transwarp encoded to 16-6. That's 11 tracks with 21 blocks each, 11 * 21 = 231. A 202 standard blocks file ($0801-$dd00) takes 230 Transwarp blocks. Should fit snugly in that track block, unpacked. =)
Quoting ZaphodPlush packer clobbered transwarp in a manner that it doesn’t detect and reset the vectors after The issue is that the resident code at the upper end of memory gets overwritten during depacking, though, the vectors and lowmem routines are left intact.
Maybe you should just wait a few more days for ChristopherJam to finish the next tinycrunch version featuring minimal crunching and copying to just come out below a given size threshold.
Quoting ZaphodG packer must touch $FC, which breaks the intro. So I need to debug what actually gets written there. Does fixing that “bug” have the intro still work? I don't use to post solutions to problems without first confirming them to work. And i just confirmed that it is indeed a classic use-of-unintialised-variable bug in the original intro, and likely caused by a typo. In the original version, nothing overwrites the 0 left by the ROM init routine there before $fc is read by the intro.
Btw.:
Quoting Zaphodtwo files on it What did you use to save the files in that image? Block allocation layout looks funky. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
I intend to build the rest of the lucasfilm collection
Ballblazer loads two files and one goes under IO. This is fixed by linking and packing them. An unbranded one file that doesn’t show intro and repacks fast will fix it. Transwarp can go to the directory track and 19.
The eidolon will use the same intro but use a different main I have because it’s music sounds better. It uses a variant joe loader after that and has no hidden data. I should be able to master with no issues.
Rescue on fractalus writes high scores to 18.2 and uses drive code to do so. That is the only reserved sector. Assuming that this drive code is stored in main, there should be no issues mastering this because there is plenty of room.
What’s the smallest assembler I can use to rebuild transwarp?
I intend to transwarp remaster every vorpal v1 original I can find. :) I probably can’t do Barbie though |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting ZaphodWhat’s the smallest assembler I can use to rebuild transwarp? Sorry, but i don't quite get this question. The source is intended to be assembled using 64TASS V1.56.2625 though (the build i used reports "64tass Turbo Assembler Macro V1.55.2200?" including the question mark). |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
My bad. Track 6 was full. It was 16 to 7. That’s why I needed the packing on main.
Anyway I can fix the bug in the intro then g pack it, which completes the release after I build the install only minimal transwarp. I still need a linker/packer that puts everything back where it was for ballblazer. This doesn’t need to preserve transwarp.
If someone can rewrite the game to move tracks 5 and 6 up one that ours be an improvement.
I would also like a way to transwarp encode a file that doesn’t load to $801 and provide a jmp address. This is for when I don’t need to pack the logo.
But I will probably just leave it G packed with a credit line of “transwarp by krill/plush” to give you credit. :) make use of the repacking delay. Will install transwarp lite (and call it that in the loading routine extending the text string) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting ZaphodI would also like a way to transwarp encode a file that doesn’t load to $801 and provide a jmp address. This is for when I don’t need to pack the logo. You can encode files loading to anywhere in $0400-$d000 just fine. Make sure to load them with ",8,1", though. =)
Quoting ZaphodBut I will probably just leave it G packed with a credit line of “transwarp by krill/plush” to give you credit. :) make use of the repacking delay. Will install transwarp lite (and call it that in the loading routine extending the text string) I guess the Transwarp boot banner is enough for giving credit. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
good point.
the install only version should have transwarp by krill/plush instead of the dots.
there's your credit, and then i get to add cute other messages on the g-packed intros, like
HOW'S THIS, SCOTT NELSON?
FASTER THAN A SPEEDING WARP*25
TRANSWARP BEATS LAZER
SPRINTING PAST HEUREKA |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodthe install only version should have transwarp by krill/plush instead of the dots. It does. No dots, just the banner. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
lol, the banner doesn't stay on the screen long enough. :)
i wanted it to skip the large banner, but DO the wooom sound and print out
SEARCHING FOR *
LOADING TRANSWARP V0.82 BY KRILL/PLUSH....
READY.
and then kick off everything. This way it stays long enough to look at. :)
ah well. release done. time to work on the others, unless someone can provide the build. The logo text i have of faster than a speeding warp*25 is nearly subliminal now, with the full g-pack on the logo. :) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodi wanted it to skip the large banner, but DO the wooom sound and print out Feel free to do that, but observe the license terms. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
Quoting KrillYou can encode files loading to anywhere in $0400-$d000 just fine. Make sure to load them with ",8,1", though. =)
but the encoder won't let me specify a jmp address.
the depack is so darn fast anyway that it's not worth the bother, though.
the logo now loads "COPYRIGHT*" so i can now have the same intro for everything BUT Rescue on Fractalus (that one is a dual intro, with the rescue on fractalus loading screen immediately following the lucasfilm intro) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
Quote: Quoting Zaphodi wanted it to skip the large banner, but DO the wooom sound and print out Feel free to do that, but observe the license terms.
Right. GPL.
anyway writing transwarp to track 4 does the job in 19 blocks.
while there are that many free on 17 and 18, cc1541 will not place it into the free blocks there properly, for some unaccountable reason, no matter what i do. it insists on leaving 2 open on 18, even with -t -u 0, and writing 11 blocks that shouldn't be there to 19, for a total of 29, when it only writes 19 to track 4.
i could actually fit the full one on 4-5 on this disk. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodbut the encoder won't let me specify a jmp address. It's just that, an encoder. It takes a regular .prg file and saves it in Transwarp format to a D64 disk image. No more, no less. Anything not loading to $0801, without a regular BASIC SYS line, does not carry an explicit entry point. The loading program or user must know this themselves.
Quoting ZaphodIt insists on leaving 2 open on 18, even with -t -u 0, and writing 11 blocks that shouldn't be there to 19 Track 18 sectors 0 and 1 are required for the BAM and a minimal directory of up to 8 files. Without them, you couldn't load the booter stub from plain BASIC.
What causes the extra blocks on track 19 might be seen with cc1541's verbose flag "-v". |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
I can't figure out out. 18.0 and 18.1 are used, as expected. a number of others are already used. but there are 20 free sectors between tracks 17 and 18, so a 19 block transwarp boot file should be able to hide there.
for some reason two OTHER sectors on track 18 are left empty when it tries to put in the loader, and it writes the boot file as a total of 29 blocks instead of 19, filling the rest of track 17, leaving 2 unallocated on 18, and writing 11 to track 19(!)
this IS with verbose showing what's going on. it's weird.
anyway done with the eidolon as well, and am happy with it.
ballblazer should be very simple if plush packer will actually put both parts where they should be. which one do i have first? the lower one, or the higher one?
rescue on fractalus is trickier because the intro for that one is NOT self contained. the loader banks out the kernal after loading the combined intro before JMPing to it. which probably means it clobbers transwarp. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodfor some reason two OTHER sectors on track 18 are left empty when it tries to put in the loader 19 blocks are 2 blocks too many on the dir track (it only has 19 blocks, and 2 are required for the directory).
If the bootfile doesn't fit on the dir track in its entirety and spills over to another track anyways, cc1541 gives it only 15 blocks on the dir track, so that up to 24 files can fit in the directory.
Quoting Zaphodand it writes the boot file as a total of 29 blocks instead of 19, filling the rest of track 17, leaving 2 unallocated on 18, and writing 11 to track 19(!) Can you post the exact printout for the bootfile, something that looks likeFile allocation:
18/10 32 (0x05 0x01:0xa0) "transwarp v0.84.prg" => "TRANSWARP V0.84" (SL: -4)
18/10 18/14 18/18 .18/03 !18/08 18/12 18/16 .18/02 18/06 !18/11
18/15 .18/05 18/09 18/13 18/17!-19/10 19/14 19/18!.19/03 19/07
19/11 19/15 .19/00 19/04 19/08 19/12 19/16 .19/01 19/05 19/09
19/13 19/17 Quoting Zaphodballblazer should be very simple if plush packer will actually put both parts where they should be. which one do i have first? the lower one, or the higher one? Lower in memory comes first. But the link feature is just for convenience, and there is no gap between the two chunks (load address of second file is ignored). If you want the gap, better link the two files manually before packing. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
had to rename "transwarp" to " transwarp" to get the eidolon to actually work for real (it was trying to joe load transwarp. silly me thought it was a file layout issue and beat my head against the wall wayyyyy too long on this.)
for ballblazer i should be able to just bank out everything, prefill memory, monitor load both parts, save them together spaced out as one file, then g-pack it sorted.
or not. i have saved the two parts out, but it only starts at $500 if io is banked out when it's loaded in the monitor. gpacker isn't getting it. i may have to cheat and find a working onefile sans intro for this one. except i can't find that EITHER. and plush packer won't pack it enough.
rescue on fractalus is still a royal pain, though. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodit only starts at $500 if io is banked out when it's loaded. gpacker is't getting it. Setting "$01 VALUE" to $30 in G-Packer doesn't work?
And what about that verbose printout about the mysteriously big Transwarp bootfile, with 29 instead of 19 blocks? =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
okay it seems that it's a glitch in the track display.
it ONLY shows it like that when the other file i'm trying to put in 19-21 is also being added.
so it's only stuffing 1 lousy block to track 19, which conflicts with the 19-21 file, and it's mistakenly showing 1 though 9 as filled. It will NOT show the transwarp chain when there's another error, which is what caused this strange result.
-t -u 0 should allow me to write transwarp into one of those last two directory sectors.
I'd have to add a dummy plain file into track 19 called koronis rift, then add copyright 1985 and transwarp into track 17, move the sector on track 19, fix the link, then scratch koronis rift, then transwarp add it to track 19
yeah, that worked.
and no it doesn't. never gets to the jmp $500. which according to the docs, it should be able to depack that range. if i store 30 in $01, then load both parts in the monitor, then g 500, it DOES work. i think it's because it's writing the blank textline and messing with screen memory. gonna try something.
no, that wasn't it. somehow it ends up clobbering a lot of zero page with $#87 |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodokay it seems that it's a glitch in the track display.
it ONLY shows it like that when the other file i'm trying to put in 19-21 is also being added. Keep in mind that in a print like this 18: ####.############## "ATG" "TRANSWARP V0.84" there is no notion of which block belongs to which of the two files or is allocated otherwise.
Quoting Zaphodso it's only stuffing 1 lousy block to track 19, which conflicts with the 19-21 file, and it's mistakenly showing 1 though 9 as filled. 2 blocks, i guess? And mistakenly? Those other 9 blocks may be from the other file you mentioned, no? Or may have been marked as occupied already in the disk image you use as a basis (use the -v option on it without adding any files to check).
Quoting Zaphod-t -u 0 should allow me to write transwarp into one of those last two directory sectors. It's in nanny mode for a reason at this stage (for maximum loading speed), and your case of working around pre-allocated blocks is quite special.
I will think about a solution, but in the meanwhile, well, the source is there to modify. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
well i did make a workaround that worked for that. so i squeezed that last block onto track 18, and mapped te other two. so yay, fastcopyable fastloading koronis rift. :)
It was ONE block, and though it filled it in, it didn't list any other filename on the track line. It JUST said transwarp. which is what caused the confusion. AND it didn't show the trace map for the transwarp file.
and for the eidolon i just had to rename the transwarp file cuz there was also a "tr" file for it's joe loader.
now if someone can build me a lucasfilm logo+loading pic+music for rescue on fratcalus that cleans up after itself and leave transwarp intact, i can get that one done, and it should still be able to block load the high scores from 18.2.
exomizer actually manages to get ballblazer's low and high main using #$38 at $01 during decrunch, but takes wayyyy too long. Is there a trick to making exomizer compress less and also decrunch faster? |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodnow if someone can build me a lucasfilm logo+loading pic+music for rescue on fratcalus that cleans up after itself and leave transwarp intact Do it the other way around. Move conflicting Transwarp code out of the way to memory areas not used by the intro, run intro, then restore Transwarp code. The Giana Sisters intro does that.
Quoting ZaphodIs there a trick to making exomizer compress less and also decrunch faster? Consider other options, especially other crunchers. Compressing should be last resort in this context, and if you need to compress, pack lightly. Exomizer really should only be used if you need minimum size and don't care much for speed. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
main issue is that the intro has the second stage loader routine inside of it, with a JSR to vorpal.
so it's not started wit a JSR.
so i need a version that can, say return to a basic program and then load the next stage. no packing is needed at all on the intro, since there's nothing pre-allocated to work around except 18-2
I just seem to be needing tools that don't quite exist, or are hard to find. Like a simple PC side program that works in windows command prompt that will turn scattered files in memory into a single self unpacking and relocating executable with a JMP address for ballblazer.
also, it seems that the high score saver talks to the vorpal drive code (and is back in the vorpal loader, which is not overwritten by anything). so i have to install vorpal after transwarp loading main! and going after v1 isn't any better, because also uses drive code left in place by it's loader to save the high scores (they are loaded with drive code halfway through the loader).
I'm going to actually have to reverse engineer how to start vorpal without initiating a load. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphoda simple PC side program that works in windows command prompt that will turn scattered files in memory into a single self unpacking and relocating executable with a JMP address NuCrunch V1.0.1 might fit that bill.
Quoting Zaphodit seems that the high score saver talks to the vorpal drive code (and is back in the vorpal loader, which is not overwritten by anything). so i have to install vorpal If neither speed nor background music/animation is required for hi-scores disk access, you can maybe just use the ROM routines. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
Quoting Krill NuCrunch V1.0.1 might fit that bill.
will give it a try. thanks.
nope. ballblazer's low part goes to $500, and NuCrunch can't do it.
Quoting NuCrunch
C:\c64\exomizer>nucrunch -xo "copyright 1984.prg" -j 500 g:\emulators\c64\blmain
0x0500-0xfff0: 64242 bytes read from g:\emulators\c64\blmain
error: self extracting option doesn't currently support destinations below $0800
Quoting Krill
If neither speed nor background music/animation is required for hi-scores disk access, you can maybe just use the ROM routines.
but then i'd have to actually write a score saver and loader when there is already one. Since we are already using drivecode, there's no reason not to put vorpal back in the drive if I can figure out HOW when the scores are loaded, which will leave it there for when they are saved.
normally games turn vorpal back off with a JSR to their own vorpal removal routine after the final load, suggesting vorpal to be a captive loader. but this one doesn't.
time to go trace a vorpal loader. ahh there we go. just need to jsr $1000 to put back the vorpal drive code.
so i just need to put this in free memory between the two.
JSR $1000
JMP $18c0
and bank out everything for the depack, and bank kernal back in to reload vorpal. above code fragment tested.
the saved scores are a standard dos sector, so vorpal being used to write and or read it in is not a problem for my release. seems vorpal CAN read normal sectors too.
This should complete the lucasfilm transwarp quadrilogy. :) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quote:error: self extracting option doesn't currently support destinations below $0800 That explains why no mention of maximum decrunch area in the readme.
However, you can still copy that chunk manually after decrunch. It's not hard.
But please do open another thread for anything not directly Transwarp related. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
out of curiosity, how small would a transwarp that operates like vorpal be?
you pass it the starting track, number of transwarp blocks to read, and the load address, and it loads the file.
the game version of vorpal fits within 1k of memory, and exists in many versions that load to different addresses.
protection check optional (laugh) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodout of curiosity, how small would a transwarp that operates like vorpal be? Maybe $0800 bytes. But you'd need to pass more parameters: starting track, load address, end address, file data checksum.
However, Transwarp is not intended as an integral part of a program, but ultimately as a cartridge speeder.
That's why it's supposed to be operated via the KERNAL's standard LOAD interface (load vector at $0330).
Re-encoding Transwarp files that load files themselves back to standard format shall yield perfectly working programs using whatever load routine that comes with the load vector, for whatever range of devices, original CBM or aftermarket.
Also note that Transwarp is released under GPL for a reason. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
okay. i have discovered a real bug. :)
sound without erstat does not leave the sid registers in the same state that sound with er stat does.
This is most likely because erstat adds the "tink" at the end, which fixes the sid registers.
This broke the lucasfilm intro, which assumes a default sid state.
the pow pow chicka chick didn't last long enough anyway. :) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
ERSTAT does not add the ting at the end, this is solely controlled by SOUND. My bet is on another uninitialed variable issue in that intro. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
I JUST loaded the intro with the sound version. i got NO "tink"
when i use the full version, i get the tink.
the tink happesn during the speed timing dispaly.
when sound and erstats are on, the speed rating is enabled too. that's what does the tink.
the assumption of the sid being in it's default poweron state is reasonable for the intro to make, since it' sonly ever called from it.
The tink gets it close enough for the intro to work. I don't know what the default values for the sid registers are, or how to reset them without making a sound.
maybe my 64tass is borked, but when my 6,675 byte transwarp without erstats or crypto is used, it DOES NOT TINK AT END OF LOAD.
also, sound without erstats reloads itself once.
I now have installonly, install+compat, install+compat+sound, install+compat+sound+erstats, and full. full is identical to the compiled download.
install+compat+sound is the one that is misbehaving. please compile with this combination and test for yourself. :)
if that tink does not happen, the sids registers are left in a seriously weird state that completely silences not only the lucasfilm logo but the eidolon main game itself as well! |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
I believe it's merely a timing issue, and nothing i care to "fix".
The ting sound is done by setting a few SID registers, then waiting for about 6 video frames, then clearing the gate, then going on.
That is, it may be that the release phase is cut short by whatever the intro is doing, and with the stats (or anything else delaying executing the payload program) enabled, the intro is actually run ever so slightly later so the ting sound is (more) audible. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
the tings happen when the speed results are printed out.
when they are not printed, the tings don't happen.
i can hear two tings, one for each speed info line.
It doesn't matter how long i wait after the load finishes. I can wait a minute after loading the intro with ,8 after loading transwarp. It still breaks. so it's not a timing issue with the intro trying to start too fast.
insert disk with sound no erstats transwarp
LOAD TRANSWARP",8,1
loads with wooom and dots
reloads a second time with WOOM and dots. (not supposed to happen!)
ejectt disk, and insert the eidolon
LOAD "THE EIDOLON" ,8
(screen blank, tune plays)
ready.
no ting.
wait 1 minute
run.
silent intro.
game loads. silent GAME.
If I knew what it was doing exactly to silence the SID instantly before the tings (it's not the master volume, i tried poking that before running the intro, no dice), and how it differed from the default state of the registers, I could fix the intro, which would then fix the game. But i haven't been able to work out how to patch the loader to trip the ting when erstats is off. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Okay, could reproduce the problem.
In line 3788, there is jsr pausreadtmr
.if SOUND
;sec
rol sndplaying
.endif; SOUND
jsr reinittimer Uncommenting the sec should fix it.
(Without ERSTAT, pausreadtmr does not return with the carry flag set.)
I still maintain that the intro does not properly initialise variables (SID registers), though. :) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
yeah, that fixes it.
now why does transwarp double load if erstats is off and sound is on? (this only affects loading transwarp directly, everything else works)
also i figured out (somewhat) why autobooting a basic program doesn't work.
the basic pointers aren't initialized properly when doing the autoboot. exomizer sfx basic +relocating decrunch table solves that, which finally lets me make booga-boo work as an intro then load. |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
so when loading a file NOT to $0801, it auto jumps to the start address when you load it without transwarp on? with a bit of testing, that's what it seems happens. problem is that's not always the start address. guess the solution is adding jmp 3 bytes before to the real start address?
hmm. could two more bytes be added to the directory entry to specify optional auto jump address? probably not, as the tranwarp signature appears to use all but 1 of the free bytes.
i've decoded what all but two of the bytes most likely are (the one above and the one below starting track puzzle me) |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting Zaphodnow why does transwarp double load if erstats is off and sound is on? (this only affects loading transwarp directly, everything else works) Could not reproduce this. What are the 5 options set to, which name does the Transwarp bootfile have in the directory, and what is your exact LOAD command?
Quoting Zaphodalso i figured out (somewhat) why autobooting a basic program doesn't work. Yes, there are a couple of bugs in v0.82 regarding running BASIC programs, will be fixed in a patch release.
Quoting Zaphodso when loading a file NOT to $0801, it auto jumps to the start address when you load it without transwarp on? with a bit of testing, that's what it seems happens. I guess you mean booting a Transwarp file from plain BASIC. This should just execute the RUN command after loading, regardless of where the file is loaded to.
Quoting Zaphodproblem is that's not always the start address. guess the solution is adding jmp 3 bytes before to the real start address? The solution is to make the program RUN-able. =)
Quoting Zaphodcould two more bytes be added to the directory entry to specify optional auto jump address? probably not, as the tranwarp signature appears to use all but 1 of the free bytes. All bytes are used. But even if there were 2 more available, i'd not add an entry address to the meta data, as this isn't supported by plain .PRG files nor the KERNAL load API.
Quoting Zaphodi've decoded what all but two of the bytes most likely are (the one above and the one below starting track puzzle me) #define TRANSWARPSIGNATROFFSLO 21
#define TRANSWARPSIGNATURELO 'T'
#define TRANSWARPSIGNATROFFSHI 22
#define TRANSWARPSIGNATUREHI 'W'
#define DIRDATACHECKSUMOFFSET 23
#define TRANSWARPTRACKOFFSET 24
#define FILECHECKSUMOFFSET 25
#define LOADADDRESSLOOFFSET 26
#define LOADADDRESSHIOFFSET 27
#define ENDADDRESSLOOFFSET 28
#define ENDADDRESSHIOFFSET 29
#define FILEBLOCKSLOOFFSET 30
#define FILEBLOCKSHIOFFSET 31 I guess you mean the bytes at offsets 23 and 25: checksums. =) |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
Quoting KrillCould not reproduce this. What are the 5 options set to, which name does the Transwarp bootfile have in the directory, and what is your exact LOAD command?
crypto is off, bootname is transwarp, erstats is off, all others are on.
i have it named transwarp, and it happens when using any wildcards. i usually trip it with something like
"LOAD"TR*",8,1
if i actually type
LOAD "TRANSWARP",8,1
it doesn't happen.
if sound is off, it doesn't happen.
but if sound is on, and erstats is off, it does.
**** commodore 64 basic v2 ****
64k ram system 38911 basic bytes free
ready.
load"*",8,1
searching for *
loading
\\\transwarp
\\\\krill/plush
////v0.82
///
\\\transwarpr *
\\\\krill/plush
////v0.82
///ready.
Quoting Krill
I guess you mean booting a Transwarp file from plain BASIC. This should just execute the RUN command after loading, regardless of where the file is loaded to.
oh. must be the same bug that breaks basic programs having anything more than a sys line.
i crashed the computer with
LOAD"PULGA1",8,1
it loads to $c000 just fine, but then when it prints run, the top part 40% of the screen corrupts, even though nothing in basic was loaded at all, and the computer hangs. so i thought it was executing something, and it couldn't be basic code because nothing was loaded to that memory area.
but turns out JMP $c000 doesn't produce that crash after all.
anyway i can autostart ml easily enough if i use an ML loader, by pushing the start address onto the stack and JMP instead of JSR to start the load. and i can put this ml loader at the start of basic. Or i can make a 1 block basic loader. but that would use an entire track for one or two blocks. yeah it only takes half a second to relocate or so, but i'd like to save that half a second. :)
The teeny basic menu concept has the same problem. You are stuck using an entire track unless you save it as a normal non transwarp program, so to make it worth it you need to include more bells and whistles in the menu to fill out the track, since the space is taken up anyway. like say a character set and sid tune. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Hmm, still cannot reproduce the double-load issue. Do you maybe have the Transwarp bootfile as first file in the directory?
Quoting Zaphodyeah it only takes half a second to relocate or so, but i'd like to save that half a second. :) Half a second? Copying $4000 bytes to $c000 should only take about a quarter of a second, and i guess the program is smaller than 16 KB? |
| |
Zaphod
Registered: Jun 2012 Posts: 63 |
it happens whether or not it's the first file.
CRYPTO = 0
.endif; BOOTNM = TRANSWARP
SOUND = 1
ERSTAT = 0
COMPAT = 1
INSTAL = 1
Hmm. i can't reproduce, except with "*" in PAL. but it happens 100% with ntsc.
still yet to find a convenient tool that converts 1 or more files into a self relocating blob. I'm well aware that it's laziness, but why can't i tell exomizer to just NOT compress? :) if i -M 0, it just hangs (laugh)
i only consider the workaround acceptable for booga boo because i removed a pointless delay from the original loader which is about the same length.
anyway can confirm 0.84 has the basic bug fixed, and now i have zero compression at all on booga-boo. 209 transwarp blocks for the two files, and zero delays. found out how to use basic's own transfer forward routine (the one used when you insert a line), which works here since we aren't going in or out of basic memory. and there were three free bytes after the 00 00 00 in the original main program to wedge in a JSR to move the data up. it's now quite the impressive showcase. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Goof Info
Submitted by Peiselulli [PM] on 18 October 2021
"compat error (check user port") if a 4 player adaptor is plugged in ...
Goof Info
Submitted by Krill [PM] on 18 October 2021
Peiselulli: Entirely expected behaviour. :) If the user-port device drives the parallel port pins stronger than CIA $dd01/$dd03 set to output does, jmp ($dd00) won't work. Now... i've been thinking about moving the jump table to $ff00.
This would work with user port devices that drive the parallel port with $ff when idle, but with a 4-player extension i guess that means that loading can break randomly with some devious fellow player moving the joystick while loading.
Not sure if that's better than bailing out right away.
But then there are also things like WLAN modems for the user port, where such a change might make sense.
Any more relevant user port devices which might tip the scales on this issue?
(Those things should be more well-behaved by default and go tri-state when idle, provide proper buffers etc., but alas... Commodore hardware and cheap must go together, i guess.) |
| |
Frantic
Registered: Mar 2003 Posts: 1648 |
There is a relatively new midi interface for the user port called "the vessel". Not sure if huge amounts of people care, but from my own personal perspective I do care. I have it plugged in more or less at all time. |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting FranticThere is a relatively new midi interface for the user port called "the vessel". Not sure if huge amounts of people care, but from my own personal perspective I do care. I have it plugged in more or less at all time. Okay, i do care for proper music gear. Does Transwarp complain with the thing plugged in? :) |
| |
Frantic
Registered: Mar 2003 Posts: 1648 |
I'll check next time I have the possibility to do so. Might take some time unfortunately, because at the moment I am buried in work.
Here is a link to the midi interface I mentioned:
https://github.com/anarkiwi/vessel
I also have one of those wifi modems for the user port by the way, that I use from time to time. I'll try that as well next time the gear is running. |
| |
JackAsser
Registered: Jun 2002 Posts: 2014 |
Quote: Goof Info
Submitted by Peiselulli [PM] on 18 October 2021
"compat error (check user port") if a 4 player adaptor is plugged in ...
Goof Info
Submitted by Krill [PM] on 18 October 2021
Peiselulli: Entirely expected behaviour. :) If the user-port device drives the parallel port pins stronger than CIA $dd01/$dd03 set to output does, jmp ($dd00) won't work. Now... i've been thinking about moving the jump table to $ff00.
This would work with user port devices that drive the parallel port with $ff when idle, but with a 4-player extension i guess that means that loading can break randomly with some devious fellow player moving the joystick while loading.
Not sure if that's better than bailing out right away.
But then there are also things like WLAN modems for the user port, where such a change might make sense.
Any more relevant user port devices which might tip the scales on this issue?
(Those things should be more well-behaved by default and go tri-state when idle, provide proper buffers etc., but alas... Commodore hardware and cheap must go together, i guess.)
$0100 ftw! |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
Quoting JackAsser$0100 ftw! Please elaborate. :)
Table at $0100? Which problem would that solve for you? |
| |
Krill
Registered: Apr 2002 Posts: 2982 |
For any testing, please refer to https://bitbucket.org/KrillPlush/transwarp-test/downloads/ where i keep binaries of the latest version for a patch release. |