6128 ł 464 ł Size ł Comments on the memory locations
ÄÄÄÄÄÄĹÄÄÄÄÄÄÄĹÄÄÄÄÄÄĹÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
&B7D4 ł &B1D9 ł 1+16 ł Border and Pens' First Inks (as hardware numbers):
ł ł ł
&B7D4 ł &B1D9 ł 1 ł hw &04 = sw 1 (blue) border
&B7D5 ł &B1DA ł 1 ł hw &04 = sw 1 (blue) pen 0
&B7D6 ł &B1DB ł 1 ł hw &0A = sw 24 (bright yellow) pen 1
&B7D7 ł &B1DC ł 1 ł hw &13 = sw 20 (bright cyan) pen 2
&B7D8 ł &B1DD ł 1 ł hw &0C = sw 6 (bright red) pen 3
&B7D9 ł &B1DE ł 1 ł hw &0B = sw 26 (bright white) pen 4
&B7DA ł &B1DF ł 1 ł hw &14 = sw 0 (black) pen 5
&B7DB ł &B1E0 ł 1 ł hw &15 = sw 2 (bright blue) pen 6
&B7DC ł &B1E1 ł 1 ł hw &0D = sw 8 (bright magenta) pen 7
&B7DD ł &B1E2 ł 1 ł hw &06 = sw 10 (cyan) pen 8
&B7DE ł &B1E3 ł 1 ł hw &1E = sw 12 (yellow) pen 9
&B7DF ł &B1E4 ł 1 ł hw &1F = sw 14 (pale blue) pen 10
&B7E0 ł &B1E5 ł 1 ł hw &07 = sw 16 (pink) pen 11
&B7E1 ł &B1E6 ł 1 ł hw &12 = sw 18 (bright green) pen 12
&B7E2 ł &B1E7 ł 1 ł hw &19 = sw 22 (pale green) pen 13
&B7E3 ł &B1E8 ł 1 ł hw &04 = sw 1 (blue) pen 14
&B7E4 ł &B1E9 ł 1 ł hw &17 = sw 11 (sky blue) pen 15
ÄÄÄÄÄÄĹÄÄÄÄÄÄÄĹÄÄÄÄÄÄĹÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
&B7E5 ł &B1EA ł 1+16 ł Border and Pens' Second Inks (as hardware numbers):
ł ł ł
&B7E5 ł &B1EA ł 1 ł hw &04 = sw 1 (blue) border
&B7E6 ł &B1EB ł 1 ł hw &04 = sw 1 (blue) pen 0
&B7E7 ł &B1EC ł 1 ł hw &0A = sw 24 (bright yellow) pen 1
&B7E8 ł &B1ED ł 1 ł hw &13 = sw 20 (bright cyan) pen 2
&B7E9 ł &B1EE ł 1 ł hw &0C = sw 6 (bright red) pen 3
&B7EA ł &B1FF ł 1 ł hw &0B = sw 26 (bright white) pen 4
&B7EB ł &B1F0 ł 1 ł hw &14 = sw 0 (black) pen 5
&B7EC ł &B1F1 ł 1 ł hw &15 = sw 2 (bright blue) pen 6
&B7ED ł &B1F2 ł 1 ł hw &0D = sw 8 (bright magenta) pen 7
&B7EE ł &B1F3 ł 1 ł hw &06 = sw 10 (cyan) pen 8
&B7EF ł &B1F4 ł 1 ł hw &1E = sw 12 (yellow) pen 9
&B7F0 ł &B1F5 ł 1 ł hw &1F = sw 14 (pale blue) pen 10
&B7F1 ł &B1F6 ł 1 ł hw &07 = sw 16 (pink) pen 11
&B7F2 ł &B1F7 ł 1 ł hw &12 = sw 18 (bright green) pen 12
&B7F3 ł &B1F8 ł 1 ł hw &19 = sw 22 (pale green) pen 13
&B7F4 ł &B1F9 ł 1 ł hw &04 = sw 1 (bright yellow) pen 14
&B7F5 ł &B1FA ł 1 ł hw &17 = sw 11 (pink) pen 15
Quote from: ZorrO on 00:05, 05 July 25@andymccall - I have no idea where you got the numbers for the colors you listed.
And as for the width of the text, you can use a narrow font, like this:
https://www.cpcwiki.eu/forum/programming/basic-programming-tips/msg117620/#msg117620
Quote from: andycadley on 07:47, 05 July 25You're over complicating things. Since you're using the firmware to do the drawing, you might as well let it deal with the complexity of byte encoding too.
100 &BC2C SCR INK ENCODE
Action: Converts a PEN to provide a mask which, if applied to a screen byte, will convert all of the pixels in the byte to the appropriate PEN
Entry: A contains a PEN number
Exit: A contains the encoded value of the PEN, the flags are corrupt, and all other registers are preserved
Notes: The mask returned is different in each of the screen modes
So all you need is something like:
LD A,(current_pen)
CALL SCR_INK_ENCODE
; Is this now correct?
; Set the pen
ld a, 2 ; Select Pen 2
call #BB90 ; Call TXT SET PEN
; Set the pen ink
ld a, 2 ; Use pen 2
ld b, 10 ; Set Ink 2 to be the color
ld c, b ; Copy same color to c to ensure a solid, non-flashing color
call #BC32 ; Call SCR SET INK
; Convert to code suitable for mode 0
ld a, 2 ; Use the current value of Pen 2
call #BC2C ; Call SCR INK ENCODE
; Copy the converted color code left in a to c
ld c, a ; Color of rectangle
ld hl, screen_base ; Start of screen memory
ld d, 10 ; Width of the rectangle, accounting for double width
ld e, 120 ; Height of the rectangle
call #BC47 ; Call the graphics function to draw the rectangle
Quote from: orzel on 12:24, 05 July 25I may give it a try myself, but generally I don't mind using the EPROMs as I have a UV EPROM Eraser.Quote from: Rabs on 07:41, 05 July 25There is a 28c256 to 27c256 adapter on github, see aDIPters. May be suitable as a 23256 replacement.
Thanks for the link, might give it a try. It's nicely done.
Quote from: Rabs on 07:41, 05 July 25There is a 28c256 to 27c256 adapter on github, see aDIPters. May be suitable as a 23256 replacement.So basically, "no".
Page created in 0.099 seconds with 12 queries.