nspire-z80 icon indicating copy to clipboard operation
nspire-z80 copied to clipboard

Program doesn't work

Open FerdinandoPH opened this issue 3 years ago • 11 comments

Rom works fine on wabbitemu (it's a ti 84 se rom), but I open it on this emulator and this happens: I can exit pressing esc, but that's about it. I'm using a ti nspire cx ii cas with ndless 5.3 WhatsApp Image 2022-09-13 at 20 40 06

FerdinandoPH avatar Sep 13 '22 18:09 FerdinandoPH

pinging @Vogtinator just in case

adriweb avatar Sep 13 '22 19:09 adriweb

Yeah, this looks like it's the usual HW-W-like LCD format mismatch. The issue with the CX II LCD in particular is that there's extra HW which performs rotation, so when writing to the existing framebuffer it's like a 320x240 one, but when changing to a different location it's actually 240x320... That unfortunately needs specific code to handle the is_cx2 case here.

Vogtinator avatar Sep 13 '22 21:09 Vogtinator

Is this project maintained?

FerdinandoPH avatar Sep 13 '22 21:09 FerdinandoPH

No (read the author profile bio...), a fork would be needed to update the code to use the latest SDK stuff

adriweb avatar Sep 13 '22 22:09 adriweb

There is already an is_hww clause in the lcd code that seems to rotate the framebuffer. How would an is-cx2 differ from this, and what would need to be done to implement it?

Noahmatada avatar Sep 29 '23 15:09 Noahmatada

There is already an is_hww clause in the lcd code that seems to rotate the framebuffer. How would an is-cx2 differ from this, and what would need to be done to implement it?

IIRC it's almost the same. It might have to do an X/Y flip in addition to the 240x320 conversion, but I'm not entirely sure.

You could try

	if(is_hww) {
		return x * 240 + y;
	} else if(is_cx2) {
                return (319-x) * 240 + 239 - y;
        } else {
		return y * 320 + x;
	}

Vogtinator avatar Sep 29 '23 19:09 Vogtinator