Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

header section can be unbuildable for iQue roms #220

Open
marijnvdwerf opened this issue Feb 20, 2023 · 2 comments
Open

header section can be unbuildable for iQue roms #220

marijnvdwerf opened this issue Feb 20, 2023 · 2 comments

Comments

@marijnvdwerf
Copy link
Contributor

Splat produces invalid code when extracting the header from iQue roms, which barely have any info in the header. The "internal name" contains null bytes, which then trips up as

Error

mips-linux-gnu-as -EB -march=vr4300 -mtune=vr4300 -Iinclude ver/cn/asm/header.s -o ver/cn/build/ver/cn/asm/header.s.o
ver/cn/asm/header.s: Assembler messages:
ver/cn/asm/header.s:11: Warning: missing closing `"'
ver/cn/asm/header.s:11: Error: unrecognized opcode `
.word 0x00000000
.word 0x00000000
.ascii "\0\0"'

Hexdump (Paper Mario, iQue)

00000000  80 37 12 40 00 00 00 0f  80 02 5c 00 00 00 14 4c  |.7.@......\....L|
00000010  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000020  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000030  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000040  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|

header.s

.section .data

.word 0x80371240       /* PI BSB Domain 1 register */
.word 0x0000000F       /* Clockrate setting */
.word 0x80025C00       /* Entrypoint address */
.word 0x0000144C       /* Revision */
.word 0x00000000       /* Checksum 1 */
.word 0x00000000       /* Checksum 2 */
.word 0x00000000       /* Unknown 1 */
.word 0x00000000       /* Unknown 2 */
.ascii "��������������������" /* Internal name */
.word 0x00000000       /* Unknown 3 */
.word 0x00000000       /* Cartridge */
.ascii "\0\0"          /* Cartridge ID */
.ascii "\0"            /* Country code */
.byte 0x00             /* Version */
@ethteck
Copy link
Owner

ethteck commented Apr 3, 2023

Fixed in #228

@ethteck ethteck closed this as completed Apr 3, 2023
@marijnvdwerf
Copy link
Contributor Author

Still happens as of 0c5540f. This is probably gonna require changes in segtypes/n64/header.py.

@AngheloAlf AngheloAlf reopened this Apr 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants