<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.temlib.org/AtariForumWiki/index.php?action=history&amp;feed=atom&amp;title=STTOMSA</id>
	<title>STTOMSA - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.temlib.org/AtariForumWiki/index.php?action=history&amp;feed=atom&amp;title=STTOMSA"/>
	<link rel="alternate" type="text/html" href="https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;action=history"/>
	<updated>2026-05-02T09:07:56Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.2</generator>
	<entry>
		<id>https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17185&amp;oldid=prev</id>
		<title>&gt;Wongck at 14:23, 12 October 2011</title>
		<link rel="alternate" type="text/html" href="https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17185&amp;oldid=prev"/>
		<updated>2011-10-12T14:23:45Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 10:23, 12 October 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l177&quot;&gt;Line 177:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 177:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back to [[Disk-Imagers]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back to [[Disk-Imagers]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category: Disk Imaging]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category: Disk Imaging &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tools&lt;/ins&gt;]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>&gt;Wongck</name></author>
	</entry>
	<entry>
		<id>https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17184&amp;oldid=prev</id>
		<title>&gt;Wongck at 15:41, 11 October 2011</title>
		<link rel="alternate" type="text/html" href="https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17184&amp;oldid=prev"/>
		<updated>2011-10-11T15:41:16Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 11:41, 11 October 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l177&quot;&gt;Line 177:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 177:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back to [[Disk-Imagers]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Back to [[Disk-Imagers]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category: Disk Imaging]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>&gt;Wongck</name></author>
	</entry>
	<entry>
		<id>https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17183&amp;oldid=prev</id>
		<title>&gt;Zorro 2 at 15:07, 2 November 2006</title>
		<link rel="alternate" type="text/html" href="https://www.temlib.org/AtariForumWiki/index.php?title=STTOMSA&amp;diff=17183&amp;oldid=prev"/>
		<updated>2006-11-02T15:07:11Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
                            ST-to-MSA version 1.0&lt;br /&gt;
&lt;br /&gt;
                            =====================&lt;br /&gt;
&lt;br /&gt;
                         Copyright 1997 Damien Burke &lt;br /&gt;
&lt;br /&gt;
                        email: st@jetman.demon.co.uk&lt;br /&gt;
               WWW: http://www.jetman.demon.co.uk/st/index.html&lt;br /&gt;
		&lt;br /&gt;
  DESCRIPTION&lt;br /&gt;
--===========-----------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
ST-to-MSA converts the .ST disk images used by PaCifiST, the Atari ST&lt;br /&gt;
emulator, into compressed Magic Shadow Archiver (MSA) files.&lt;br /&gt;
&lt;br /&gt;
  DISTRIBUTION&lt;br /&gt;
--============----------------------------------------------------------------&lt;br /&gt;
ST-to-MSA is freeware and unsupported. I take no responsibility for any data&lt;br /&gt;
loss you may suffer (e.g. if you type the wrong filename in and overwrite&lt;br /&gt;
something important). If you find bugs, mail me and I'll fix them. You may do&lt;br /&gt;
what you want with the program provided you include this documentation&lt;br /&gt;
unaltered, and do not alter the program itself.&lt;br /&gt;
&lt;br /&gt;
  USAGE&lt;br /&gt;
--=====-----------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
To use ST-to-MSA, type:&lt;br /&gt;
&lt;br /&gt;
STTOMSA &amp;lt;name of ST input file&amp;gt; &amp;lt;name of MSA output file&amp;gt; [/Q] [/O]&lt;br /&gt;
		&lt;br /&gt;
/Q - quiet mode - no screen output and no pauses for keyboard input&lt;br /&gt;
/O - overwrite - if output file exists, overwrite without prompting&lt;br /&gt;
		&lt;br /&gt;
If /Q is used without /O and an output file exists, it will *not* be&lt;br /&gt;
overwritten and the program will *not* create the archive at all. Both /Q and&lt;br /&gt;
/O, if used, must be *after* the input/output filenames, for example:&lt;br /&gt;
&lt;br /&gt;
STTOMSA INFILE.ST OUTFILE.MSA /Q /O&lt;br /&gt;
&lt;br /&gt;
...creates the OUTFILE.MSA archive from the disk image INFILE.ST without&lt;br /&gt;
any onscreen messages and overwriting the existing OUTFILE.MSA file (if it&lt;br /&gt;
exists).&lt;br /&gt;
&lt;br /&gt;
While creating, a progress bar is displayed. Each block in the bar indicates&lt;br /&gt;
one track converted. Large blocks indicate compressed tracks and smaller&lt;br /&gt;
blocks indicate uncompressed tracks.&lt;br /&gt;
&lt;br /&gt;
  NOTES&lt;br /&gt;
--=====-----------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
ST-to-MSA will return status codes of 0 for success or 1 for failure; you can&lt;br /&gt;
check for these in a batch file by testing ERRORLEVEL or if you are running&lt;br /&gt;
ST-to-MSA from within another program you can check by testing the return code&lt;br /&gt;
you get from the execution.&lt;br /&gt;
&lt;br /&gt;
  SPLITTING DISKS INTO MORE THAN ONE MSA FILE&lt;br /&gt;
--===========================================---------------------------------&lt;br /&gt;
&lt;br /&gt;
One of ST-to-MSA's uses is to enable ST users to use some of the .ST files on&lt;br /&gt;
the net. However, many of these files are images of disks that are quite&lt;br /&gt;
large - it can be difficult to get a PC to format a disk to the appropriate&lt;br /&gt;
size in order to write the .ST image to it, and if that fails, it can be even&lt;br /&gt;
more difficult to try and copy the .ST file over to your ST as it is so large.&lt;br /&gt;
&lt;br /&gt;
So, converting that .ST file to an MSA archive can give you a smaller file to&lt;br /&gt;
deal with, which you can then de-MSA on your real ST. However, the compression&lt;br /&gt;
routine used by MSA is very basic so many disk images will not get any smaller&lt;br /&gt;
when converted to an MSA file. This leaves you back at square one - how do you&lt;br /&gt;
get such a big file onto your ST so you can de-MSA it there?&lt;br /&gt;
&lt;br /&gt;
Answer: split it into two MSA files. If you supply ST-to-MSA with a *second*&lt;br /&gt;
output filename, it will create two separate MSA files - the first holding&lt;br /&gt;
the first half of the disk and the second holding the second half (oddly&lt;br /&gt;
enough). For example, if BIGDEMO.ST is an 800Kb disk (80 tracks, 2 sides, 10&lt;br /&gt;
sectors per track), then the following:&lt;br /&gt;
&lt;br /&gt;
STTOMSA BIGDEMO.ST BIGDEMO1.MSA BIGDEMO2.MSA&lt;br /&gt;
&lt;br /&gt;
...will create two MSA files named BIGDEMO1.MSA and BIGDEMO2.MSA. BIGDEMO1.MSA&lt;br /&gt;
will store tracks 0 to 39 (or 1 to 40 as MSA likes to term them) and&lt;br /&gt;
BIGDEMO2.MSA will store tracks 40 to 79 (or 41 to 80 in MSA-speak). Now it's a&lt;br /&gt;
lot easier to get them across to your ST because you can use standard format&lt;br /&gt;
ST disks (if you have TOS 1.04+) or standard 720Kb PC disks.&lt;br /&gt;
&lt;br /&gt;
  .MSA FILE FORMAT&lt;br /&gt;
--================------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
For those interested, an MSA file is made up as follows:&lt;br /&gt;
&lt;br /&gt;
Header:&lt;br /&gt;
&lt;br /&gt;
Word	ID marker, should be $0E0F&lt;br /&gt;
Word	Sectors per track&lt;br /&gt;
Word	Sides (0 or 1; add 1 to this to get correct number of sides)&lt;br /&gt;
Word	Starting track (0-based)&lt;br /&gt;
Word	Ending track (0-based)&lt;br /&gt;
&lt;br /&gt;
Individual tracks follow the header in alternating side order, e.g. a double&lt;br /&gt;
sided disk is stored as:&lt;br /&gt;
&lt;br /&gt;
TRACK 0, SIDE 0&lt;br /&gt;
TRACK 0, SIDE 1&lt;br /&gt;
TRACK 1, SIDE 0&lt;br /&gt;
TRACK 1, SIDE 1&lt;br /&gt;
TRACK 2, SIDE 0&lt;br /&gt;
TRACK 2, SIDE 1&lt;br /&gt;
&lt;br /&gt;
...and so on. Track blocks are made up as follows:&lt;br /&gt;
&lt;br /&gt;
Word	Data length&lt;br /&gt;
Bytes	Data&lt;br /&gt;
&lt;br /&gt;
If the data length is equal to 512 x the sectors per track value, it is an&lt;br /&gt;
uncompressed track and you can merely copy the data to the appropriate track&lt;br /&gt;
of the disk. However, if the data length value is less than 512 x the sectors&lt;br /&gt;
per track value it is a compressed track.&lt;br /&gt;
&lt;br /&gt;
Compressed tracks use simple a Run Length Encoding (RLE) compression method.&lt;br /&gt;
You can directly copy any data bytes until you find an $E5 byte. This signals&lt;br /&gt;
a compressed run, and is made up as follows:&lt;br /&gt;
&lt;br /&gt;
Byte	Marker - $E5&lt;br /&gt;
Byte	Data byte&lt;br /&gt;
Word	Run length&lt;br /&gt;
&lt;br /&gt;
So, if MSA found six $AA bytes in a row it would encode it as:&lt;br /&gt;
&lt;br /&gt;
$E5AA0006&lt;br /&gt;
&lt;br /&gt;
What happens if there's an actual $E5 byte on the disk? Well, logically&lt;br /&gt;
enough, it is encoded as:&lt;br /&gt;
&lt;br /&gt;
$E5E50001&lt;br /&gt;
&lt;br /&gt;
This is obviously bad news if a disk consists of lots of data like&lt;br /&gt;
$E500E500E500E500... but if MSA makes a track bigger when attempting to&lt;br /&gt;
compress it, it just stores the uncompressed version instead.&lt;br /&gt;
&lt;br /&gt;
MSA only compresses runs of at least 4 identical bytes (after all, it would be&lt;br /&gt;
wasteful to store 4 bytes for a run of only 3 identical bytes!). There is one&lt;br /&gt;
exception to this rule: if a run of 2 or 3 $E5 bytes is found, that is stored&lt;br /&gt;
appropriately enough as a run. Again, it would be wasteful to store 4 bytes&lt;br /&gt;
for every single $E5 byte.&lt;br /&gt;
&lt;br /&gt;
The hacked release of MSA that enables the user to turn off compression&lt;br /&gt;
completely simply stops MSA from trying this compression and produces MSA&lt;br /&gt;
images that are completely uncompressed. This is okay because it is possible&lt;br /&gt;
for MSA to produce such an image anyway, and such images are therefore 100%&lt;br /&gt;
compatible with normal MSA versions (and MSA-to-ST of course).&lt;br /&gt;
&lt;br /&gt;
ST-to-MSA always tries to compress tracks - the time taken to try the&lt;br /&gt;
compression is so small it wasn't worth putting in an option to turn it off.&lt;br /&gt;
&lt;br /&gt;
  .ST FILE FORMAT&lt;br /&gt;
--===============-------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
The file format of the .ST image files used by PaCifiST is simplicity itself;&lt;br /&gt;
they are just straight images of the disk in question, with sectors stored in&lt;br /&gt;
the expected logical order. So, on a sector basis the images run from sector&lt;br /&gt;
0 (bootsector) to however many sectors are on the disk. On a track basis the&lt;br /&gt;
layout is the same as for MSA files but obviously the data is raw, no track&lt;br /&gt;
header or compression or anything like that.&lt;br /&gt;
&lt;br /&gt;
.ST files can be written to real disks using DKC's STImage program for the PC,&lt;br /&gt;
available from my web site (see top of this document). If you have .ST files&lt;br /&gt;
on your real ST you can write them to a disk using ArghBlarg's STTODSK.TTP&lt;br /&gt;
program, also available from my web site.&lt;br /&gt;
&lt;br /&gt;
You can also use STtoMSA's companion program, MSAtoST, to convert MSA files to&lt;br /&gt;
.ST files. That is also available from my web site.&lt;br /&gt;
&lt;br /&gt;
-- &lt;br /&gt;
Damien Burke&lt;br /&gt;
31st May 1997&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Back to [[Disk-Imagers]]&lt;/div&gt;</summary>
		<author><name>&gt;Zorro 2</name></author>
	</entry>
</feed>