Toshiba HX-23F wiki

Page 1/3
| 2 | 3

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 09:47

This page states

Quote:

The 64kB RAM is split in half between the slots 0 and 3-0, a configuration that can cause poorly written software to crash. Also, with this layout, the POKE-1,(15-PEEK(-1)\16)*17 trick to workaround buggy softwares that don't handle subslots properly will not work on this machine.

Can the author of the personal opinion about poorly written software and buggy softwares show me the right way handling this machine to enable 64KB continuous RAM in whole CPU addressable space?

It is not that I am offended by this statement LOL! rather than my personal opinion is that machine's design is buggy rather than software expecting RAM in single slot in base configuration.

Login or register to post comments

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 10:07

Ok, I have one small idea. DOS1 is most probably considered as well written software (isn't it?), I will see how it manages RAM in machine of this type to boot MSX-DOS.

By Grauw

Ascended (8317)

Grauw's picture

11-05-2017, 10:13

You should do a RAM detection in each slot, rather than assuming the slot of the RAM in page 3 can be switched to other pages.

This is also true when e.g. I have a 16K machine and I plug in a 16K memory expansion, the RAM is not in the same slot. That’s a feature (being able to extend the RAM). It’s a case software needs to deal with. That is, for unmapped memory (the MSX1 memory architecture).

For memory mappers I think it makes little sense if the same mapper is available in different slots for different pages. Not sure if there are machines which do that, not sure either whether this machine has a memory mapper.

By the way, iirc if there is a DiskROM available I think the DiskROM does RAM detection and conveniently stores the RAM slots for each page somewhere. Maybe someone else can mention the exact addresses because I don’t know them by heart.

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 15:10

Grauw wrote:

You should do a RAM detection in each slot, rather than assuming the slot of the RAM in page 3 can be switched to other pages.

Logical, but there could be cases when writing to some area may have different effect than writing to RAM - for example, accessing FDC mapped I/O register, or GR8NET register.

Grauw wrote:

... I think the DiskROM does RAM detection

Checked, you are correct, I will reuse its sub.

By Grauw

Ascended (8317)

Grauw's picture

11-05-2017, 15:30

https://www.msx.org/wiki/System_variables,_code_%26_hooks_in...

F341 8B Slot ID of RAM in page 0 (DOS) (i.e.   3-2)
F342 8B Slot ID of RAM in page 1 (DOS)
F343 8B Slot ID of RAM in page 2 (DOS/BASIC)
F344 8B Slot ID of RAM in page 3 (DOS/BASIC)

Not sure this means that F341 / F342 are uninitialised in the Basic environment, or just not used. Of course, the DiskROM first needs to execute (possible dependency on slot order, also not sure if it initialises this in the INIT call).

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 16:13

If there's no initialized disk-ROM subsystem, these locations are undefined. I can not use them, thus I am implementing custom search routine.

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 16:28

Now application works properly in HX-23F setup. I slightly changed disk-ROM RAM search routine to be able to search in bank 2 (8000-BFFF) and check for BOTTOM to ensure base RAM is at least 16K.

By Piter Punk

Master (202)

Piter Punk's picture

11-05-2017, 17:08

Eugeny_Brychkov wrote:

Now application works properly in HX-23F setup. I slightly changed disk-ROM RAM search routine to be able to search in bank 2 (8000-BFFF) and check for BOTTOM to ensure base RAM is at least 16K.

Hi Eugeny,

Can you publish your search for RAM code? Probably it will be useful for others, there is a lot of games that made a terrible job in handling the slot/RAM layout.

Thanks!

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

11-05-2017, 17:49

The routine is located within 5E52-5EAC of the DOS1 disk-ROM.

By sd_snatcher

Prophet (3032)

sd_snatcher's picture

12-05-2017, 00:52

Quote:

rather than my personal opinion is that machine's design is buggy rather than software expecting RAM in single slot in base configuration.

There are many MSX models that feature this kind of split-RAM configuration. They're:

  • Sony HB-10P
  • Sony HB-F500P
  • Toshiba HX-22
  • Toshiba HX-23
  • Toshiba HX-23F
  • Toshiba HX-51
  • Toshiba HX-52
  • Victor HC-80
  • Yamaha YIS-503FB

It's a perfectly valid design under the MSX specs and, as Grauw already explained, nearly all MSX models that have less than 64KB of internal RAM will end up with a split-RAM configuration when an external RAM expansion is used on them. Just to name a few:

  • Yamaha CX5M and all its brothers
  • Sony HB-10 (japanese)
  • Sony HB-101
  • National CF-1200
  • National CF-2000
  • Casio PV-7 with the KB-7 dockstation
  • Casio MX-10
  • Casio MX-15
  • Casio MX-101
  • Sanyo MPC-10
  • and many others

By Eugeny_Brychkov

Paragon (1080)

Eugeny_Brychkov's picture

12-05-2017, 09:42

Thank you Grauw and sd_snatcher, I now see that such configurations are fairly possible and within standard.

Let's return to considering wording as they bugged me. Do we still think that software which can not handle such configurations is "poorly written" and "buggy"? I would say these are kind of strongly negative statements. I would write differently, that "software may not assume and thus support these configurations".

Page 1/3
| 2 | 3