News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Brunword MK4 (ROM)

Started by SyX, 15:48, 21 July 12

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

SyX

The last weekend in CPCManiaco's home, he showed me his wonderful hardware collection and between all those jewels, a little cartridge for the CPC expansion bus took my attention.

It's one of the last commercial word processor for CPC, i'm talking of Brunword. A superb nice program in rom for our CPCs, we took a look to the info in the CPCWiki and my interest increased, because this version, MK4, it was not preserved and the info about the MK2 version looked intriguing.

We have been researching it during this week and this morning we are being able to dump all the rom pages. This rom cartridge is more special than looks at first. Its size is 512KBs, the bigger CPC commercial software ever  :D , include a tutorial, examples and fonts in the ROM :D And the ROM pages are made visible in $4000-$7FFF instead in the usual $C000-$FFFF (Superinteresting!!! 8) ).

I have update the wiki page with the info related to the recovered MK4 version (manual scans and pictures will be attached in the next weeks) and i'm sure that you will enjoy it :)

TFM

That looks like RAM paging.

It should be doabel to simulate that 512 KB ROM by using a 512 KB RAM expansion, because it banks in at &4000-&7FFF too.

Or maybe this MK4 is a RAM expansion using ROMs instead of RAM?

Would be cool to get a dump and check it out.

I must admit I never heart about it, but I would have bought it!
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

SyX

Use ROM, i checked that explicitly, the RAM under $4000-$7FFF is alive and well used while the program is running  :)

The dump is in the wiki, take a look in the downloads section of the page ;)

For dumping, i paged the ROM, copy over itself in RAM (LD HL,$4000|LD DE,$4000|LD BC,$4000|LDIR), dispaged the ROM and save the copy in ram using the firmware.

And before of that, i made a little program for checking all the combinations of rom numbers and CPCManiaco took notes with the combinations that enabled rom pages of Brunword.

Bryce

I'll take a look at this when I have time and see how easy it would be to make a new device to hold this Program. I had access to one of these a while back, but it was encased in black resin too, so I couldn't take a proper look at the hardware :(

Bryce.

SyX

Yes, that is the problem and it's a shame, because Brunword and Multiface are the only hardware using a different way of paging the roms.

IanS

Quote from: SyX on 23:16, 21 July 12
And before of that, i made a little program for checking all the combinations of rom numbers and CPCManiaco took notes with the combinations that enabled rom pages of Brunword.

From the wiki ariticle:-
QuoteThe pages 1, 2 and 3 ($C1, $C2 and $C3 are the page number for the hardware) are standard CPC ROMs and they can be paged in at the normal $C000-$FFFF range.

Do you know which standard rom numbers these 3 map into? (I guess they are in the range 1-6, could be 8-15 as it was 6128 only).

For the pages mapped into $4000-&7fff does anyone have any idea if ROMDIS or RAMDIS (or both) would be required for reading the mapped rom. I'd guess it only needs RAMDIS, but I'm not sure.

SyX

Quote from: IanS on 12:07, 22 July 12Do you know which standard rom numbers these 3 map into? (I guess they are in the range 1-6, could be 8-15 as it was 6128 only).
They are mapped in rom numbers 1, 2 and 3, for that order :)

TFM

Like I understand the MK4 was released in 1995, so in that time (at least in Europe) there was no more commercial CPC related magazine, so people could not know that the MK4 was released. What a pity!
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

arnoldemu

I will extend my emulation of the mk2 to include the mk4 :)
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

arnoldemu

btw the info about the mk2 was worked out from the software alone. I don't have access to the real hardware.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

arnoldemu

#10
I see the decoding logic for the page at &4000-&7fff, to select which page it uses, but what is the exact logic for the page at &c000. What must the data bits be?

How is the port &DFxx decoded, is this defined only bit bit 13=0 or is it more complete?

if rom page at &4000-&7fff is visible, is the rom page at &c000-&ffff also visible?

Are both rom pages enabled/disabled when upper rom is enabled/disabled?

How is the lower rom page turned off? Bit 3 = 1 of the data??? or...??
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Gryzor

512k? Whoa. Is this the biggest commercial piece of software to be sold?

IanS

