35#include <SoDa/MailBox.hxx>
The Baseclass for all SoDa objects, and useful commonly used classes.
The Baseclass for all SoDa thread objects.
ModulationType
modulation selector targets take one of these values
sin/cos oscillator to drive TX signal chain
void doCW(CBufPtr out, FBufPtr envelope)
given a keying envelope, impose it on the CW tone
virtual void subExecGetCommand(CommandPtr cmd)
double tx_sample_rate
sample rate for buffer going to USRP (UHD)
virtual RadioTXPtr getSelfPtr()=0
virtual void subExecRepCommand(CommandPtr cmd)
void execSetCommand(CommandPtr cmd)
handle SET commands from the command channel
unsigned int tx_buffer_size
size of buffer going to USRP
bool beacon_mode
if true, we're transmitting a steady carrier
virtual void subscribeToMailBoxes(const std::vector< MailBoxBasePtr > &mailboxes) final
SoDa Threads must subscribe to at least the control mailbox.
FDatMBox::Subscription cw_subs
subscription handle for cw envelope stream (from CW unit)
CDatMBoxPtr tx_stream
transmit audio stream
virtual void subExecCommand(CommandPtr cmd)
Some hardware radio modules might want to watch or publish to the command mailbox.
CBufPtr cw_buf
working buffer for CW output
CmdMBoxPtr cmd_stream
command stream
Command::ModulationType tx_modulation
current modulation mode
CmdMBox::Subscription cmd_subs
subscription handle for command stream
FDatMBoxPtr cw_env_stream
envelope stream from text-to-CW converter (CW unit)
void execGetCommand(CommandPtr cmd)
execute GET commands from the command channel
void run()
RadioTX run loop: handle commands, and modulate the tx carrier.
virtual void subExecSetCommand(CommandPtr cmd)
QuadratureOscillator CW_osc
CW tone IQ oscillator.
CDatMBox::Subscription tx_subs
subscription handle for transmit audio stream (from BaseBandTX)
bool waiting_to_run_dry
When set, we should send out a report when we run out of CW buffer.
virtual bool put(CBufPtr buf)=0
The TX hardware unit doesn't do much at all.
virtual void init()
Some initialization must occurr after all the components are created.
CBufPtr zero_buf
envelope for dead silence.
FBufPtr zero_env
zero amplitude envelope
void execRepCommand(CommandPtr cmd)
handle Report commands from the command channel
bool tx_enabled
if true, we're transmitting.
RadioTX(ParamsPtr params, const std::string &name)
Constructor for RF Transmit/modulator process.
virtual bool transmitSwitch(bool tx_on)=0
most transmit chains will require multiple stages to enable the transmitter.
FBufPtr beacon_env
steady constant amplitude envelope
float cw_env_amplitude
used to set CW output envelope, constant at 0.7
void setCWFreq(bool usb, double freq)
set the CW tone frequency to generate an IQ stream
The Thread baseclass for all SoDa thread objects.
std::shared_ptr< FBuf > FBufPtr
std::shared_ptr< Params > ParamsPtr
std::shared_ptr< Command > CommandPtr
std::shared_ptr< CmdMBox > CmdMBoxPtr
std::shared_ptr< CDatMBox > CDatMBoxPtr
std::shared_ptr< CBuf > CBufPtr
std::shared_ptr< FDatMBox > FDatMBoxPtr
std::shared_ptr< RadioTX > RadioTXPtr