code: def _checksum(data):
          # type: (bytes) -> int
          '''
          A static method to compute the checksum on the ISO.  Note that this is
          *not* a 1's complement checksum; when an addition overflows, the carry
          bit is discarded, not added to the end.
  
          Parameters:
           data - The data to compute the checksum over.
          Returns:
           The checksum of the data.
          '''
          def identity(x):
              # type: (int) -> int
              '''
              The identity function so we can use a function for python2/3
              compatibility.
              '''
              return x
  
          if isinstance(data, str):
              myord = ord
          elif isinstance(data, bytes):
              myord = identity
          s = 0
          for i in range(0, len(data), 2):
              w = myord(data[i]) + (myord(data[i + 1]) << 8)
              s = (s + w) & 0xffff
          return f _checksum(data):
          # type: (bytes) -> int
          '''
          A static method to compute the checksum on the ISO.  Note that this is
          *not* a 1's complement checksum; when an addition overflows, the carry
          bit is discarded, not added to the end.
  
          Parameters:
           data - The data to compute the checksum over.
          Returns:
           The checksum of the data.
          '''
          def identity(x):
              # type: (int) -> int
              '''
              The identity function so we can use a function for python2/3
              compatibility.
              '''
              return x
  
          if isinstance(data, str):
              myord = ord
          elif isinstance(data, bytes):
              myord = identity
          s = 0
          for i in range(0, len(data), 2):
              w = myord(data[i]) + (myord(data[i + 1]) << 8)
              s = (s + w) & 0xffff
          return s
docs: A static method to compute the checksum on the ISO.  Note that this is
          *not* a 1's complement checksum; when an addition overflows, the carry
          bit is discarded, not added to the end.
  
          Parameters:
           data - The data to compute the checksum over.
          Returns:
           The checksum of the data.