Quote from: arnoldemu on 13:51, 23 July 12
I see the decoding logic for the page at &4000-&7fff, to select which page it uses, but what is the exact logic for the page at &c000. What must the data bits be?

How is the port &DFxx decoded, is this defined only bit bit 13=0 or is it more complete?

if rom page at &4000-&7fff is visible, is the rom page at &c000-&ffff also visible?

Are both rom pages enabled/disabled when upper rom is enabled/disabled?

How is the lower rom page turned off? Bit 3 = 1 of the data??? or...??
&df00 is the standard upper rom selection port, so bit a13=0 should be enough.


My reading of the description is:-


The rom is 512K and is made up of 32 pages, each 16k(numbered 0-31 for any further description).


Pages 1,2 and 3 are standard roms and will appear at &c000-&ffff if 1, 2 or 3 is written to port &df00.


If the upper two bits of the value written to &df00 are 1 then the page selected by bits 5,4,3,1 & 0 (5 bit number, 32 possible values) will appear at &4000-&7fff. I would be suprised if the page also appeared at &c000-&ffff if the upper two bits are set.


The page will be de-selected from &4000-&7fff if any value without the two top bits is sent to port &df00.

SyX

Well, because the cartridge is in Madrid and i had returned from my visit, already. And of course, don't having physical access to it and not trying to take a lot of CPCManiaco time, the number of tests, that i could, do were limited, because our goal was preserve the roms. That means i'm not going to have all the answers to your questions... but it should not be too difficult to answer with more tests or simply tracing the code (the rsxs, to launch it, are in the page 1).

Quote from: arnoldemu on 13:51, 23 July 12btw the info about the mk2 was worked out from the software alone. I don't have access to the real hardware.
With respect to mk2, i have not idea. The info in the wiki was by Nocash (i think) and it looks different to the mk4.

Quote from: arnoldemu on 13:51, 23 July 12I see the decoding logic for the page at &4000-&7fff, to select which page it uses, but what is the exact logic for the page at &c000. What must the data bits be?
In my first test for seeing which roms appeared in $C000, i only checked 0-31  using KL_ROM_SELECT or $DF00 directly. And as i only got the pages 1, 2 and 3 of Brunword in $C000 (sending 1, 2 and 3), then i checked in other places of the z80 addressing space.

Quote from: arnoldemu on 13:51, 23 July 12How is the port &DFxx decoded, is this defined only bit bit 13=0 or is it more complete?
We should test that, because i used $DF00 only and the epoxy don't let you see the chips in the rom board... but it would be strange to have a full port decode when one bit is enough.

Quote from: arnoldemu on 13:51, 23 July 12if rom page at &4000-&7fff is visible, is the rom page at &c000-&ffff also visible?
I have not tested that, too. But while i have been disassembling the code, i have seen this:
LD    H,$C0
CALL  KL_CURR_SELECTION
LD    BC,$DF00
OUT   (C),H ; Enable tutorial page in $4000
OUT   (C),A ; Enable page 1 in $C000

That means two roms can be enabled simultaneously; but using the program, i had realized that.

Quote from: arnoldemu on 13:51, 23 July 12Are both rom pages enabled/disabled when upper rom is enabled/disabled?
More tests to do.

Quote from: arnoldemu on 13:51, 23 July 12How is the lower rom page turned off? Bit 3 = 1 of the data??? or...??
For disabling in the rom dump program, i simply use OUT $DF00,0 (one of the combinations that not enable any rom in $4000).

The sourcecode of the rom checker:
Quote; ---------------------------------------------------------------------------
; Brunword rom checker (c) SyX 2012
; ---------------------------------------------------------------------------

    include 'hardware.i'
    include 'firmware.i'

; ---------------------------------------------------------------------------
inicio
    ; Select ROM
    LD   IXH,0
    LD   HL,buffer_roms   
