equal
deleted
inserted
replaced
2 # -*- coding: utf-8 -*- |
2 # -*- coding: utf-8 -*- |
3 # |
3 # |
4 # See COPYING.Runtime file for copyrights details. |
4 # See COPYING.Runtime file for copyrights details. |
5 # |
5 # |
6 |
6 |
7 |
|
8 import ctypes |
7 import ctypes |
9 from ctypes import * |
8 from ctypes import * |
10 from datetime import timedelta as td |
9 from datetime import timedelta as td |
11 |
10 |
12 ctypes.pythonapi.PyString_AsString.argtypes = (ctypes.c_void_p,) |
11 ctypes.pythonapi.PyUnicode_AsUTF8.argtypes = (ctypes.c_void_p,) |
13 ctypes.pythonapi.PyString_AsString.restype = ctypes.POINTER(ctypes.c_char) |
12 ctypes.pythonapi.PyUnicode_AsUTF8.restype = ctypes.POINTER(ctypes.c_char) |
14 |
13 |
15 |
14 |
16 class IEC_STRING(Structure): |
15 class IEC_STRING(Structure): |
17 """ |
16 """ |
18 Must be changed according to changes in iec_types.h |
17 Must be changed according to changes in iec_types.h |