| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
Krill Loader & Open borders
I have problems while loading with Krills loader and at the same time have open upper & lower borders. As soon as i start to load the borders starts to flicker.
Note: i don't do anything else in the interrupt, just opening the upper & lower border.
Anyone have a clue why ? |
|
| |
Martin Piper
Registered: Nov 2007 Posts: 722 |
Does the loader use SEI/CLI? |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
thats what i first tought but couldnt find it in the code. |
| |
Burglar
Registered: Dec 2004 Posts: 1101 |
you probably timed the openborder code too tight.
which rasterline do u set $d011? I use $fa, should work fine. |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
$fa here aswell. (and been randomly trying different values with the same result :)). |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
If you look at the test program that comes with the loader, you'll notice that it opens the borders while loading.
There is no SEI/CLI in the code, so interrupts have the exact same latency and jitter as without loading.
I guess you have not enabled KERNAL fallback, which might explain this behaviour if the loader misdetects the drive for some reason (detected drive type is returned in the X register after install).
Currently i have no idea what could cause this, but you can send me a minimal test program so i can have a look.
|
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
Krill, i've sent you a mail now. (to krill at plush dot de)
|
| |
Krill
Registered: Apr 2002 Posts: 2980 |
You have enabled loading to the memory under the IO space at $d000-$dfff. Thus, the loader will switch $01.
Your interrupt handlers buffer $01 nicely, but they don't set it after buffering, so the writes to $d012 to set another trigger line and $d019 to ack the IRQ are ineffective when the loader was interrupted after having disabled the IO registers in order to write to $d000-$dfff.
Just set $01 to enable IO registers after buffering it in your IRQ handlers.
Btw., loading to $d000-$dfff decreases loader performance quite a bit, as it has to set $01 twice for each received byte.
Consider working around the need to do so, or use two incarnations of the resident code, one with and one without loading under IO space, the former only when it's really needed. |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
yeah found it now :)
and cant really avoid loading under $d000 unless i split my files in several parts and do a manual memcpy. unfortunely all our parts takes $08000-$ff3f. |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
Is there a build flag for this:
"or use two incarnations of the resident code, one with and one without loading under IO space"
or do i manually need to do something :) |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Manually. Build the loader twice with and without load under IO. You'll notice the install portions are identical except for different configuration strings. |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Now that i think about it, maybe i will add some code for the load under IO option, so the loader will have two getblock loops, one with and one without $01 writes, and choose either depending on the destination of the block to be downloaded from the drive. |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
yeah :) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
Quote:maybe i will add some code for the load under IO option, so the loader will have two getblock loops, one with and one without $01 writes, and choose either depending on the destination of the block to be downloaded from the drive.
please, that might even allow me to use a non hacked version of the loader =) |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
Krill, how long will that modification take ? :) |
| |
algorithm
Registered: May 2002 Posts: 705 |
Although, memory constraints aside, it may just be faster to load to another area, then do a quick memcopy via irq in segments (would take a few frames or so) which may be faster then loading directly to IO perhaps.
Great to have the feature of detection and adjust loader accordingly however instead of two loaders |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Quote: Krill, how long will that modification take ? :)
Effectively a few hours of work. I'll be on vacation for the next two weeks, but there'll be time to code. But two weeks should be alright, i hope? :) |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Quote: Quote:maybe i will add some code for the load under IO option, so the loader will have two getblock loops, one with and one without $01 writes, and choose either depending on the destination of the block to be downloaded from the drive.
please, that might even allow me to use a non hacked version of the loader =)
Heh, is your modification doing exactly that?
But for the next time, please tell me such things so i can add it to the code base and other users can benefit from it as well. |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
nice :) 2 weeks is fine :) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
Quote:Heh, is your modification doing exactly that?
in a very ugly way - i compiled both versions, with some padding here and there... and patch the binary with the diffs =P |
| |
Danzig
Registered: Jun 2002 Posts: 440 |
Quote:in a very ugly way - i compiled both versions, with some padding here and there... and patch the binary with the diffs =P
so now sit down and "binary patch" raydomat to create MUIFLI-output. (husch-husch) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
it already supports that =D |
| |
algorithm
Registered: May 2002 Posts: 705 |
Great! Lets see it :-) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
i have lost interest in converted pictures in these unuseable modes to be honest. at the end of the day, koala wins :) |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Quote: nice :) 2 weeks is fine :)
Pantaloon: Traded size for speed now with the load-to-$d000..$dfff option. Grab new loader version at
http://krill.earthtomoon.net/loader-v142.zip
Note that the default now uses a new kind of protocol, TWO_BITS_RESEND, as it is faster than TWO_BITS_ATN when not having multiplexer walls of sprites. |
| |
HCL
Registered: Feb 2003 Posts: 728 |
Rumors say that it is impossible to have open borders together with Krill's loader. Not sure though as i have never tried, but good luck Pantaloon ;). |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
Indeed! :) |
| |
The Human Code Machine
Registered: Sep 2005 Posts: 112 |
Thx for the improvement! |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
it's only rumors, works perfectly here :) |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
infact you have to configure HAVE_SANE_TIMING or it will not work! |
| |
Pantaloon
Registered: Aug 2003 Posts: 124 |
Krill, you have mail, i have another issue now .) |
| |
Frantic
Registered: Mar 2003 Posts: 1648 |
Maybe you have enabled HAVE_INSANE_TIMING? |