another question on Free Region Bios Mod.

Discussion in 'Sega Saturn Programming and Development' started by path-neo80, Jun 11, 2015.

  1. path-neo80

    path-neo80 Rising Member

    Joined:
    Jun 10, 2015
    Messages:
    53
    Likes Received:
    1
    Hi, many articles mention a "byteSwapping", before flashing the eprom ... what do you mean? I do use Flowrebuilder and quiet?
    Someone kindly, I would like byteswappare rom bios free region of the saturn properly.
    Obviously everything in due time I have no hurry, though some informazionein more does not hurt.
    thanks
     
  2. phoenixdownita

    phoenixdownita Spirited Member

    Joined:
    Apr 29, 2012
    Messages:
    160
    Likes Received:
    8
    It means that the files floating around are in Little Endian format and if you decide to flash them in an actual EEPROM to use on an actual Saturn you need to byteswap their content and make the files Big Endian prior to flashing them [it is possible that your flashing sw allows to do the conversion at load time, not sure]

    In more details the files floating around although contain valid 16 bits data are stored as:
    LoByteOf16BitWord0,
    HiByteOf16BitWord0,
    LowByteOf16BitWord1
    HiByteOf16BitWord1
    ...

    What the Saturn expects in the EEPROM (which are 16bits by the way) is instead:

    HiByteOf16BitWord0
    LoByteOf16BitWord0
    HiByteOf16BitWord1
    LowByteOf16BitWord1
    ....

    So you see the order of the bytes is swapped. The files are in Little Endian as that is the std format on x86, while the SH-2 processors of the Saturn are Big Endian.

    More info here:
    http://www.scadacore.com/community-support/blogs/software-programming/174-the-trouble-with-endians

    It is possible that there are already byteswapped files floating around, I just don't know.
    Usually the ones I found are not.

    A way to do it in linux is via
    dd if=yourinputfile of=youroutputfile conv=swab
    [swab with a b]

    It also works in windows if you care to install cygwin.

    There are for sure tools that allow you to do it with fancy UIs I just don't know of any on top of my head, when I needed it I learnt to use 'dd swab'.
     
  3. path-neo80

    path-neo80 Rising Member

    Joined:
    Jun 10, 2015
    Messages:
    53
    Likes Received:
    1
    ok, thank you very much, I understood a lot more ', although they are far from understanding what really do, but I think it's inexperience.
    For now I've found who I program an EPROM, memomale (expletive) ... but in his time buying a programmer myself and I have to sbrigare..magari looks more 'simple than necessary. As ll'hex 12c508a for the ps1
     
  4. caius

    caius Rising Member

    Joined:
    Jul 17, 2007
    Messages:
    66
    Likes Received:
    5
    To byteswap means swap the high/even byte ( upper 8 bits from D8 to D15) with low/odd byte (lower 8 bits from D0 to D7).Evey programmer software has this function.
     
    path-neo80 likes this.
  5. Helder

    Helder Site Supporter 2014,2015

    Joined:
    Apr 6, 2013
    Messages:
    981
    Likes Received:
    54
    path-neo80 likes this.
  6. path-neo80

    path-neo80 Rising Member

    Joined:
    Jun 10, 2015
    Messages:
    53
    Likes Received:
    1
    Ok thanks, aid, I solved the mystery ... there are programs apposta..e then I need a programmer EPROM, which supports the chip to flash
    thanks
     
sonicdude10
Draft saved Draft deleted
Insert every image as a...
  1.  0%

Share This Page