spectrum 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #------------------------------------------------------------------------------
  2. # spectrum: file(1) magic for Spectrum emulator files.
  3. #
  4. # John Elliott <jce@seasip.demon.co.uk>
  5. #
  6. # Spectrum +3DOS header
  7. #
  8. 0 string PLUS3DOS\032 Spectrum +3 data
  9. >15 byte 0 - BASIC program
  10. >15 byte 1 - number array
  11. >15 byte 2 - character array
  12. >15 byte 3 - memory block
  13. >>16 belong 0x001B0040 (screen)
  14. >15 byte 4 - Tasword document
  15. >15 string TAPEFILE - ZXT tapefile
  16. #
  17. # Tape file. This assumes the .TAP starts with a Spectrum-format header,
  18. # which nearly all will.
  19. #
  20. 0 string \023\000\000 Spectrum .TAP data
  21. >4 string x "%-10.10s"
  22. >3 byte 0 - BASIC program
  23. >3 byte 1 - number array
  24. >3 byte 2 - character array
  25. >3 byte 3 - memory block
  26. >>14 belong 0x001B0040 (screen)
  27. # The following three blocks are from pak21-spectrum@srcf.ucam.org
  28. # TZX tape images
  29. 0 string ZXTape!\x1a Spectrum .TZX data
  30. >8 byte x version %d
  31. >9 byte x \b.%d
  32. # RZX input recording files
  33. 0 string RZX! Spectrum .RZX data
  34. >4 byte x version %d
  35. >5 byte x \b.%d
  36. # Floppy disk images
  37. 0 string MV\ -\ CPCEMU\ Disk-Fil Amstrad/Spectrum .DSK data
  38. 0 string MV\ -\ CPC\ format\ Dis Amstrad/Spectrum DU54 .DSK data
  39. 0 string EXTENDED\ CPC\ DSK\ Fil Amstrad/Spectrum Extended .DSK data
  40. 0 string SINCLAIR Spectrum .SCL Betadisk image
  41. # Hard disk images
  42. 0 string RS-IDE\x1a Spectrum .HDF hard disk image
  43. >7 byte x \b, version 0x%02x