|  | @@ -1,11 +1,19 @@
 | 
	
		
			
				|  |  | +# greaseweazle/codec/formats.py
 | 
	
		
			
				|  |  | +#
 | 
	
		
			
				|  |  | +# Written & released by Keir Fraser <keir.xen@gmail.com>
 | 
	
		
			
				|  |  | +#
 | 
	
		
			
				|  |  | +# This is free and unencumbered software released into the public domain.
 | 
	
		
			
				|  |  | +# See the file COPYING for more details, or visit <http://unlicense.org>.
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  from greaseweazle.tools import util
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  class Format:
 | 
	
		
			
				|  |  |      img_compatible = False
 | 
	
		
			
				|  |  |      default_trackset = 'c=0-79:h=0-1'
 | 
	
		
			
				|  |  | +    max_trackset = 'c=0-81:h=0-1'
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
		
			
				|  |  | -        self.tracks = util.TrackSet(self.default_trackset)
 | 
	
		
			
				|  |  | +        self.default_tracks = util.TrackSet(self.default_trackset)
 | 
	
		
			
				|  |  | +        self.max_tracks = util.TrackSet(self.max_trackset)
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  class Format_Amiga_AmigaDOS(Format):
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
	
		
			
				|  | @@ -24,6 +32,15 @@ class Format_IBM_720(Format):
 | 
	
		
			
				|  |  |          self.decode_track = self.fmt.decode_track
 | 
	
		
			
				|  |  |          super().__init__()
 | 
	
		
			
				|  |  |      
 | 
	
		
			
				|  |  | +class Format_IBM_800(Format):
 | 
	
		
			
				|  |  | +    img_compatible = True
 | 
	
		
			
				|  |  | +    def __init__(self):
 | 
	
		
			
				|  |  | +        import greaseweazle.codec.ibm.mfm as m
 | 
	
		
			
				|  |  | +        self.fmt = m.IBM_MFM_800
 | 
	
		
			
				|  |  | +        self.default_revs = m.default_revs
 | 
	
		
			
				|  |  | +        self.decode_track = self.fmt.decode_track
 | 
	
		
			
				|  |  | +        super().__init__()
 | 
	
		
			
				|  |  | +    
 | 
	
		
			
				|  |  |  class Format_IBM_1440(Format):
 | 
	
		
			
				|  |  |      img_compatible = True
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
	
		
			
				|  | @@ -36,6 +53,7 @@ class Format_IBM_1440(Format):
 | 
	
		
			
				|  |  |  class Format_AtariST_360(Format):
 | 
	
		
			
				|  |  |      img_compatible = True
 | 
	
		
			
				|  |  |      default_trackset = 'c=0-79:h=0'
 | 
	
		
			
				|  |  | +    max_trackset = 'c=0-81:h=0'
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
		
			
				|  |  |          import greaseweazle.codec.ibm.mfm as m
 | 
	
		
			
				|  |  |          self.fmt = m.AtariST_SS_9SPT
 | 
	
	
		
			
				|  | @@ -46,6 +64,7 @@ class Format_AtariST_360(Format):
 | 
	
		
			
				|  |  |  class Format_AtariST_400(Format):
 | 
	
		
			
				|  |  |      img_compatible = True
 | 
	
		
			
				|  |  |      default_trackset = 'c=0-79:h=0'
 | 
	
		
			
				|  |  | +    max_trackset = 'c=0-81:h=0'
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
		
			
				|  |  |          import greaseweazle.codec.ibm.mfm as m
 | 
	
		
			
				|  |  |          self.fmt = m.AtariST_10SPT
 | 
	
	
		
			
				|  | @@ -56,6 +75,7 @@ class Format_AtariST_400(Format):
 | 
	
		
			
				|  |  |  class Format_AtariST_440(Format):
 | 
	
		
			
				|  |  |      img_compatible = True
 | 
	
		
			
				|  |  |      default_trackset = 'c=0-79:h=0'
 | 
	
		
			
				|  |  | +    max_trackset = 'c=0-81:h=0'
 | 
	
		
			
				|  |  |      def __init__(self):
 | 
	
		
			
				|  |  |          import greaseweazle.codec.ibm.mfm as m
 | 
	
		
			
				|  |  |          self.fmt = m.AtariST_11SPT
 | 
	
	
		
			
				|  | @@ -100,7 +120,8 @@ formats = {
 | 
	
		
			
				|  |  |      'atarist.440': Format_AtariST_440,
 | 
	
		
			
				|  |  |      'atarist.720': Format_AtariST_720,
 | 
	
		
			
				|  |  |      'atarist.800': Format_AtariST_800,
 | 
	
		
			
				|  |  | -    'atarist.880': Format_AtariST_880
 | 
	
		
			
				|  |  | +    'atarist.880': Format_AtariST_880,
 | 
	
		
			
				|  |  | +    'commodore.1581': Format_IBM_800,
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  def print_formats(f = None):
 |