def LJHash(hashStr, size):
 print ('Hash String:' + str(hashStr))
 outBuff = (ctypes.c_char * 16)()
 retBuff = ''
 staticLib = ctypes.windll.LoadLibrary('labjackud')
 ec = staticLib.LJHash(ctypes.cast(hashStr, ctypes.POINTER(ctypes.c_char)), size, ctypes.cast(outBuff, ctypes.POINTER(ctypes.c_char)), 0)
 if (ec != 0):
  raise LabJackException(ec)
 for i in range(16):
  retBuff += outBuff[i]
 return retBuff

def LJHash ( hashStr , size ) : print ( 'Hash String:' + str ( hashStr ) ) outBuff = ( ctypes . c_char * 16 ) ( ) retBuff = '' staticLib = ctypes . windll . LoadLibrary ( 'labjackud' ) ec = staticLib . LJHash ( ctypes . cast ( hashStr , ctypes . POINTER ( ctypes . c_char ) ) , size , ctypes . cast ( outBuff , ctypes . POINTER ( ctypes . c_char ) ) , 0 ) if ( ec != 0 ) : raise LabJackException ( ec ) for i in range ( 16 ) : retBuff += outBuff [ i ] return retBuff
an approximation of the md5 hashing algorithms .