| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
How to split the screen horizontally ?
........
No problem, to split the screen vertically, through the use of $ d012
..................
graphic
lda # $ 60
aa cmp $ d012
bne aa
text
........
|
|
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
it works exactly the same, except you need cycle exact timing. (that said, it doesnt really work terribly well with $d011 ... try $d021 first to get the idea, and to get the timing right). |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
someone who has a small example? |
| |
Cybernator
Registered: Jun 2002 Posts: 154 |
1000 78 SEI
1001 A9 00 LDA #$00
1003 8D 11 D0 STA $D011
1006 A9 06 LDA #$06
1008 A2 04 LDX #$04
100a 8D 20 D0 STA $D020
100d A0 05 LDY #$05
100f 88 DEY
1010 D0 FD BNE $100F
1012 EA NOP
1013 8E 20 D0 STX $D020
1016 A0 04 LDY #$04
1018 88 DEY
1019 D0 FD BNE $1018
101b 24 00 BIT $00
101d 4C 0A 10 JMP $100A
This one simply switches the border color. (Try hitting RESTORE repeatedly. :)) Making a graphics/text split gets more involved. Since you can't make a split in a middle of a badline, you'll have to abort (yes, begin then abort) the badlines. Also, the modes won't work the way you probably expect since the VIC won't do any C-accesses.
|
| |
null Account closed
Registered: Jun 2006 Posts: 645 |
uhm. wouldn't a horizontal be much easier than vertical?
becauase, afaik:
left to right == horizontal
top to bottom == vertical.
...or I just misunderstand the question..
------------------------------------
http://zomgwtfbbq.info |
| |
Trooper
Registered: Sep 2002 Posts: 39 |
SEI
nope1 lda $d012 ;these lines check
raster1 cmp #$80 ;the raster and wait
bne nope1 ;until it reaches the point
LDA #$01
STA $D020
nope2 lda $d012 ;these lines check
raster2 cmp #$90 ;the raster and wait
bne nope2 ;until it reaches the point
lda #$02
sta $d020
ldx #$50
slowdown dex
bpl slowdown
inc raster1+1
inc raster2+1
JMP nope1
|
| |
Mace
Registered: May 2002 Posts: 1799 |
Quote: uhm. wouldn't a horizontal be much easier than vertical?
becauase, afaik:
left to right == horizontal
top to bottom == vertical.
...or I just misunderstand the question..
------------------------------------
http://zomgwtfbbq.info
Yeah, left to right == horizontal, but if you want left and right to be different (i.e. split), it's vertical ;-) |
| |
iAN CooG
Registered: May 2002 Posts: 3197 |
*=$0801
word eop
word 7102
byte $9e,[startprg]d,0
eop
word 0
startprg
sei
lda #$35
sta $01
lda #$7f
sta $dc0d
lda $dc0d
lda #<irq
sta $fffe
lda #>irq
sta $ffff
lda #<nmi
sta $fffa
lda #>nmi
sta $fffb
lda #$18
sta $d012
lda #$0b
sta $d011
lda #01
sta $d01a
sta $d019
cli
jmp *
irq
inc $d019
sta sa+1
stx sx+1
sty sy+1
nop
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
lda #$00
sta $ff
startpiece
lda #$05
ldx #$01
ldy #$02
sta $d020
bit $24
bit $24
bit $24
stx $d020
bit $24
bit $24
bit $24
bit $24
sty $d020
bit $24
bit $24
nop
lda #$00
sta $d020
nop
endpiece
dec $ff
bne startpiece
nop
sa lda #00
sx ldx #00
sy ldy #00
nmi rti
|
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote:
*=$0801
word eop
word 7102
byte $9e,[startprg]d,0
eop
word 0
startprg
sei
lda #$35
sta $01
lda #$7f
sta $dc0d
lda $dc0d
lda #<irq
sta $fffe
lda #>irq
sta $ffff
lda #<nmi
sta $fffa
lda #>nmi
sta $fffb
lda #$18
sta $d012
lda #$0b
sta $d011
lda #01
sta $d01a
sta $d019
cli
jmp *
irq
inc $d019
sta sa+1
stx sx+1
sty sy+1
nop
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
lda #$00
sta $ff
startpiece
lda #$05
ldx #$01
ldy #$02
sta $d020
bit $24
bit $24
bit $24
stx $d020
bit $24
bit $24
bit $24
bit $24
sty $d020
bit $24
bit $24
nop
lda #$00
sta $d020
nop
endpiece
dec $ff
bne startpiece
nop
sa lda #00
sx ldx #00
sy ldy #00
nmi rti
word eop
word 7102
byte $9e,[startprg]d,0
word 0
dont work to type in assembler ?
this rutine make raster that is cros on the screen.?
i want to have text on the left and gfx on the right =) |
| |
Frantic
Registered: Mar 2003 Posts: 1648 |
Oh... so you want to do a vertical split. ;) |
| |
Stainless Steel
Registered: Mar 2003 Posts: 966 |
For ACME compatible xcompilers, try this :
*=$5000
sei
lda #$35
sta $01
lda #$7f
sta $dc0d
lda $dc0d
lda #<irq
sta $fffe
lda #>irq
sta $ffff
lda #<nmi
sta $fffa
lda #>nmi
sta $fffb
lda #$18
sta $d012
lda #$0b
sta $d011
lda #01
sta $d01a
sta $d019
cli
jmp *
irq
inc $d019
sta sa+1
stx sx+1
sty sy+1
nop
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
bit $24
lda #$00
sta $ff
startpiece
lda #$00
ldx #$02
ldy #$07
sta $d020
bit $24
bit $24
bit $24
stx $d020
bit $24
bit $24
bit $24
bit $24
sty $d020
bit $24
bit $24
nop
lda #$01
sta $d020
nop
endpiece
dec $ff
bne startpiece
nop
sa lda #00
sx ldx #00
sy ldy #00
nmi rti
just jump to $5000 once the file is loaded.
|
| |
yago
Registered: May 2002 Posts: 333 |
A vertical split on $d011..
I doubt you can change graphic-mode from text to bitmap , but you will explore some nice and strange effects
|
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
try some of the wonderland demos, the d011 split thing is in one of them (yes it does work if you do it right) :) |
| |
Cybernator
Registered: Jun 2002 Posts: 154 |
Here goes a little experiment. Assemble with ACME and make sure you write something on the first charrow before running (so you can see the problem caused by lack of C-accesses). Be warned that it will take a lot more effort before you can display "proper" graphics/text.
!to "hsplit.prg"
*=$1000
a = 2
x = 3
y = 4
sei
lda #$35
sta $01
lda #$7f
sta $dc0d
sta $dd0d
lda $dc0d
lda $dd0d
lda #1
sta $d01a
lda #$1b
sta $d011
lda #$38
sta $d012
lda #$c8
sta $d016
lda #0
sta $d015
lda #<irq1
ldx #>irq1
sta $fffe
stx $ffff
lda $d019
sta $d019
cli
inc $c000,x
bne *-3
beq *-5
jmp *
irq1 sta a
stx x
sty y
inc $d012
lda #<irq2
sta $fffe
dec $d019
cli
keep_noping:nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
jmp keep_noping
irq2 pla
pla
pla
lda $d012
ldx #6
dex
bne *-1
bit $00
cmp $d012
beq *+2
!for i, 192 {
lda #$38 + (i&7)
ldx #$18 + ((i+1)&7)
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
bit $00
sta $d011
nop
nop
nop
nop
nop
nop
nop
nop
bit $00
stx $d011
nop
nop
nop
bit $00
}
lda #<irq1
sta $fffe
lda #$38
sta $d012
lda #$1b
sta $d011
dec $d019
lda a
ldx x
ldy y
rti
|
| |
HCL
Registered: Feb 2003 Posts: 728 |
..so i say what most others seem to be trying say, only being hardly understandable.. :)
There is no easy trick to split the screen vertically between gfx and text. However, it may still be possible, depending more precisely on your interpretation of "gfx" and "text". Do you want multicolor bitmap gfx, or is it ok with 3 colors + background? Maybe we're talking gfx in hires!? And the text, is it ok with a 7 pixels high font? Does it have to be text on a char-screen, or can it be text on bitmap?
..need more info to solve the problem. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
i still recommend watching a few of the demos which demonstrate this :) in most of them you can also clearly see the problems connected to it (eg the fli-bug alike mess you almost certainly get somewhere across the screen) |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
After all, has seen many demos (from the old days) =), which raster lines divided up in many different colors from left to right.
These are split up, some ideas how it is done? |
| |
HCL
Registered: Feb 2003 Posts: 728 |
Example plz. Name a demo. |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
color splits are a lot easier to achive than text/gfx :) the stuff seen in really old demos (with say 4 or 5 splits) doesnt even need precise timing, since all you do is covering the screen with a multicolor pattern and do rasterbars in d02x. and the "40 splits" stuff is just...fli =) |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote: Example plz. Name a demo.
Raster Crime
this one =) nice demo..
Someone who has example of such a routine to split the raster =)? |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
one more =)
Raster Machine |
| |
Mantiz Account closed
Registered: Apr 2006 Posts: 36 |
If all you want is to have regular gfx on one side of the screen and text on the other, the easiest way would probably be to simply have a picture which uses only half the screen and then plot the text into the blank side of the bitmap. It would not be hardcore coder pr0n but it will work and it will take no timing at all for the display routine, as there will be no display routine to worry about at all.
All you need is to understand how the bitmap works and is setup in order to be able to put the text wherever you want it. You probably need to setup screen and color ram for the text area as well.
In order to to a regular horizontal text scroller on one part of the screen and you want to use $d016 for softscroll, you need pretty precise timing to set $d016 accordingly between the moving part of the screen (the text) and then change $d016 back when the rasterbeam hits the picture part, and then do the same over and over for every line your chars are displayed. Also you need a routine to plot the letters on the screen from the charset, as you are working in bitmap mode.
|
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
what about, filling sprites on the side of the image of text.
should be the easiest way =) |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
what about, filling sprites with text, on the beside the image .
should be the easiest way =) |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
arg |
| |
HCL
Registered: Feb 2003 Posts: 728 |
Using sprites is surely one way to go, but i still don't really get what you want to do. You talk about splitting between graphics and text, and then you show us some demos with raster splits. That's something completely different, really <:). |
| |
Danzig
Registered: Jun 2002 Posts: 440 |
what about converting the gfx to 3col, leaving the first $0200 bytes free for a regular 1x1-charset and then showing it on screen... switch on mc in $d016 and use $d800&0x07 you get singlecolor for the charset. using some fine rasterroutine behind that for the mc-colors ($d022/23) gives you a pretty colorful logo... wisely used ;)
or take a look at crest light... vision moved the logo up and down, plotted huge balls on the screen and had even an upscroller in 1x2 size.. killer back then. |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
yes it is true =)
thought it was the same thing splitting text and graphics.
if there was a way similar like use D012 to splitt from top to bottom
understand there are 2 different things
any idea, how to splitt raster like in the demo's |
| |
Hein
Registered: Apr 2004 Posts: 954 |
lda #color1
sta $d021
lda #color2
sta $d021
lda #color3
sta $d021
and so on till you fall of the earth. |
| |
Graham Account closed
Registered: Dec 2002 Posts: 990 |
Quote: A vertical split on $d011..
I doubt you can change graphic-mode from text to bitmap , but you will explore some nice and strange effects
Ice Cream Castle (part CHOCOLATE ICE splits text from MC bitmap)
Coma Light 8 (part 03 splits text from FLI)
|
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
thank you all
how do I find this acme assembler. ? =) |
| |
Stainless Steel
Registered: Mar 2003 Posts: 966 |
Google is your friend.
http://www.esw-heim.tu-clausthal.de/~marco/smorbrod/acme/
http://www.cbmhardware.de/c64/acme.php?Lang=E
|
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote: Google is your friend.
http://www.esw-heim.tu-clausthal.de/~marco/smorbrod/acme/
http://www.cbmhardware.de/c64/acme.php?Lang=E
this is only for win 32 not xp
sorry i am a litle bit lame =(
i am trying to learn. |
| |
JackAsser
Registered: Jun 2002 Posts: |
Quote: this is only for win 32 not xp
sorry i am a litle bit lame =(
i am trying to learn.
uhm... windows xp IS win32. If you're running xp 64-bit then it can run win32-binaries anyway. |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
how do i install it ? =)
just get a black screen , and so it disapear |
| |
Cruzer
Registered: Dec 2001 Posts: 1048 |
Protip: Horizontal is like the horizon. Vertical is the other way.
|
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote: Protip: Horizontal is like the horizon. Vertical is the other way.
thanks ..
must say I love your work ...
has to come with something new soon =) |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote: ........
No problem, to split the screen vertically, through the use of $ d012
..................
graphic
lda # $ 60
aa cmp $ d012
bne aa
text
........
How to split the screen vertically ?
How to split the screen vertically ?
How to split the screen vertically ?
How to split the screen vertically ?
=) |
| |
Cybernator
Registered: Jun 2002 Posts: 154 |
> how do i install it ? =)
No need to install it, just type "ACME <name_of_source>" and you get a compiled prg file. Also, it works like a charm on 64-bit XP, so I see no reason why that would not be the case with 32-bit XP. |
| |
turtle Account closed
Registered: Mar 2005 Posts: 44 |
Quote: > how do i install it ? =)
No need to install it, just type "ACME <name_of_source>" and you get a compiled prg file. Also, it works like a charm on 64-bit XP, so I see no reason why that would not be the case with 32-bit XP.
eks =) ?
acme c:\pr...... hmm |
| |
Cybernator
Registered: Jun 2002 Posts: 154 |
You might want to add ACME to your PATH (this is not absolutely necessary, but it will make life easier :)). Let's say you unpacked the assembler in C:\Acme. Right click on My Computer and select Properties. Go to the advanced tab and click Environment Variables. In the "System variables" listbox, select "Path" and click Edit. Now, in Variable value, at the end of the string (make sure you don't delete anything you might have here), add ";C:\Path" (excluding the quotes).
If you already have a DOS shell opened, close it and open it again (so the changes can take effect). Now go to the directory where you source code is. Once there (assuming the source code is named Exmaple.asm) type "acme example.asm", and that's it. The resulting filename is the one you give in the !to directive (in the source code).
|