User Tag List

Показано с 1 по 10 из 34

Тема: Формат файла tap zx spectrum

Древовидный режим

Предыдущее сообщение Предыдущее сообщение   Следующее сообщение Следующее сообщение
  1. #1
    Activist Аватар для san010101
    Регистрация
    18.11.2015
    Адрес
    г. Красноярск
    Сообщений
    271
    Спасибо Благодарностей отдано 
    19
    Спасибо Благодарностей получено 
    2
    Поблагодарили
    2 сообщений
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    По умолчанию Формат файла tap zx spectrum

    Всем добра!
    Прошу не ругать за повтор и т.д.
    Не нашел ответов на вопросы вот и решил создать тему.

    Format Description

    The .TAP files contain blocks of tape-saved data. All blocks start with two bytes specifying how many bytes will follow (not counting the two length bytes). Then raw tape data follows, including the flag and checksum bytes. The checksum is the bitwise XOR of all bytes including the flag byte. For example, when you execute the line SAVE "ROM" CODE 0,2 this will result:

    |------ Spectrum-generated data -------| |---------|

    13 00 00 03 52 4f 4d 7x20 02 00 00 00 00 80 f1 04 00 ff f3 af a3

    ^^^^^...... first block is 19 bytes (17 bytes+flag+checksum)
    ^^... flag byte (A reg, 00 for headers, ff for data blocks)
    ^^ first byte of header, indicating a code block

    file name ..^^^^^^^^^^^^^
    header info ..............^^^^^^^^^^^^^^^^^
    checksum of header .........................^^
    length of second block ........................^^^^^
    flag byte ...........................................^^
    first two bytes of rom .................................^^^^^
    checksum (checkbittoggle would be a better name!).............^^

    Note that it is possible to join .TAP files by simply stringing them together; for example, in DOS / Windows: COPY /B FILE1.TAP + FILE2.TAP ALL.TAP ; or in Unix/Linux: cp file1.tap all.tap && cat file2.tap >> all.tap

    For completeness, I'll include the structure of a tape header. A header always consists of 17 bytes:
    Byte Length Description
    0 1 Type (0,1,2 or 3)
    1 10 Filename (padded with blanks)
    11 2 Length of data block
    13 2 Parameter 1
    15 2 Parameter 2

    The type is 0,1,2 or 3 for a Program, Number array, Character array or Code file. A SCREEN$ file is regarded as a Code file with start address 16384 and length 6912 decimal. If the file is a Program file, parameter 1 holds the autostart line number (or a number >=32768 if no LINE parameter was given) and parameter 2 holds the start of the variable area relative to the start of the program. If it's a Code file, parameter 1 holds the start of the code block when saved, and parameter 2 holds 32768. For data files finally, the byte at position 14 decimal holds the variable name.

    Вопрос по блокам
    length of second block ........................^^^^^
    flag byte ...........................................^^
    first two bytes of rom .................................^^^^^
    checksum (checkbittoggle would be a better name!).............^^

    что это за блок и откуда берутся first two bytes of rom (в каждом файле они разные)
    Нужно ли этот блок считывать.

  2. #1
    С любовью к вам, Yandex.Direct
    Размещение рекламы на форуме способствует его дальнейшему развитию

Информация о теме

Пользователи, просматривающие эту тему

Эту тему просматривают: 1 (пользователей: 0 , гостей: 1)

Похожие темы

  1. Тесты для ZX-Spectrum в tap формате
    от Ovvnex в разделе Софт
    Ответов: 30
    Последнее: 20.11.2017, 01:32
  2. THX - формат файла
    от breeze в разделе Amiga
    Ответов: 2
    Последнее: 04.06.2013, 20:06
  3. AY:воспроизведение WAV-файла
    от goblinish в разделе Программирование
    Ответов: 35
    Последнее: 10.10.2012, 20:32

Ваши права

  • Вы не можете создавать новые темы
  • Вы не можете отвечать в темах
  • Вы не можете прикреплять вложения
  • Вы не можете редактировать свои сообщения
  •