Simplex Link¶
Simplex links represent the signal processing chain of a unidirectional communication betweeen a transmitting device and a receiving device, implementing the digital signal processing before digital-to-analog conversion and after analog-to-digital conversion, respectively. They are a combination of a Transmitting Modem and a Receiving Modem.
After a SimplexLink
is added as a
type of Transmitter
to a Device
,
a call to Device.transmit
will be delegated
to TransmittingModem._transmit()
.
Similarly, after a SimplexLink
is added as a
type of Receiver
to a Device
,
a call to Device.receive
will be delegated
to ReceivingModem._receive()
1# Initialize a new simulation considering a single device
2simulation = Simulation()
3tx_device = simulation.new_device(carrier_frequency=1e10)
4rx_device = simulation.new_device(carrier_frequency=1e10)
5
6# Configure the links's waveform
7waveform = RootRaisedCosineWaveform(
8 oversampling_factor=4,
9 symbol_rate=1e6,
10 num_preamble_symbols=16,
11 num_data_symbols=32,
12 modulation_order=64,
13)
14
15# Configure the link to connect both devices
16link = SimplexLink(waveform=waveform)
17link.connect(tx_device, rx_device)
For a detailed description of the transmit and receive routines, refer to the Transmitting Modem and a Receiving Modem of the base classes.
The barebone configuration can be extend by additional components such as
Custom Bit Sources
,
Synchronization
,
Stream Precoding
,
Channel Estimation
,
Symbol Precoding
,
Channel Equalization
and
Bit Encoders
:
1# Configure the links's waveform
2waveform = RootRaisedCosineWaveform(
3 oversampling_factor=4,
4 symbol_rate=1e6,
5 num_preamble_symbols=16,
6 num_data_symbols=32,
7 modulation_order=64,
8)
9
10# Configure the link to connect both devices
11link = SimplexLink(waveform=waveform)
12link.connect(tx_device, rx_device)
13
14# Configure a custom bits source for the modem
15link.bits_source = RandomBitsSource(seed=42)
16
17# Configure the waveform's synchronization routine
18link.waveform.synchronization = SingleCarrierCorrelationSynchronization()
19
20# Add a custom stream precoding to the modem
21link.transmit_signal_coding[0] = ConventionalBeamformer()
22link.receive_signal_coding[0] = ConventionalBeamformer()
23
24# Add a custom symbol precoding to the modem
25link.transmit_symbol_coding[0] = DFT()
26link.receive_symbol_coding[0] = DFT()
27
28# Configure the waveform's channel estimation routine
29link.waveform.channel_estimation = SingleCarrierLeastSquaresChannelEstimation()
30
31# Configure the waveform's channel equalization routine
32link.waveform.channel_equalization = SingleCarrierZeroForcingChannelEqualization()
33
34# Add forward error correction encodings to the transmitted bit stream
35link.encoder_manager.add_encoder(RepetitionEncoder(32, 3))
- class SimplexLink(*args, bits_source=None, selected_transmit_ports=None, selected_receive_ports=None, **kwargs)[source]¶
Bases:
TransmittingModem
,ReceivingModem
Convenience class to manage a simplex communication link between two dedicated devices.
- Parameters:
bits_source (BitsSource, optional) – Source configuration of communication bits transmitted by this modem. Bits are randomly generated by default.
selected_transmit_ports (Sequence[int] | None) – Indices of antenna ports selected for transmission from the operated
Device's
antenna array. If not specified, all available ports will be considered.selected_receive_ports (Sequence[int] | None) – Indices of antenna ports selected for reception from the operated
Device's
antenna array. If not specified, all available ports will be considered.*args – Modem initialization parameters. Refer to
TransmittingModem
andReceivingModem
for further details.**kwargs – Modem initialization parameters. Refer to
TransmittingModem
andReceivingModem
for further details.
- connect(transmitting_device, receiving_device)[source]¶
Connect two devices by this simplex link.
Convenience method that assigns this DSP layer as a transmitter to the transmitting device and as a receiver to the receiving device.
- yaml_tag: Optional[str] = 'SimplexLink'¶
YAML serialization tag