@@ -0,0 +1,1098 @@
+from ctypes import *%0A%0ASOFT_DOG_DATA_SIZE = 256%0ASOFT_DOG_LIBRARY = %22win32dll.dll%22%0A%0Adef LOGE(message):%0A%09print message%0A%0Adef LOGI(message):%0A%09print message%0A%0Adef checkSoftDogLibraryIsExist():%0A%09LOGI(SOFT_DOG_LIBRARY + %22 is exist.%22)%0A%09return True%0A%0Adef _readSoftDogData(outBuffer):%0A%0A%09# TODO%0A%09# Check SOFT_DOG_LIBRARY if is exits.%0A%09if not checkSoftDogLibraryIsExist():%0A%09%09return False%0A%0A%09windll = WinDLL(SOFT_DOG_LIBRARY)%0A%09if not windll:%0A%09%09LOGI(%22Load soft dog library: %22 + SOFT_DOG_LIBRARY + %22 failed!!!%22)%0A%09%09return False%0A%09%0A%09LOGE(%22Load soft dog library: %22 + SOFT_DOG_LIBRARY + %22 Success.%22)%0A%0A%09if not windll.DogRead:%0A%09%09LOGE(%22Can not find function entry: DogRead%22)%0A%09%09return False%0A%0A%09dataBytes = c_ulong(90)%0A%09readAddr = c_ulong(0)%0A%09windll.DogRead.argtypes = %5Bc_ulong, c_ulong, c_char_p%5D%0A%09windll.DogRead(dataBytes, readAddr, outBuffer)%0A%0A%09return True%0A%0Adef readSoftDogData():%0A%09softDogData = %22%22%0A%09outBuffer = (c_char * SOFT_DOG_DATA_SIZE)('%5C0')%0A%0A%09if _readSoftDogData(outBuffer):%0A%09%09for item in outBuffer:%0A%09%09%09if item == '%5C0':%0A%09%09%09%09break%0A%09%09%09softDogData = softDogData + item%0A%0A%09return softDogData%0A%0Aprint readSoftDogData()%0A%0A%0A%0A%0A%09%0A

Add read soft dog data function.