def load_image(ptr, options, data):
"""Load a JPEG image in the FT800 chip memory.
ptr: Starting address to decompress the image
options: Can be FT800_OPT_RGB565 or FT800_OPT_MONO
data: A list of bytes
Note: An exception is thrown if it fails to load the image in the memory of
the FT800 chip.
"""
length = len(data)
_data = (ctypes.c_uint8 * length)(*data)
ret = _LIB.eve_click_load_image(ptr, options, _data, length)
if ret < 0:
raise Exception("eve click load image failed")
评论列表
文章目录