.loop_check_roms
    LD   BC,ROM_SELECT
    LD   A,IXH
    PUSH HL
    LD   L,A
    LD   DE,mensaje_rom_number
    CALL convierte_a_hex
    LD   DE,mensaje_rom_number
    LD   A,(DE)
    CALL TXT_OUTPUT
    INC  DE
    LD   A,(DE)
    CALL TXT_OUTPUT
    LD   A,32
    CALL TXT_OUTPUT
    POP  HL
    LD   A,IXH
    OUT  (C),A                      ; Enable page of Brunword ROM in $4000 - $7FFF

    CALL check_for_empty            ; HL e IXH preserved
   
    INC  IXH
    LD   A,IXH
    OR   A
    JR   NZ,.loop_check_roms

    CALL espera_tecla

    ; Mostrar Resultados
    LD   A,1
    CALL SCR_SET_MODE

.repeat_show_roms
    LD   IXH,0
    LD   HL,buffer_roms   
.loop_show_roms
    LD   A,'$'
    CALL TXT_OUTPUT
    LD   A,IXH
    PUSH HL
    LD   L,A
    LD   DE,mensaje_rom_number
    CALL convierte_a_hex
    LD   DE,mensaje_rom_number
    LD   A,(DE)
    CALL TXT_OUTPUT
    INC  DE
    LD   A,(DE)
    CALL TXT_OUTPUT
    LD   A,' '
    CALL TXT_OUTPUT
    POP  HL

    LD   B,36
.loop_print_line
    LD   A,1
    CALL TXT_OUTPUT
    LD   A,(HL)
    CALL TXT_OUTPUT
    INC  HL
    DJNZ .loop_print_line

    INC  IXH
    LD   A,IXH
    AND  $0F
    CALL Z,espera_tecla
    LD   A,IXH
    OR   A
    JR   NZ,.loop_show_roms

    JR   .repeat_show_roms

; ---------------------------------------------------------------------------
; PIP + Wait Key
espera_tecla
    LD   A,7
    CALL TXT_OUTPUT
.loop_keyboard_free
    CALL KM_READ_KEY
    JR   C,.loop_keyboard_free
    CALL KM_WAIT_KEY
    RET

; ---------------------------------------------------------------------------
; Check for empty
check_for_empty
    EX   DE,HL
    LD   HL,RAM_P1
    XOR  A
.loop_check_clean_rom
    OR   (HL)
    JR   NZ,.exit_loop_check_clean_rom
    INC  HL
    JR   .loop_check_clean_rom
.exit_loop_check_clean_rom
    LD   A,H
    CP   $80
    JR   NZ,.dump_first_16_bytes
.rom_was_clean
    LD   HL,mensaje_rom_limpia
    JR   .dump_to_buffer
.dump_first_16_bytes
    LD   HL,RAM_P1
    ; Dump ROM to buffer
.dump_to_buffer
    LD   BC,36
    LDIR
    EX   DE,HL
    RET

; ---------------------------------------------------------------------------
; Convierte de binario a ascii en hexadecimal una cadena de bytes (Baze)
; Entradas:
;    HL: Valor a convertir
;    DE: Puntero a la cadena
; ---------------------------------------------------------------------------
convierte_a_hex
    LD   A,L
    CALL .bin2hex1
    LD   A,L
    JR   .bin2hex2
.bin2hex1
    RRA
    RRA
    RRA
    RRA
.bin2hex2
    OR   $F0
    DAA
    ADD  A,$A0
    ADC  A,$40
    ; Guarda caracter
    LD   (DE),A
    INC  DE
    RET

; ---------------------------------------------------------------------------
mensaje_rom_limpia
    DEFB '** NO HAY ROM DEL BRUNWORD ACTIVA **'

mensaje_rom_number
    DEFB '  '

; ---------------------------------------------------------------------------
; Buffer con 16 bytes de cada rom
buffer_roms

; ---------------------------------------------------------------------------
    END
And the dumper:; ---------------------------------------------------------------------------
; Volcador de Brunword MK4 a disco (c) SyX 2012
; ---------------------------------------------------------------------------

    include 'hardware.i'
    include 'firmware.i'

; ---------------------------------------------------------------------------
inicio
    ; Mostramos el mensaje de inicio
    LD   HL,init_text
    CALL print_string

    ; Esperamos a que se pulse una tecla
    CALL wait_key

    ; Guardamos las roms detectadas
    LD   IX,lista_roms
.loop_save_roms
    LD   A,(IX + 0)
    OR   A
    JR   Z,.exit_save_roms

    AND  $0F
    JR   NZ,.sigue_volcando
    LD   HL,change_side_text
    CALL print_string
    CALL wait_key

.sigue_volcando
    ; Enable page of Brunword ROM in $4000 - $7FFF
    LD   A,(IX + 0)
    LD   BC,ROM_SELECT
    OUT  (C),A

    ; Copy the rom over the ram
    LD   HL,$4000
    LD   DE,$4000
    LD   BC,$4000
    LDIR

    ; Disable page of Brunword ROM in $4000 - $7FFF
    LD   BC,ROM_SELECT
    XOR  A
    OUT  (C),A

    ; Save ROM
    CALL save_rom2disc

    ; Next ROM
    INC  IX
    JR   .loop_save_roms

.exit_save_roms
    ; Show process finished message
    LD   HL,reset_text
    CALL print_string

    ; Esperamos a que se pulse una tecla
    CALL wait_key

    RST 0

; ---------------------------------------------------------------------------
wait_key
    LD   A,7
    CALL TXT_OUTPUT
.loop_keyboard_free
    CALL KM_READ_KEY
    JR   C,.loop_keyboard_free
    CALL KM_WAIT_KEY
    RET

; ---------------------------------------------------------------------------
save_rom2disc
    ; Update filename
    LD   DE,rom_filename.number
    LD   L,(IX + 0)
    CALL convierte_a_hex
   
    LD   DE,disc_buffer                     ; 2KBs buffer
    LD   HL,rom_filename                    ; Filename address
    LD   B,end_rom_filename - rom_filename  ; Length filename
    CALL CAS_OUT_OPEN                       ; Open file

    LD   HL,RAM_P1                          ; Data address
    LD   DE,$4000                           ; Length
    LD   BC,$0000                           ; Execution Address
    LD   A,2                                ; File type (Binary)
    CALL CAS_OUT_DIRECT                     ; Read file

    JP   CAS_OUT_CLOSE                      ; Close file
   
; ---------------------------------------------------------------------------
; Print_String Num_bytes,String
print_string
    LD   B,(HL)
    INC  HL
.loop_print_text
    LD   A,(HL)
    CALL TXT_OUTPUT
    INC  HL
    DJNZ .loop_print_text
    RET

; ---------------------------------------------------------------------------
; Convierte de binario a ascii en hexadecimal una cadena de bytes (Baze)
; Entradas:
;    HL: Valor a convertir
;    DE: Puntero a la cadena
; ---------------------------------------------------------------------------
convierte_a_hex
    LD   A,L
    CALL .bin2hex1
    LD   A,L
    JR   .bin2hex2
.bin2hex1
    RRA
    RRA
    RRA
    RRA
.bin2hex2
    OR   $F0
    DAA
    ADD  A,$A0
    ADC  A,$40
    ; Guarda caracter
    LD   (DE),A
    INC  DE
    RET

; ---------------------------------------------------------------------------
init_text
    DEFB end_init_text - $ - 1
    DEFB ' Para volcar Brunword usaremos discos   '
    DEFB ' con al menos 136 KBs libres por cara.',10,13,10,13
end_init_text

reset_text
    DEFB end_reset_text - $ - 1
    DEFB ' Proceso finalizado.',10,13,10,13
    DEFB ' Pulse una tecla para reiniciar su CPC.'
end_reset_text

change_side_text
    DEFB end_change_side_text - $ - 1
    DEFB 'Se va a pasar un grupo de 8 roms, ponga '
    DEFB 'una cara libre del disco y presione una '
    DEFB 'tecla para continuar con el volcado.',10,13,10,13
end_change_side_text

; ---------------------------------------------------------------------------
;rom_number
;    DEFW 0

; Lista de roms
lista_roms
    DEFB $C0,$C1,$C2,$C3
    DEFB $C8,$C9,$CA,$CB

    DEFB $D0,$D1,$D2,$D3
    DEFB $D8,$D9,$DA,$DB

    DEFB $E0,$E1,$E2,$E3
    DEFB $E8,$E9,$EA,$EB

    DEFB $F0,$F1,$F2,$F3
    DEFB $F8,$F9,$FA,$FB

    DEFB $00

