Making compute's gazette VIC turbodisk for ROM

Basic and Machine Language

Moderator: Moderators

User avatar
Mike
Herr VC
Posts: 4831
Joined: Wed Dec 01, 2004 1:57 pm
Location: Munich, Germany
Occupation: electrical engineer

Post by Mike »

I downloaded the Jul. '85 version of Turbodisk at arnold.c64.org, and made a quick shot at it. Turbodisk resides in the last 5 pages of the available RAM. The very last page is used as sector buffer. So the whole code only needs 1K, but ...

1. The filename is copied into the code, that is transferred into the 1541. That can't be easily altered.

2. Turbodisk doesn't work with the 1571.

3. Within VICE, Turbodisk made transmission errors in PAL (NTSC was ok.)

Aren't there other fast loaders which might more suited?

Michael
ruud
Vic 20 Devotee
Posts: 245
Joined: Wed Aug 04, 2004 11:26 pm

Post by ruud »

Hallo Michael,

Regarding the filename: what about copying the piece of code to RAM first, then copy the filenam to it and then copy the whole from RAM to disk?

Regarding the 1571: have you tried to put it in VIC-20 mode first? (if that exists at all)

Code: Select all

    ___
   / __|__
  / /  |_/     Met vriendelijke groet, Ruud Baltissen
  \ \__|_\
   \___|       URL: www.baltissen.org

User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

Mike wrote:I downloaded the Jul. '85 version of Turbodisk at arnold.c64.org, and made a quick shot at it. Turbodisk resides in the last 5 pages of the available RAM. The very last page is used as sector buffer. So the whole code only needs 1K, but ...

1. The filename is copied into the code, that is transferred into the 1541. That can't be easily altered.

2. Turbodisk doesn't work with the 1571.

3. Within VICE, Turbodisk made transmission errors in PAL (NTSC was ok.)

Aren't there other fast loaders which might more suited?

Michael
First, thank you for this fantastic insight. Its an excellent strart.

Second, VIC turbodisk may not work with a 1571 for an unknown reason but it does work well with a 1541 (obviously) and a 1541-II.

Why it wouldn't work in PAL is probably just a question of slightly different timing.

If its just a question of the filename being incorporated in the code sent to the floppy drive then I think it should be easy to tell the routine that transfers this code to send everything that is in the ROM before the filename, then, the part that contains the filename (in the cassette buffer ?) then the part that is after the filename in the ROM...

Obviously what I presently use is a modified version of the installer that puts Turbodisk at $9800 instead of the normally used last 5 pages of available Basic RAM. Presently, I am forced to have NVRAM there because of the way this software works.

I don't know much but this is truly the one and only disk accelerator I know for the VIC. The fact that it can so easily be relocated is what made possible the usage I have for it now.
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

ruud wrote:Regarding the filename: what about copying the piece of code to RAM first, then copy the filenam to it and then copy the whole from RAM to disk?
One of the reason why Turbodisk is so versatile the way I use it right now is because all the RAM it uses is at IO2 and IO3, this software will never have a memory conflict with what it is trying to load. All I have to do to activate it when I turn on the VIC is type SYS152*256 or SYS38912.

I suspect, let's say I use 2k of RAM in whatever block and then put the filename in it, well, what if the data being loaded goes into that same memory area? Not to mention the fact that it forces you to designate an area of memory as been safe for this usage.

If you have a software that loads in multiple parts then you could be in trouble with part of what you already loaded being destroyed by that 2k section of data being regenerated in a utilized area.
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

Marko Mäkelä wrote a fastloader, which Albert of Pu-239 improved on in VIMM, to which there is assembly source code available. See bottom of this page:

http://www.cs.tut.fi/~albert/Pu-239/vimm/ and download vimm-src.lha.

Perhaps there are other, even better fastloaders out there, but it could be a good start. I might look into loader.asm to see what it does and if it can be used separately.
Anders Carlsson

Image Image Image Image Image
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

carlsson wrote:Marko Mäkelä wrote a fastloader, which Albert of Pu-239 improved on in VIMM, to which there is assembly source code available. See bottom of this page:

http://www.cs.tut.fi/~albert/Pu-239/vimm/ and download vimm-src.lha.

Perhaps there are other, even better fastloaders out there, but it could be a good start. I might look into loader.asm to see what it does and if it can be used separately.
That is just beyond my abilities with ML programming.
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

I had a brief look into the code yesterday, and I think it is doable. I haven't made any testing yet though, and the fast loader is implemented as part of an IRQ routine, but I don't think it is important. I'll let you know if I manage to make a standalone turbo program out of it.
Anders Carlsson

Image Image Image Image Image
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

carlsson wrote:I had a brief look into the code yesterday, and I think it is doable. I haven't made any testing yet though, and the fast loader is implemented as part of an IRQ routine, but I don't think it is important. I'll let you know if I manage to make a standalone turbo program out of it.
yesssssssss
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

So far, I manage to crash the 1541 CPU when uploading the drive part. Dunno why, I have just reordered parts of the code.

Except for the little detail it doesn't work at all for the moment, the assembled code size is 1046 bytes + load address. However that includes a number of self-modifying memory locations (i.e. it should run in RAM). Once I get it to function, I will look into how to separate the code part (ROM) from data part (RAM)
Anders Carlsson

Image Image Image Image Image
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

Still no working solution ? Carlson, Mike, Anyone ??
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

Sorry, no luck. I don't understand why it doesn't work, but it doesn't.
Anders Carlsson

Image Image Image Image Image
carlsson
Class of '6502
Posts: 5516
Joined: Wed Mar 10, 2004 1:41 am

Post by carlsson »

Hm, I think I'm onto something.

Edit: Now it functions. For short files, it doesn't make any difference. For long files (about 60 blocks or more), it is quite a speed-up.

However, there are a number of shortcomings:

1. Once the turbo is installed, if you execute a regular load command, the turbo breaks and you need to load and re-install it again.
2. It currently can not use wildcards, i.e. WED*
3. It loads files to their load address ,8,1

However, according to a1bert's code, it should run on 1541/71/81.

Currently it is configured to run from $A000 and has a bit of self-modifying code which I need to fix so it can be put in a ROM.

With other words, it is not yet in a format you have use of. Maybe I can fix all this stuff in the weekend if I'm out of other things to do. The original code was released as GPL, so this must too. Not sure if it makes any difference for your usage.

I will post some executable when it is complete.
Anders Carlsson

Image Image Image Image Image
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Post by eslapion »

carlsson wrote: Currently it is configured to run from $A000 and has a bit of self-modifying code which I need to fix so it can be put in a ROM.
My solution was to run it from $9800. Im my actual VIC, I put NVRAM at IO2 and IO3 ($9800-$9FFF) so I don't have to reload it again and again.

It also doesn't conflict with anything I might want to load. If it was a ROM software, that is where I think it is best to put it.
Post Reply