Lines Matching +full:rom +full:- +full:14 +full:h
2 #------------------------------------------------------------------------------
7 # ines: file(1) magic for Marat's iNES Nintendo Entertainment System ROM dump format
10 # - https://wiki.nesdev.com/w/index.php/INES
11 # - https://wiki.nesdev.com/w/index.php/NES_2.0
14 0 name nes-rom-image-ines
18 >6 byte&0x08 =0x8 [4-Scr]
19 >6 byte&0x09 =0x0 [H-mirror]
20 >6 byte&0x09 =0x1 [V-mirror]
29 >>>13 byte&0x0F =0x2 \b, RP2C04-0001
30 >>>13 byte&0x0F =0x3 \b, RP2C04-0002
31 >>>13 byte&0x0F =0x4 \b, RP2C04-0003
32 >>>13 byte&0x0F =0x5 \b, RP2C04-0004
35 >>>13 byte&0x0F =0x8 \b, RP2C05-01
36 >>>13 byte&0x0F =0x9 \b, RP2C05-02
37 >>>13 byte&0x0F =0xA \b, RP2C05-03
38 >>>13 byte&0x0F =0xB \b, RP2C05-04
39 >>>13 byte&0x0F =0xC \b, RP2C05-05
42 # NES 2.0-specific flags.
48 # Standard iNES ROM header.
49 0 string NES\x1A NES ROM image (iNES)
50 !:mime application/x-nes-rom
51 >0 use nes-rom-image-ines
53 # Wii U Virtual Console iNES ROM header.
54 0 belong 0x4E455300 NES ROM image (Wii U Virtual Console)
55 !:mime application/x-nes-rom
56 >0 use nes-rom-image-ines
58 #------------------------------------------------------------------------------
59 # unif: file(1) magic for UNIF-format Nintendo Entertainment System ROM images
67 >4 lelong <16 NES ROM image (UNIF v%d format)
68 !:mime application/x-nes-rom
70 #------------------------------------------------------------------------------
77 0 name nintendo-fds-disk-info-block
78 >23 byte !1 FMC-
79 >23 byte 1 FSC-
86 >0x11 string *NINTENDO-HVC* Famicom Disk System disk image:
87 !:mime application/x-fds-disk
88 >>0x10 use nintendo-fds-disk-info-block
93 1 string *NINTENDO-HVC* Famicom Disk System disk image:
94 !:mime application/x-fds-disk
95 >0 use nintendo-fds-disk-info-block
97 #------------------------------------------------------------------------------
98 # tnes: file(1) magic for TNES-format Nintendo Entertainment System ROM images
102 0 string TNES NES ROM image (Nintendo 3DS Virtual Console)
103 !:mime application/x-nes-rom
105 >>0x2010 use nintendo-fds-disk-info-block
110 >>8 byte&0x09 =1 [H-mirror]
111 >>8 byte&0x09 =2 [V-mirror]
114 #------------------------------------------------------------------------------
115 # gameboy: file(1) magic for the Nintendo (Color) Gameboy raw ROM format
120 0 name gameboy-title
129 0 name gameboy-machine-type
142 0 name gameboy-mapper
143 >0 byte 0x00 [ROM ONLY]
149 >0 byte 0x08 [ROM+RAM]
150 >0 byte 0x09 [ROM+RAM+BATTERY]
167 >0 byte 0xFE [Hudson HuC-3]
168 >0 byte 0xFF [Hudson HuC-1]
170 # ROM size
171 0 name gameboy-rom-size
172 >0 byte 0 \b, ROM: 256Kbit
173 >0 byte 1 \b, ROM: 512Kbit
174 >0 byte 2 \b, ROM: 1Mbit
175 >0 byte 3 \b, ROM: 2Mbit
176 >0 byte 4 \b, ROM: 4Mbit
177 >0 byte 5 \b, ROM: 8Mbit
178 >0 byte 6 \b, ROM: 16Mbit
179 >0 byte 7 \b, ROM: 32Mbit
180 >0 byte 0x52 \b, ROM: 9Mbit
181 >0 byte 0x53 \b, ROM: 10Mbit
182 >0 byte 0x54 \b, ROM: 12Mbit
185 0 name gameboy-ram-size
194 >0x143 byte&0x80 0x80 Game Boy Color ROM image
195 !:mime application/x-gameboy-color-rom
196 >0x143 byte&0x80 !0x80 Game Boy ROM image
197 !:mime application/x-gameboy-rom
198 >0 use gameboy-title
199 >0 use gameboy-machine-type
200 >0x147 use gameboy-mapper
201 >0x148 use gameboy-rom-size
202 >0x149 use gameboy-ram-size
206 >0 byte x Analogue Pocket ROM image
207 !:mime application/x-analogue-pocket-rom
208 >0 use gameboy-title
209 >0 use gameboy-machine-type
210 >0x147 use gameboy-mapper
211 >0x148 use gameboy-rom-size
212 >0x149 use gameboy-ram-size
214 #------------------------------------------------------------------------------
215 # genesis: file(1) magic for various Sega Mega Drive / Genesis ROM image and disc formats
218 # - https://www.retrodev.com/segacd.html
219 # - http://devster.monkeeh.com/sega/32xguide1.txt
224 0 name sega-mega-drive-header
225 # ROM title. (Use domestic if present; if not, use international.)
231 >0x180 string >\0 (%.14s
238 # Sega Mega CD disc images: 2048-byte sectors.
240 !:mime application/x-sega-cd-rom
241 >0 use sega-mega-drive-header
242 >0 byte x \b, 2048-byte sectors
244 !:mime application/x-sega-cd-rom
245 >0 use sega-mega-drive-header
246 >0 byte x \b, 2048-byte sectors
247 # Sega Mega CD disc images: 2352-byte sectors.
249 !:mime application/x-sega-cd-rom
250 >0x10 use sega-mega-drive-header
251 >0 byte x \b, 2352-byte sectors
253 !:mime application/x-sega-cd-rom
254 >0x10 use sega-mega-drive-header
255 >0 byte x \b, 2352-byte sectors
259 >0x3C0 string MARS\040CHECK\040MODE Sega 32X ROM image
260 !:mime application/x-genesis-32x-rom
261 >>0 use sega-mega-drive-header
262 >0x104 string \040PICO Sega Pico ROM image
263 !:mime application/x-sega-pico-rom
264 >>0 use sega-mega-drive-header
265 >0x104 string TOYS\040PICO Sega Pico ROM image
266 !:mime application/x-sega-pico-rom
267 >>0 use sega-mega-drive-header
268 >0x104 string \040TOYS\040PICO Sega Pico ROM image
269 !:mime application/x-sega-pico-rom
270 >>0 use sega-mega-drive-header
271 >0x104 string \040IAC Sega Pico ROM image
272 !:mime application/x-sega-pico-rom
273 >>0 use sega-mega-drive-header
274 >0x104 string \040TERA68K Sega Teradrive (68K) ROM image
275 !:mime application/x-sega-teradrive-rom
276 >>0 use sega-mega-drive-header
277 >0x104 string \040TERA286 Sega Teradrive (286) ROM image
278 !:mime application/x-sega-teradrive-rom
279 >>0 use sega-mega-drive-header
280 >0x180 string BR Sega Mega CD Boot ROM image
281 !:mime application/x-genesis-rom
282 >>0 use sega-mega-drive-header
283 >0x104 default x Sega Mega Drive / Genesis ROM image
284 !:mime application/x-genesis-rom
285 >>0 use sega-mega-drive-header
288 0x100 string \040SEGA Sega Mega Drive / Genesis ROM image
289 >0 use sega-mega-drive-header
292 0x100 string SAMSUNG\040PICO Samsung Pico ROM image
293 !:mime application/x-sega-pico-rom
294 >0 use sega-mega-drive-header
295 0x100 string IMA\040IKUNOUJYUKU Samsung Pico ROM image
296 !:mime application/x-sega-pico-rom
297 >0 use sega-mega-drive-header
298 0x100 string IMA\040IKUNOJYUKU Samsung Pico ROM image
299 !:mime application/x-sega-pico-rom
300 >0 use sega-mega-drive-header
304 >0x3C0 string PICTURE\040MAGIC-01 Sega 32X ROM image
305 !:mime application/x-genesis-32x-rom
306 >>0 use sega-mega-drive-header
308 #------------------------------------------------------------------------------
309 # genesis: file(1) magic for the Super MegaDrive ROM dump format
314 0 name sega-genesis-smd-header
317 >2 byte >0 \b, split ROM
321 >8 beshort 0xAABB Sega Mega Drive / Genesis ROM image (SMD format):
322 !:mime application/x-genesis-rom
323 >>0 use sega-genesis-smd-header
327 >8 beshort 0xAABB Sega Mega Drive / Genesis ROM image (SMD format):
328 !:mime application/x-genesis-rom
329 >>0 use sega-genesis-smd-header
331 #------------------------------------------------------------------------------
332 # smsgg: file(1) magic for Sega Master System and Game Gear ROM images
333 # Detects all Game Gear and export Sega Master System ROM images,
334 # and some Japanese Sega Master System ROM images.
340 # The SMS boot ROM checks the header at three locations.
341 0 name sega-master-system-rom-header
344 !:mime application/x-sms-rom
346 !:mime application/x-sms-rom
348 !:mime application/x-gamegear-rom
350 !:mime application/x-gamegear-rom
352 !:mime application/x-gamegear-rom
354 !:mime application/x-sms-rom
355 >0 byte x ROM image:
370 >0x0E ubyte&0xF0 0xE0 14
379 # ROM size. (Used for the boot ROM checksum routine.)
392 >0x7FF0 use sega-master-system-rom-header
394 >0x3FF0 use sega-master-system-rom-header
396 >0x1FF0 use sega-master-system-rom-header
398 #------------------------------------------------------------------------------
406 0 name sega-saturn-disc-header
412 # 2048-byte sector version.
414 !:mime application/x-saturn-rom
415 >0 use sega-saturn-disc-header
416 >0 byte x (2048-byte sectors)
417 # 2352-byte sector version.
419 !:mime application/x-saturn-rom
420 >0x10 use sega-saturn-disc-header
421 >0 byte x (2352-byte sectors)
423 #------------------------------------------------------------------------------
432 0 name sega-dreamcast-disc-header
438 # 2048-byte sector version.
440 !:mime application/x-dc-rom
441 >0 use sega-dreamcast-disc-header
442 >0 byte x (2048-byte sectors)
443 # 2352-byte sector version.
445 !:mime application/x-dc-rom
446 >0x10 use sega-dreamcast-disc-header
447 >0 byte x (2352-byte sectors)
449 #------------------------------------------------------------------------------
455 #------------------------------------------------------------------------------
456 # z64: file(1) magic for the Z64 format N64 ROM dumps
457 # Reference: http://forum.pj64-emu.com/showthread.php?t=2239
460 0 bequad 0x803712400000000F Nintendo 64 ROM image
461 !:mime application/x-n64-rom
466 #------------------------------------------------------------------------------
467 # v64: file(1) magic for the V64 format N64 ROM dumps
468 # Same as z64 format, but with 16-bit byteswapping.
470 0 bequad 0x3780401200000F00 Nintendo 64 ROM image (V64)
471 !:mime application/x-n64-rom
473 #------------------------------------------------------------------------------
474 # n64-swap2: file(1) magic for the swap2 format N64 ROM dumps
475 # Same as z64 format, but with swapped 16-bit words.
477 0 bequad 0x12408037000F0000 Nintendo 64 ROM image (wordswapped)
478 !:mime application/x-n64-rom
480 #------------------------------------------------------------------------------
481 # n64-le32: file(1) magic for the 32-bit byteswapped format N64 ROM dumps
482 # Same as z64 format, but with 32-bit byteswapping.
484 0 bequad 0x401237800F000000 Nintendo 64 ROM image (32-bit byteswapped)
485 !:mime application/x-n64-rom
487 #------------------------------------------------------------------------------
488 # gba: file(1) magic for the Nintendo Game Boy Advance raw ROM format
494 4 bequad 0x24FFAE51699AA221 Game Boy Advance ROM image
495 !:mime application/x-gba-rom
500 #------------------------------------------------------------------------------
501 # nds: file(1) magic for the Nintendo DS(i) raw ROM format
507 0xC0 bequad 0x24FFAE51699AA221 Nintendo DS ROM image
508 !:mime application/x-nintendo-ds-rom
522 >>>>0x1000 lequad !0x0000000000000000 (mask ROM)
524 #------------------------------------------------------------------------------
525 # nds_passme: file(1) magic for Nintendo DS ROM images for GBA cartridge boot.
528 0xC0 bequad 0xC8604FE201708FE2 Nintendo DS Slot-2 ROM image (PassMe)
529 !:mime application/x-nintendo-ds-rom
531 #------------------------------------------------------------------------------
532 # ngp: file(1) magic for the Neo Geo Pocket (Color) raw ROM format.
535 # - https://neogpc.googlecode.com/svn-history/r10/trunk/src/core/neogpc.cpp
536 # - https://www.devrs.com/ngp/files/ngpctech.txt
539 !:mime application/x-neo-geo-pocket-rom
541 >0 byte x ROM image
546 #------------------------------------------------------------------------------
548 # Too simple - MPi
551 #------------------------------------------------------------------------------
553 0 string PS-X\040EXE Sony Playstation executable
586 #------------------------------------------------------------------------------
589 !:mime audio/x-xbox-executable
593 >>(0x0118.l-0x0FFF4) lestring16 x \b: "%.40s"
594 >>(0x0118.l-0x0FFF5) byte x (%c
595 >>(0x0118.l-0x0FFF6) byte x \b%c-
596 >>(0x0118.l-0x0FFF8) uleshort x \b%03u)
597 >>(0x0118.l-0x0FF60) ulelong&0x80000007 0x80000007 \b, all regions
598 >>(0x0118.l-0x0FF60) ulelong&0x80000007 !0x80000007
599 >>>(0x0118.l-0x0FF60) ulelong >0 (regions:
600 >>>>(0x0118.l-0x0FF60) ulelong &0x00000001 NA
601 >>>>(0x0118.l-0x0FF60) ulelong &0x00000002 Japan
602 >>>>(0x0118.l-0x0FF60) ulelong &0x00000004 Rest_of_World
603 >>>>(0x0118.l-0x0FF60) ulelong &0x80000000 Manufacturer
604 >>>(0x0118.l-0x0FF60) ulelong >0 \b)
613 # --------------------------------
618 #------------------------------------------------------------------------------
622 # - https://free60project.github.io/wiki/XEX.html
623 # - https://github.com/xenia-project/xenia/blob/HEAD/src/xenia/kernel/util/xex2_info.h
626 0 name xbox-360-xex-execution-id
629 >(0.L+0xE) beshort x \b-%04u, media ID:
633 0 name xbox-360-xex-region-code
648 !:mime audio/x-xbox360-executable
651 >>&0 use xbox-360-xex-execution-id
652 >(0x010.L+0x178) use xbox-360-xex-region-code
655 !:mime audio/x-xbox360-executable
658 >>&0 use xbox-360-xex-execution-id
659 >(0x010.L+0x154) use xbox-360-xex-region-code
661 #------------------------------------------------------------------------------
665 # - https://free60project.github.io/wiki/STFS.html
666 # - https://github.com/xenia-project/xenia/blob/HEAD/src/xenia/kernel/util/xex2_info.h
668 # TODO: More information for console-signed packages.
670 0 name xbox-360-package
673 >0x362 beshort x \b-%04u, media ID:
707 0 string CON\x20 Microsoft Xbox 360 package (console-signed)
708 >0 use xbox-360-package
710 >0 belong 0 Microsoft Xbox 360 package (non-Xbox Live)
711 >>0 use xbox-360-package
714 >>0 use xbox-360-package
720 # Double-check that the image type matches too, 0x8008 conflicts with
721 # 8 character OMF-86 object file headers.
724 !:mime application/x-atari-lynx-rom
728 # Note: called "Atari Lynx ROM" by TrID
730 !:mime application/x-atari-lynx-rom
757 # "Gameboy GBS rom image" by X11 Gameboy sound player xgbsplay and
763 # skip Grand Theft Auto 2 Style data (*.sty via sty-gta2.trid.xml) and Opera (*.patch) by check for…
765 !:mime audio/x-nintendo-gbs
770 # fields are right null-filled; no terminating \0 if all bytes are used; if field unknown, should b…
780 # number of songs (1-255)
786 # load address (400h-7fffh)
788 # init address (400h-7fffh)
790 # play address (400-7fffh)
795 >14 ubyte !0 \b, timer modulo %#x
806 # BPS Patch Files - from: David Korth <gerbilsoft@gerbilsoft.com>
811 # APS Patch Files - from: David Korth <gerbilsoft@gerbilsoft.com>
812 # Reference: https://github.com/btimofeev/UniPatcher/wiki/APS-(N64)
816 >5 byte 1 \b, N64-specific patch for
821 # FIXME: /T specifier isn't working with a fixed-length string.
824 # UPS Patch Files - from: David Korth <gerbilsoft@gerbilsoft.com>
858 # Match CISO version 1 with ISO-9660 sector size
861 !:mime application/x-compressed-iso
869 !:mime application/x-compressed-iso
877 # - 0x04 == 0x00200000: GameCube/Wii CISO (block_size)
878 # - 0x10 == 0x00000800: PSP CISO (ISO-9660 sector size)
879 # - None of the above: Compact ISO.
883 !:mime application/x-wii-rom
884 >>>>0x8000 use nintendo-gcn-disc-common
886 !:mime application/x-wii-rom
887 >>>>0x8000 use nintendo-gcn-disc-common
889 # Reference: https://pismotec.com/ciso/ciso.h
892 # - GameCube/Wii CISO: https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/DiscIO/CISOBl…
893 # - PSP CISO: https://github.com/jamie/ciso/blob/master/ciso.h
895 # - 0x04 == 0x00200000: GameCube/Wii CISO (block_size)
896 # - 0x10 == 0x00000800: PSP CISO (ISO-9660 sector size)
897 # - 0x10 == 0x00004000: For >2GB files using maxcso...
899 # - None of the above: Compact ISO.
955 >>0x17 byte &0x40 \b, ROM:
956 >>>(0x18.l-26) lelong x CRC32 %#08x
957 >>>(0x18.l-23) string x "%s"
964 #------------------------------------------------------------------------------
971 0 name nintendo-gcn-disc-common
988 !:mime application/x-gamecube-rom
989 >0 use nintendo-gcn-disc-common
998 !:mime application/x-gamecube-rom
999 >>>(8.L) use nintendo-gcn-disc-common
1005 >0 use nintendo-gcn-disc-common
1012 !:mime application/x-wii-rom
1013 >>0x200 use nintendo-gcn-disc-common
1020 !:mime application/x-gamecube-rom
1022 !:mime application/x-wii-rom
1030 !:mime application/x-gamecube-rom
1031 >>>0x38 use nintendo-gcn-disc-common
1033 !:mime application/x-wii-rom
1034 >>>0x38 use nintendo-gcn-disc-common
1038 !:mime application/x-gamecube-rom
1039 >>>(12.L) use nintendo-gcn-disc-common
1041 !:mime application/x-wii-rom
1042 >>>(12.L) use nintendo-gcn-disc-common
1047 !:mime application/x-gamecube-rom
1049 !:mime application/x-wii-rom
1052 >>0x58 use nintendo-gcn-disc-common
1061 !:mime application/x-wii-rom
1062 >>>>0x8000 use nintendo-gcn-disc-common
1064 !:mime application/x-gamecube-rom
1065 >>>>0x8000 use nintendo-gcn-disc-common
1070 !:mime application/x-gamecube-rom
1072 !:mime application/x-wii-rom
1075 >>0x58 use nintendo-gcn-disc-common
1077 #------------------------------------------------------------------------------
1100 # - 6-bit: Major
1101 # - 6-bit: Minor
1102 # - 4-bit: Revision
1103 # NOTE: Only supporting major/minor versions from 0-15 right now.
1105 0 name nintendo-3ds-version-code
1123 >0 leshort&0xFC00 0x3800 14
1140 >0 leshort&0x03F0 0x00E0 \b.14
1153 >>0x10E use nintendo-3ds-version-code
1157 >>0x10E use nintendo-3ds-version-code
1162 >>>0x112 use nintendo-3ds-version-code
1190 #------------------------------------------------------------------------------
1191 # a7800: file(1) magic for the Atari 7800 raw ROM format.
1193 # Reference: https://sites.google.com/site/atari7800wiki/a78-header
1197 >>1 string ATARI7800 Atari 7800 ROM image
1198 !:mime application/x-atari-7800-rom
1205 #------------------------------------------------------------------------------
1206 # vectrex: file(1) magic for the GCE Vectrex raw ROM format.
1214 0 string g\040GCE Vectrex ROM image
1217 #------------------------------------------------------------------------------
1228 >>>>>>>0x54 belong x Nintendo amiibo NFC dump - amiibo ID: %08X-
1231 #------------------------------------------------------------------------------
1243 #------------------------------------------------------------------------------
1249 #------------------------------------------------------------------------------
1256 #------------------------------------------------------------------------------
1260 # - https://github.com/GerbilSoft/rom-properties/issues/92
1261 # - https://github.com/CaitSith2/BadgeArcadeTool
1262 # - https://github.com/TheMachinumps/Advanced-badge-editor
1281 >>0xA4 ulelong x \b-%08X
1289 #------------------------------------------------------------------------------
1290 # sufami: file(1) magic for Sufami Turbo ROM images.
1293 # - https://problemkaputt.de/fullsnes.htm#snescartsufamiturbominicartridgeadaptor
1294 0 string BANDAI\040SFC-ADX
1295 >0x10 string !SFC-ADX\040BACKUP Sufami Turbo ROM image:
1296 >>0x10 string/T x "%.14s"
1306 #------------------------------------------------------------------------------
1307 # Type: Super NES ROM image
1310 0 name snes-rom-hdr
1312 >0 ubyte-0x20 <0xC0
1313 >>1 ubyte-0x20 <0xC0
1314 >>>2 ubyte-0x20 <0xC0
1315 >>>>3 ubyte-0x20 <0xC0
1316 >>>>>4 ubyte-0x20 <0xC0
1317 >>>>>>5 ubyte-0x20 <0xC0
1318 >>>>>>>6 ubyte-0x20 <0xC0
1319 >>>>>>>>7 ubyte-0x20 <0xC0
1320 >>>>>>>>>8 ubyte-0x20 <0xC0
1321 >>>>>>>>>>9 ubyte-0x20 <0xC0
1322 >>>>>>>>>>>10 ubyte-0x20 <0xC0
1323 >>>>>>>>>>>>21 ubyte-0x20 <0xC0 Super NES ROM image
1336 >>>>>>>>>>>>>23 byte 8 \b, ROM size: 256KB
1337 >>>>>>>>>>>>>23 byte 9 \b, ROM size: 512KB
1338 >>>>>>>>>>>>>23 byte 10 \b, ROM size: 1024KB
1339 >>>>>>>>>>>>>23 byte 11 \b, ROM size: 2048KB
1340 >>>>>>>>>>>>>23 byte 12 \b, ROM size: 4096KB
1351 # ROM is <=4096KB, RAM is <=64KB and country<=10
1355 >>>>32704 use snes-rom-hdr
1359 # ROM is <=4096KB, RAM is <=64KB and country<=10
1363 >>>>65472 use snes-rom-hdr
1365 #------------------------------------------------------------------------------
1369 # - https://wiiubrew.org/wiki/Ancast_image