cocotb 2.0.0rc2__cp311-cp311-macosx_11_0_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of cocotb might be problematic. Click here for more details.
- cocotb/_ANSI.py +65 -0
- cocotb/__init__.py +125 -0
- cocotb/_base_triggers.py +515 -0
- cocotb/_bridge.py +186 -0
- cocotb/_decorators.py +515 -0
- cocotb/_deprecation.py +36 -0
- cocotb/_exceptions.py +7 -0
- cocotb/_extended_awaitables.py +419 -0
- cocotb/_gpi_triggers.py +385 -0
- cocotb/_init.py +301 -0
- cocotb/_outcomes.py +54 -0
- cocotb/_profiling.py +46 -0
- cocotb/_py_compat.py +148 -0
- cocotb/_scheduler.py +448 -0
- cocotb/_test.py +248 -0
- cocotb/_test_factory.py +312 -0
- cocotb/_test_functions.py +42 -0
- cocotb/_typing.py +7 -0
- cocotb/_utils.py +274 -0
- cocotb/_version.py +4 -0
- cocotb/_xunit_reporter.py +66 -0
- cocotb/clock.py +419 -0
- cocotb/debug.py +24 -0
- cocotb/handle.py +1752 -0
- cocotb/libs/libcocotb.so +0 -0
- cocotb/libs/libcocotbfli_modelsim.so +0 -0
- cocotb/libs/libcocotbutils.so +0 -0
- cocotb/libs/libcocotbvhpi_aldec.so +0 -0
- cocotb/libs/libcocotbvhpi_ius.so +0 -0
- cocotb/libs/libcocotbvhpi_modelsim.so +0 -0
- cocotb/libs/libcocotbvhpi_nvc.so +0 -0
- cocotb/libs/libcocotbvpi_aldec.so +0 -0
- cocotb/libs/libcocotbvpi_dsim.so +0 -0
- cocotb/libs/libcocotbvpi_ghdl.so +0 -0
- cocotb/libs/libcocotbvpi_icarus.vpl +0 -0
- cocotb/libs/libcocotbvpi_ius.so +0 -0
- cocotb/libs/libcocotbvpi_modelsim.so +0 -0
- cocotb/libs/libcocotbvpi_vcs.so +0 -0
- cocotb/libs/libcocotbvpi_verilator.so +0 -0
- cocotb/libs/libembed.so +0 -0
- cocotb/libs/libgpi.so +0 -0
- cocotb/libs/libgpilog.so +0 -0
- cocotb/libs/libpygpilog.so +0 -0
- cocotb/logging.py +424 -0
- cocotb/py.typed +0 -0
- cocotb/queue.py +225 -0
- cocotb/regression.py +896 -0
- cocotb/result.py +38 -0
- cocotb/share/def/.gitignore +2 -0
- cocotb/share/def/README.md +4 -0
- cocotb/share/def/aldec.def +61 -0
- cocotb/share/def/ghdl.def +43 -0
- cocotb/share/def/icarus.def +43 -0
- cocotb/share/def/modelsim.def +138 -0
- cocotb/share/include/cocotb_utils.h +70 -0
- cocotb/share/include/embed.h +33 -0
- cocotb/share/include/exports.h +20 -0
- cocotb/share/include/gpi.h +459 -0
- cocotb/share/include/gpi_logging.h +291 -0
- cocotb/share/include/py_gpi_logging.h +33 -0
- cocotb/share/include/vhpi_user_ext.h +26 -0
- cocotb/share/include/vpi_user_ext.h +33 -0
- cocotb/share/lib/verilator/verilator.cpp +209 -0
- cocotb/simtime.py +230 -0
- cocotb/simulator.cpython-311-darwin.so +0 -0
- cocotb/simulator.pyi +107 -0
- cocotb/task.py +590 -0
- cocotb/triggers.py +67 -0
- cocotb/types/__init__.py +31 -0
- cocotb/types/_abstract_array.py +151 -0
- cocotb/types/_array.py +295 -0
- cocotb/types/_indexing.py +17 -0
- cocotb/types/_logic.py +333 -0
- cocotb/types/_logic_array.py +868 -0
- cocotb/types/_range.py +197 -0
- cocotb/types/_resolve.py +76 -0
- cocotb/utils.py +110 -0
- cocotb-2.0.0rc2.dist-info/METADATA +60 -0
- cocotb-2.0.0rc2.dist-info/RECORD +115 -0
- cocotb-2.0.0rc2.dist-info/WHEEL +5 -0
- cocotb-2.0.0rc2.dist-info/entry_points.txt +2 -0
- cocotb-2.0.0rc2.dist-info/licenses/LICENSE +29 -0
- cocotb-2.0.0rc2.dist-info/top_level.txt +23 -0
- cocotb_tools/__init__.py +0 -0
- cocotb_tools/_coverage.py +33 -0
- cocotb_tools/_vendor/__init__.py +3 -0
- cocotb_tools/_vendor/distutils_version.py +346 -0
- cocotb_tools/check_results.py +65 -0
- cocotb_tools/combine_results.py +152 -0
- cocotb_tools/config.py +241 -0
- cocotb_tools/ipython_support.py +99 -0
- cocotb_tools/makefiles/Makefile.deprecations +27 -0
- cocotb_tools/makefiles/Makefile.inc +198 -0
- cocotb_tools/makefiles/Makefile.sim +96 -0
- cocotb_tools/makefiles/simulators/Makefile.activehdl +72 -0
- cocotb_tools/makefiles/simulators/Makefile.cvc +61 -0
- cocotb_tools/makefiles/simulators/Makefile.dsim +39 -0
- cocotb_tools/makefiles/simulators/Makefile.ghdl +84 -0
- cocotb_tools/makefiles/simulators/Makefile.icarus +80 -0
- cocotb_tools/makefiles/simulators/Makefile.ius +93 -0
- cocotb_tools/makefiles/simulators/Makefile.modelsim +9 -0
- cocotb_tools/makefiles/simulators/Makefile.nvc +60 -0
- cocotb_tools/makefiles/simulators/Makefile.questa +29 -0
- cocotb_tools/makefiles/simulators/Makefile.questa-compat +143 -0
- cocotb_tools/makefiles/simulators/Makefile.questa-qisqrun +149 -0
- cocotb_tools/makefiles/simulators/Makefile.riviera +144 -0
- cocotb_tools/makefiles/simulators/Makefile.vcs +65 -0
- cocotb_tools/makefiles/simulators/Makefile.verilator +79 -0
- cocotb_tools/makefiles/simulators/Makefile.xcelium +104 -0
- cocotb_tools/py.typed +0 -0
- cocotb_tools/runner.py +1868 -0
- cocotb_tools/sim_versions.py +140 -0
- pygpi/__init__.py +0 -0
- pygpi/entry.py +42 -0
- pygpi/py.typed +0 -0
cocotb/simtime.py
ADDED
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
# Copyright cocotb contributors
|
|
2
|
+
# Copyright (c) 2013 Potential Ventures Ltd
|
|
3
|
+
# Copyright (c) 2013 SolarFlare Communications Inc
|
|
4
|
+
# Licensed under the Revised BSD License, see LICENSE for details.
|
|
5
|
+
# SPDX-License-Identifier: BSD-3-Clause
|
|
6
|
+
|
|
7
|
+
"""Tools for dealing with simulated time."""
|
|
8
|
+
|
|
9
|
+
import warnings
|
|
10
|
+
from decimal import Decimal
|
|
11
|
+
from fractions import Fraction
|
|
12
|
+
from functools import lru_cache
|
|
13
|
+
from math import ceil, floor
|
|
14
|
+
from typing import Union, cast, overload
|
|
15
|
+
|
|
16
|
+
from cocotb import simulator
|
|
17
|
+
from cocotb._py_compat import Literal, TypeAlias
|
|
18
|
+
from cocotb._typing import RoundMode, TimeUnit
|
|
19
|
+
|
|
20
|
+
__all__ = (
|
|
21
|
+
"convert",
|
|
22
|
+
"get_sim_time",
|
|
23
|
+
"time_precision",
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
Steps: TypeAlias = Literal["step"]
|
|
28
|
+
TimeUnitWithoutSteps: TypeAlias = Literal["fs", "ps", "ns", "us", "ms", "sec"]
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
@overload
|
|
32
|
+
def convert(
|
|
33
|
+
value: Union[float, Fraction, Decimal],
|
|
34
|
+
unit: TimeUnit,
|
|
35
|
+
*,
|
|
36
|
+
to: Steps,
|
|
37
|
+
round_mode: RoundMode = "error",
|
|
38
|
+
) -> int: ...
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
@overload
|
|
42
|
+
def convert(
|
|
43
|
+
value: Union[float, Fraction, Decimal],
|
|
44
|
+
unit: TimeUnit,
|
|
45
|
+
*,
|
|
46
|
+
to: TimeUnitWithoutSteps,
|
|
47
|
+
round_mode: RoundMode = "error",
|
|
48
|
+
) -> float: ...
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
def convert(
|
|
52
|
+
value: Union[float, Decimal, Fraction],
|
|
53
|
+
unit: TimeUnit,
|
|
54
|
+
*,
|
|
55
|
+
to: TimeUnit,
|
|
56
|
+
round_mode: RoundMode = "error",
|
|
57
|
+
) -> float:
|
|
58
|
+
"""Convert time values from one unit to another unit.
|
|
59
|
+
|
|
60
|
+
Args:
|
|
61
|
+
value: The time value.
|
|
62
|
+
|
|
63
|
+
unit: The unit of *value* (one of ``'step'``, ``'fs'``, ``'ps'``, ``'ns'``, ``'us'``, ``'ms'``, ``'sec'``).
|
|
64
|
+
|
|
65
|
+
to: The unit to convert *value* to (one of ``'step'``, ``'fs'``, ``'ps'``, ``'ns'``, ``'us'``, ``'ms'``, ``'sec'``).
|
|
66
|
+
|
|
67
|
+
round_mode:
|
|
68
|
+
How to handle non-integral step values (one of ``'error'``, ``'round'``, ``'ceil'``, ``'floor'``).
|
|
69
|
+
|
|
70
|
+
When *round_mode* is ``"error"``, a :exc:`ValueError` is thrown if the value cannot
|
|
71
|
+
be accurately represented in terms of simulator time steps.
|
|
72
|
+
When *round_mode* is ``"round"``, ``"ceil"``, or ``"floor"``, the corresponding
|
|
73
|
+
rounding function from the standard library will be used to round to a simulator
|
|
74
|
+
time step.
|
|
75
|
+
|
|
76
|
+
Returns:
|
|
77
|
+
The value scaled by the difference in units.
|
|
78
|
+
|
|
79
|
+
.. versionadded:: 2.0
|
|
80
|
+
"""
|
|
81
|
+
if unit == "step":
|
|
82
|
+
steps = cast("int", value)
|
|
83
|
+
else:
|
|
84
|
+
steps = _get_sim_steps(value, unit, round_mode=round_mode)
|
|
85
|
+
if to == "step":
|
|
86
|
+
return steps
|
|
87
|
+
else:
|
|
88
|
+
return _get_time_from_sim_steps(steps, to)
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
def get_sim_time(unit: TimeUnit = "step", *, units: None = None) -> float:
|
|
92
|
+
"""Retrieve the simulation time from the simulator.
|
|
93
|
+
|
|
94
|
+
Args:
|
|
95
|
+
unit: String specifying the unit of the result
|
|
96
|
+
(one of ``'step'``, ``'fs'``, ``'ps'``, ``'ns'``, ``'us'``, ``'ms'``, ``'sec'``).
|
|
97
|
+
``'step'`` will return the raw simulation time.
|
|
98
|
+
|
|
99
|
+
.. versionchanged:: 2.0
|
|
100
|
+
Passing ``None`` as the *unit* argument was removed, use ``'step'`` instead.
|
|
101
|
+
|
|
102
|
+
.. versionchanged:: 2.0
|
|
103
|
+
Renamed from ``units``.
|
|
104
|
+
|
|
105
|
+
Raises:
|
|
106
|
+
ValueError: If *unit* is not a valid unit.
|
|
107
|
+
|
|
108
|
+
Returns:
|
|
109
|
+
The simulation time in the specified unit.
|
|
110
|
+
|
|
111
|
+
.. versionchanged:: 1.6
|
|
112
|
+
Support ``'step'`` as the the *unit* argument to mean "simulator time step".
|
|
113
|
+
|
|
114
|
+
.. versionchanged:: 2.0
|
|
115
|
+
Moved from :mod:`cocotb.utils` to :mod:`cocotb.simtime`.
|
|
116
|
+
"""
|
|
117
|
+
if units is not None:
|
|
118
|
+
warnings.warn(
|
|
119
|
+
"The 'units' argument has been renamed to 'unit'.",
|
|
120
|
+
DeprecationWarning,
|
|
121
|
+
stacklevel=2,
|
|
122
|
+
)
|
|
123
|
+
unit = units
|
|
124
|
+
timeh, timel = simulator.get_sim_time()
|
|
125
|
+
steps = timeh << 32 | timel
|
|
126
|
+
return _get_time_from_sim_steps(steps, unit) if unit != "step" else steps
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
@overload
|
|
130
|
+
def _ldexp10(frac: float, exp: int) -> float: ...
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
@overload
|
|
134
|
+
def _ldexp10(frac: Fraction, exp: int) -> Fraction: ...
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
@overload
|
|
138
|
+
def _ldexp10(frac: Decimal, exp: int) -> Decimal: ...
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
def _ldexp10(
|
|
142
|
+
frac: Union[float, Fraction, Decimal], exp: int
|
|
143
|
+
) -> Union[float, Fraction, Decimal]:
|
|
144
|
+
"""Like :func:`math.ldexp`, but base 10."""
|
|
145
|
+
# using * or / separately prevents rounding errors if `frac` is a
|
|
146
|
+
# high-precision type
|
|
147
|
+
if exp > 0:
|
|
148
|
+
return frac * (10**exp)
|
|
149
|
+
else:
|
|
150
|
+
return frac / (10**-exp)
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
def _get_time_from_sim_steps(
|
|
154
|
+
steps: int,
|
|
155
|
+
unit: TimeUnit,
|
|
156
|
+
) -> float:
|
|
157
|
+
if unit == "step":
|
|
158
|
+
return steps
|
|
159
|
+
return _ldexp10(steps, time_precision - _get_log_time_scale(unit))
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
def _get_sim_steps(
|
|
163
|
+
time: Union[float, Fraction, Decimal],
|
|
164
|
+
unit: TimeUnit = "step",
|
|
165
|
+
*,
|
|
166
|
+
round_mode: RoundMode = "error",
|
|
167
|
+
) -> int:
|
|
168
|
+
result: Union[float, Fraction, Decimal]
|
|
169
|
+
if unit != "step":
|
|
170
|
+
result = _ldexp10(time, _get_log_time_scale(unit) - time_precision)
|
|
171
|
+
else:
|
|
172
|
+
result = time
|
|
173
|
+
|
|
174
|
+
if round_mode == "error":
|
|
175
|
+
result_rounded = floor(result)
|
|
176
|
+
if result_rounded != result:
|
|
177
|
+
raise ValueError(
|
|
178
|
+
f"Unable to accurately represent {time}({unit}) with the simulator precision of 1e{time_precision}"
|
|
179
|
+
)
|
|
180
|
+
elif round_mode == "ceil":
|
|
181
|
+
result_rounded = ceil(result)
|
|
182
|
+
elif round_mode == "round":
|
|
183
|
+
result_rounded = round(result)
|
|
184
|
+
elif round_mode == "floor":
|
|
185
|
+
result_rounded = floor(result)
|
|
186
|
+
else:
|
|
187
|
+
raise ValueError(f"Invalid round_mode specifier: {round_mode}")
|
|
188
|
+
|
|
189
|
+
return result_rounded
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
@lru_cache(maxsize=None)
|
|
193
|
+
def _get_log_time_scale(unit: TimeUnitWithoutSteps) -> int:
|
|
194
|
+
"""Retrieve the ``log10()`` of the scale factor for a given time unit.
|
|
195
|
+
|
|
196
|
+
Args:
|
|
197
|
+
unit: String specifying the unit
|
|
198
|
+
(one of ``'fs'``, ``'ps'``, ``'ns'``, ``'us'``, ``'ms'``, ``'sec'``).
|
|
199
|
+
|
|
200
|
+
.. versionchanged:: 2.0
|
|
201
|
+
Renamed from ``units``.
|
|
202
|
+
|
|
203
|
+
Raises:
|
|
204
|
+
ValueError: If *unit* is not a valid unit.
|
|
205
|
+
|
|
206
|
+
Returns:
|
|
207
|
+
The ``log10()`` of the scale factor for the time unit.
|
|
208
|
+
"""
|
|
209
|
+
scale = {"fs": -15, "ps": -12, "ns": -9, "us": -6, "ms": -3, "sec": 0}
|
|
210
|
+
|
|
211
|
+
unit_lwr = unit.lower()
|
|
212
|
+
if unit_lwr not in scale:
|
|
213
|
+
raise ValueError(f"Invalid unit ({unit}) provided")
|
|
214
|
+
else:
|
|
215
|
+
return scale[unit_lwr]
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
time_precision: int = _get_log_time_scale("fs")
|
|
219
|
+
"""The precision of time in the current simulation.
|
|
220
|
+
|
|
221
|
+
The value is seconds in powers of tens,
|
|
222
|
+
i.e. ``-15`` is ``10**-15`` seconds or 1 femtosecond.
|
|
223
|
+
|
|
224
|
+
.. versionadded:: 2.0
|
|
225
|
+
"""
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
def _init() -> None:
|
|
229
|
+
global time_precision
|
|
230
|
+
time_precision = simulator.get_precision()
|
|
Binary file
|
cocotb/simulator.pyi
ADDED
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# Copyright cocotb contributors
|
|
2
|
+
# Licensed under the Revised BSD License, see LICENSE for details.
|
|
3
|
+
# SPDX-License-Identifier: BSD-3-Clause
|
|
4
|
+
|
|
5
|
+
# generated with mypy's stubgen script
|
|
6
|
+
|
|
7
|
+
from logging import Logger
|
|
8
|
+
from typing import Any, Callable
|
|
9
|
+
|
|
10
|
+
from cocotb.handle import GPIDiscovery
|
|
11
|
+
|
|
12
|
+
DRIVERS: int
|
|
13
|
+
ENUM: int
|
|
14
|
+
GENARRAY: int
|
|
15
|
+
INTEGER: int
|
|
16
|
+
LOADS: int
|
|
17
|
+
LOGIC: int
|
|
18
|
+
LOGIC_ARRAY: int
|
|
19
|
+
MEMORY: int
|
|
20
|
+
MODULE: int
|
|
21
|
+
NETARRAY: int
|
|
22
|
+
OBJECTS: int
|
|
23
|
+
PACKAGE: int
|
|
24
|
+
REAL: int
|
|
25
|
+
STRING: int
|
|
26
|
+
STRUCTURE: int
|
|
27
|
+
PACKED_STRUCTURE: int
|
|
28
|
+
UNKNOWN: int
|
|
29
|
+
RISING: int
|
|
30
|
+
FALLING: int
|
|
31
|
+
VALUE_CHANGE: int
|
|
32
|
+
RANGE_UP: int
|
|
33
|
+
RANGE_DOWN: int
|
|
34
|
+
RANGE_NO_DIR: int
|
|
35
|
+
|
|
36
|
+
class gpi_cb_hdl:
|
|
37
|
+
def deregister(self) -> None: ...
|
|
38
|
+
def __eq__(self, other: object) -> bool: ...
|
|
39
|
+
def __ne__(self, other: object) -> bool: ...
|
|
40
|
+
def __hash__(self) -> int: ...
|
|
41
|
+
|
|
42
|
+
class gpi_iterator_hdl:
|
|
43
|
+
def __eq__(self, other: object) -> bool: ...
|
|
44
|
+
def __ne__(self, other: object) -> bool: ...
|
|
45
|
+
def __hash__(self) -> int: ...
|
|
46
|
+
def __iter__(self) -> gpi_iterator_hdl: ...
|
|
47
|
+
def __next__(self) -> gpi_sim_hdl: ...
|
|
48
|
+
|
|
49
|
+
class gpi_sim_hdl:
|
|
50
|
+
def get_const(self) -> bool: ...
|
|
51
|
+
def get_definition_file(self) -> str: ...
|
|
52
|
+
def get_definition_name(self) -> str: ...
|
|
53
|
+
def get_handle_by_index(self, index: int) -> gpi_sim_hdl | None: ...
|
|
54
|
+
def get_handle_by_name(
|
|
55
|
+
self, name: str, discovery_method: GPIDiscovery | None = GPIDiscovery.AUTO
|
|
56
|
+
) -> gpi_sim_hdl | None: ...
|
|
57
|
+
def get_indexable(self) -> bool: ...
|
|
58
|
+
def get_name_string(self) -> str: ...
|
|
59
|
+
def get_num_elems(self) -> int: ...
|
|
60
|
+
def get_range(self) -> tuple[int, int, int]: ...
|
|
61
|
+
def get_signal_val_binstr(self) -> str: ...
|
|
62
|
+
def get_signal_val_long(self) -> int: ...
|
|
63
|
+
def get_signal_val_real(self) -> float: ...
|
|
64
|
+
def get_signal_val_str(self) -> bytes: ...
|
|
65
|
+
def get_type(self) -> int: ...
|
|
66
|
+
def get_type_string(self) -> str: ...
|
|
67
|
+
def iterate(self, mode: int) -> gpi_iterator_hdl: ...
|
|
68
|
+
def set_signal_val_binstr(self, action: int, value: str) -> None: ...
|
|
69
|
+
def set_signal_val_int(self, action: int, value: int) -> None: ...
|
|
70
|
+
def set_signal_val_real(self, action: int, value: float) -> None: ...
|
|
71
|
+
def set_signal_val_str(self, action: int, value: bytes) -> None: ...
|
|
72
|
+
def __eq__(self, other: object) -> bool: ...
|
|
73
|
+
def __ne__(self, other: object) -> bool: ...
|
|
74
|
+
def __hash__(self) -> int: ...
|
|
75
|
+
|
|
76
|
+
def get_precision() -> int: ...
|
|
77
|
+
def get_root_handle(name: str | None) -> gpi_sim_hdl | None: ...
|
|
78
|
+
def get_sim_time() -> tuple[int, int]: ...
|
|
79
|
+
def get_simulator_product() -> str: ...
|
|
80
|
+
def get_simulator_version() -> str: ...
|
|
81
|
+
def is_running() -> bool: ...
|
|
82
|
+
def set_gpi_log_level(level: int) -> None: ...
|
|
83
|
+
def package_iterate() -> gpi_iterator_hdl: ...
|
|
84
|
+
def register_nextstep_callback(func: Callable[..., Any], *args: Any) -> gpi_cb_hdl: ...
|
|
85
|
+
def register_readonly_callback(func: Callable[..., Any], *args: Any) -> gpi_cb_hdl: ...
|
|
86
|
+
def register_rwsynch_callback(func: Callable[..., Any], *args: Any) -> gpi_cb_hdl: ...
|
|
87
|
+
def register_timed_callback(
|
|
88
|
+
time: int, func: Callable[..., Any], *args: Any
|
|
89
|
+
) -> gpi_cb_hdl: ...
|
|
90
|
+
def register_value_change_callback(
|
|
91
|
+
signal: gpi_sim_hdl, func: Callable[..., Any], edge: int, *args: Any
|
|
92
|
+
) -> gpi_cb_hdl: ...
|
|
93
|
+
def stop_simulator() -> None: ...
|
|
94
|
+
|
|
95
|
+
class cpp_clock:
|
|
96
|
+
def __init__(self, signal: gpi_sim_hdl) -> None: ...
|
|
97
|
+
def start(
|
|
98
|
+
self, period_steps: int, high_steps: int, start_high: bool, set_action: int
|
|
99
|
+
) -> None: ...
|
|
100
|
+
def stop(self) -> None: ...
|
|
101
|
+
|
|
102
|
+
def clock_create(hdl: gpi_sim_hdl) -> cpp_clock: ...
|
|
103
|
+
def initialize_logger(
|
|
104
|
+
log_func: Callable[[Logger, int, str, int, str, str], None],
|
|
105
|
+
get_logger: Callable[[str], Logger],
|
|
106
|
+
) -> None: ...
|
|
107
|
+
def set_sim_event_callback(sim_event_callback: Callable[[str], None]) -> None: ...
|