rom_filename
    DEFB 'BRUNW-'
.number
    DEFB '00.ROM'
end_rom_filename

disc_buffer
; ---------------------------------------------------------------------------
    END

Bryce

From a hardware point of view, it must be almost a mini-ROMBoard and a RAM expansion (but using ROMs) all in one. I suspect there's a PAL IC under the epoxy, because that much decoding would usually need more ICs than can be "seen" under the epoxy. It would need to use ROMDIS to overwrite the &C000 area for ROMs 1 to 3, but it would also need to use RAMDIS for the other ROM Images, otherwise you'd have clashes within the CPC.

Bryce.

IanS

Quote from: Bryce on 09:15, 24 July 12
I suspect there's a PAL IC under the epoxy, because that much decoding would usually need more ICs than can be "seen" under the epoxy.
Is there a picture of the MK4 device? (I've seen the MK2 device on the wiki, I pressume the MK4 is similar)

It's the fact that it support multiple pages being mapped in which makes things more difficult. Exactly when the pages at &4000-&7fff get mapped out is the bit I think we still need to find out.

Might just have to try it and see.

SyX

#16
Quote from: IanS on 19:21, 24 July 12Is there a picture of the MK4 device? (I've seen the MK2 device on the wiki, I pressume the MK4 is similar)
It's practically the same, as i said pictures and manuals of the MK4 will be uploaded during the next weeks (as CPCManiaco always do).

But we never imagined, that it would have so much interest in this expansion...  Personally, i saw much more interesting CPC hardware in my visit to Madrid and i'm excluding the Aleste and the KC Compact  ;D

ivarf

Quote from: SyX on 20:15, 24 July 12
 Personally, i saw much more interesting CPC hardware in my visit to Madrid and i'm excluding the Aleste and the KC Compact


Did you see the Aleste? Did you try it? Please give us a short review :)

SyX

Yes, Aleste lives in the best room that it can get, surrounded for practically all the cpc game catalog. But his owner should be the best person to review it. At least, i can put a link to a few of pictures of this treasure.

TFM

Quote from: SyX on 20:15, 24 July 12
...  Personally, i saw much more interesting CPC hardware in my visit to Madrid ...

Tell, tell tell!!!!! Please! Did you also see the legendary famous HD64180 coprocessor card for the CPC? What's more interesting than the MK4. Tell tell tell.... :) :) :) :) :) :) :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

SyX

No, TFM, that card is the Holy Grail, although the most part of german cpc magazines are there, because that we could try to find the article with the review ;)

Well, for me is more interesting the Hard Disk from Vortex and Dobbertin, all the ram expansions (DK'Tronics, Vortex, ...), 10 differents AMX mouses, a lot more of different mouses, light guns, multifaces (we preserved 3 or 4 new rom versions, they are already in the Grim site), hackit, transtape, teletext decoder, all kind of serial ports, printer ports, speech synthesizers, midi, ... you think and they have, you can even choose the country edition (spanish, french, german or english version of the hardware), jajaja.

And better don't mention magazines and fanzines (even from Australia) or books or software, both original or copied (in 3", 5" 1/4 or 3" 1/2), there are so many floppies that it's going to take decades preserving them.

It's difficult to assimilate all those CPC resources, but the most amazing thing is every day a part of that collection is being shared in the CPCWiki, CPC-Power, ... the generosity of CPCManiaco has no limits :)

Gryzor

Quote from: SyX on 22:18, 24 July 12
(we preserved 3 or 4 new rom versions, they are already in the Grim site),  :)



Thanks, I added a link to the MF2 wiki page leading to Grimware... can I add the ROMs to it?

SyX

Of course :) ... i forgot to upload here ;)

Gryzor


arnoldemu

#24
I did some testing of the Brunword Mk2 that Terje sent me.
I have updated the wiki with my results so far.

I have a few more to do before I can send the hardware back.

EDIT: One final test to do now.
EDIT: Final test done.

I'll dump the ROM itself next.

BTW, The "version" number that shows (e.g. RW383... perhaps this is actually a digital signature for the person who bought it - this is speculation btw).
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Powered by SMFPacks Menu Editor Mod