def CheckSum( data ):
	"""
	Calculate an ASTM checksum for the supplied data
	
	Arguments:
	data -- whatever you want to calculate a checksum for.
	
	If manually calculating checksums, you need to be mindful of whether or not you want to include
	the <2> (STX) that begins the frame.  Sometimes this is expected, sometimes not.
	
	"""
	
	Output = ''
	Counter = 0
	for char in data:
		Counter += ord( char )		# Sum up all the bytes in the data
	CheckValue = Counter % 256		# Checksum = Sum mod 256
	Output = '%X' % CheckValue
	if len( Output ) == 1:
		Output = '0' + Output
	return Output