1.1.0版本
This commit is contained in:
25
UniTAP/dev/ports/tx.py
Normal file
25
UniTAP/dev/ports/tx.py
Normal file
@@ -0,0 +1,25 @@
|
||||
from .port import TSIPort, MemoryManager, PortIO, Capturer
|
||||
from .modules.ag.ag import AudioGenerator
|
||||
|
||||
|
||||
class TX(TSIPort):
|
||||
"""
|
||||
Class describe base capabilities of Source (TX - transmitter).
|
||||
This functionality is used by child classes `DPTX` and `HDTX`.
|
||||
You cannot use a class `TX` object directly.
|
||||
"""
|
||||
def __init__(self, port_io: PortIO, memory_manager: MemoryManager, capturer: Capturer):
|
||||
super().__init__(port_io, memory_manager, capturer)
|
||||
|
||||
self.__ag = AudioGenerator(port_io, memory_manager)
|
||||
|
||||
@property
|
||||
def ag(self) -> AudioGenerator:
|
||||
"""
|
||||
|
||||
Should be used to control `AudioGenerator` on Source (TX - transmitter) role.
|
||||
|
||||
Returns:
|
||||
object of `AudioGenerator` type.
|
||||
"""
|
||||
return self.__ag
|
||||
Reference in New Issue
Block a user