diff --git a/b_asic/signal_generator.py b/b_asic/signal_generator.py index 7b25e586083d91366f24278c310227516e9e01e5..58782b96c071b41a02321ef9c3d2f2733839508e 100644 --- a/b_asic/signal_generator.py +++ b/b_asic/signal_generator.py @@ -2,11 +2,18 @@ B-ASIC signal generators These can be used as input to Simulation to algorithmically provide signal values. +Especially, all classes defined here will act as a callable which accepts an integer +time index and returns the value at that time. + +It is worth noting that the standard basic arithmetic operations do work on these, +so one can, e.g., write ``0.5 * Step()`` to get a step input with height 0.5. +This is handled by a number of private generator classes. Check out the source code +if you want more information. """ from math import pi, sin from numbers import Number -from typing import Callable, Sequence +from typing import Sequence class SignalGenerator: diff --git a/docs_sphinx/api/signal_generator.rst b/docs_sphinx/api/signal_generator.rst index 0ca472ce2f1f9bb5d734f6b69e75dcbca4a1618b..b82223196d9015f2d8c4b1d3534114b0f31bcfff 100644 --- a/docs_sphinx/api/signal_generator.rst +++ b/docs_sphinx/api/signal_generator.rst @@ -2,5 +2,10 @@ ``b_asic.signal_generator`` *************************** +.. inheritance-diagram:: b_asic.signal_generator + :parts: 1 + :top-classes: b_asic.signal_generator.SignalGenerator + .. automodule:: b_asic.signal_generator :members: + :show-inheritance: