def __new__(self):
b = "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"\
" 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"\
" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"\
" 00 00 00 00 00 00 00"
byte_object = bytes([int(a, 16) for a in b.split(" ")])
a = super().__new__(self)
ctypes.memmove(ctypes.addressof(a.set_settings_request),
bytes(byte_object), len(byte_object))
return a
# Should equal 2 for off, 1 for on.
评论列表
文章目录