"? 4 MOD 0" bug ?

Page 1/2
| 2

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 10:00

Go to basic, any MSX. Type

? 4 mod 0

What is going on here ? Didn't expect this...maybe it thinks it does not worh living after a division by zero. But before 4 this does not happen...

!login ou Inscrivez-vous pour poster

Par wolf_

Ambassador_ (10135)

Portrait de wolf_

17-04-2023, 10:05

Nothing special happening with webmsx ... unless a Division by zero is considered special.

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 10:20

i was happening in mess and openmsx i don't know if is my computer here...

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 10:25

It seems to happen on the CX5MII-128:
Sometimes you need to use

? 5mod0

This computer has a special BIOS for the 9938

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 10:30

this

Par theNestruo

Champion (430)

Portrait de theNestruo

17-04-2023, 11:10

That's the expected output.
MOD = modulus = remainder of the integer division. And you cannot divide by zero.

Par NYYRIKKI

Enlighted (6094)

Portrait de NYYRIKKI

17-04-2023, 15:05

I think I know what is going on here... Windows embedded calculator nowadays seems to return value X if you calculate X MOD 0... It does not make it right answer though. (= I think MSX gives better answer)

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 17:38

it keeps repeating a key over and over in this case d. Start openmsx with Yamaha CX5MII-128
type ? 4 mod 0
if nothing happens try again

It will repeat a sequence of characters like the print on top. Of course I know division by zero is illegal but there seems to be a bug in this msx rom. I know if has been modified to support the v9938.

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 17:40

again:

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 17:42

i have a real cx5m-ii but i modified it. probably the bug won't happen there.

Par retrocanada76

Hero (575)

Portrait de retrocanada76

17-04-2023, 17:44

it does not seem to happen on CX5MII, only the CX5MII/128. Maybe I have corrupted ROMS? I can reproduce in openMSX and Mess

Page 1/2
| 2