I finally learned what poke -1,170 does

Страница 1/2
| 2

By janvv

Resident (41)

Аватар пользователя janvv

25-09-2017, 07:23

For 30 years this used to be 'one of those magic things that you do'.

But I have been learning about subslots, and today I realized that poke -1,170 is to change the subslot to make sure RAM will be mapped into 0000-7fff. This also explains why it's different on Turbo-R... the RAM is in a different subslot.

That is all Smile

Для того, чтобы оставить комментарий, необходимо регистрация или !login

By TheKid

Paladin (826)

Аватар пользователя TheKid

25-09-2017, 08:31

and what is the equavalent for poke -1,170 on a turbo R ?

By ro

Guardian (4122)

Аватар пользователя ro

25-09-2017, 08:50

wasn't that poke -1,&HAA ?

By Grauw

Ascended (8507)

Аватар пользователя Grauw

25-09-2017, 09:37

https://www.faq.msxnet.org/miscfaq.html

Quote:

How can I let most of the MSX1 software work on MSX2 machines/what is the universal slot-select-correct POKE?
The universal poke to do this is:
POKE -1,1.0625*(NOT(PEEK(-1))AND&HF0)
The same POKE, but a bit shorter:
POKE -1,(15-PEEK(-1)\16)*17

Harder to remember, but works on every machine :D.

(Replace "poke -1," with "print" to see the exact number.)

By Meits

Scribe (5635)

Аватар пользователя Meits

25-09-2017, 10:09

Grauw wrote:

Harder to remember, but works on every machine Big smile.

haha yeah. I always google it and c/p it whenever I run into a reset due to 170 Smile

By ren

Paragon (1274)

Аватар пользователя ren

25-09-2017, 15:50

Congrats, now when are you going to restore the RPGFan website? Wink

By TheKid

Paladin (826)

Аватар пользователя TheKid

25-09-2017, 16:22

cool, thanks grauw. Didn't know that one Smile

By janvv

Resident (41)

Аватар пользователя janvv

25-09-2017, 17:59

Yeah the universal poke sets page 0/1 to the same subslot as page 2/3, because we know those are RAM. Makes perfect sense!

On a Turbo R it's poke -1, 0

Ren: I'm honoured that you remember rpgfan.demon.co.uk. It's gone for good unfortunately!

By Grauw

Ascended (8507)

Аватар пользователя Grauw

25-09-2017, 18:06

Except on machines where it isn't in the same subslot Big smile.

By Feiraco

Expert (111)

Аватар пользователя Feiraco

25-09-2017, 22:23

That poke was legendary..... :-)

Wasn't there another formula with the same outcome?

By Manuel

Ascended (15804)

Аватар пользователя Manuel

25-09-2017, 22:53

janvv - you're joking right??? You programmed quite complex MSX games without knowing about subslots?? No way.

Страница 1/2
| 2