SDRAngel  4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
Public Member Functions | Public Attributes | Private Attributes | List of all members
leansdr::cstln_transmitter< Tout, Zout > Struct Template Reference

#include <sdr.h>

+ Inheritance diagram for leansdr::cstln_transmitter< Tout, Zout >:
+ Collaboration diagram for leansdr::cstln_transmitter< Tout, Zout >:

Public Member Functions

 cstln_transmitter (scheduler *sch, pipebuf< u8 > &_in, pipebuf< complex< Tout >> &_out)
 
void run ()
 
- Public Member Functions inherited from leansdr::runnable
 runnable (scheduler *_sch, const char *name)
 
- Public Member Functions inherited from leansdr::runnable_common
 runnable_common (const char *_name)
 
virtual ~runnable_common ()
 
virtual void shutdown ()
 

Public Attributes

cstln_lut< hard_ss, 256 > * cstln
 
- Public Attributes inherited from leansdr::runnable_common
const char * name
 

Private Attributes

pipereader< u8in
 
pipewriter< complex< Tout > > out
 

Additional Inherited Members

- Protected Attributes inherited from leansdr::runnable
schedulersch
 

Detailed Description

template<typename Tout, int Zout>
struct leansdr::cstln_transmitter< Tout, Zout >

Definition at line 1606 of file sdr.h.

Constructor & Destructor Documentation

◆ cstln_transmitter()

template<typename Tout , int Zout>
leansdr::cstln_transmitter< Tout, Zout >::cstln_transmitter ( scheduler sch,
pipebuf< u8 > &  _in,
pipebuf< complex< Tout >> &  _out 
)
inline

Definition at line 1610 of file sdr.h.

1612  : runnable(sch, "cstln_transmitter"),
1613  in(_in),
1614  out(_out),
1615  cstln(0)
1616  {
1617  }
runnable(scheduler *_sch, const char *name)
Definition: framework.h:193
cstln_lut< hard_ss, 256 > * cstln
Definition: sdr.h:1608
pipewriter< complex< Tout > > out
Definition: sdr.h:1641
pipereader< u8 > in
Definition: sdr.h:1640
scheduler * sch
Definition: framework.h:199

Member Function Documentation

◆ run()

template<typename Tout , int Zout>
void leansdr::cstln_transmitter< Tout, Zout >::run ( )
inlinevirtual

Reimplemented from leansdr::runnable_common.

Definition at line 1619 of file sdr.h.

References leansdr::fail(), leansdr::complex< T >::im, leansdr::auto_notch< T >::in, leansdr::min(), leansdr::auto_notch< T >::out, leansdr::complex< T >::re, and leansdr::cstln_base::symbols.

1620  {
1621  if (!cstln)
1622  fail("constellation not set");
1623 
1624  int count = min(in.readable(), out.writable());
1625  u8 *pin = in.rd(), *pend = pin + count;
1626  complex<Tout> *pout = out.wr();
1627 
1628  for (; pin < pend; ++pin, ++pout)
1629  {
1630  complex<signed char> *cp = &cstln->symbols[*pin];
1631  pout->re = Zout + cp->re;
1632  pout->im = Zout + cp->im;
1633  }
1634 
1635  in.read(count);
1636  out.written(count);
1637  }
unsigned char u8
Definition: framework.h:453
cstln_lut< hard_ss, 256 > * cstln
Definition: sdr.h:1608
pipewriter< complex< Tout > > out
Definition: sdr.h:1641
void fail(const char *s)
Definition: framework.cpp:11
pipereader< u8 > in
Definition: sdr.h:1640
complex< int8_t > * symbols
Definition: sdr.h:478
void read(unsigned long n)
Definition: framework.h:367
T min(const T &x, const T &y)
Definition: framework.h:440
+ Here is the call graph for this function:

Member Data Documentation

◆ cstln

template<typename Tout , int Zout>
cstln_lut<hard_ss, 256>* leansdr::cstln_transmitter< Tout, Zout >::cstln

Definition at line 1608 of file sdr.h.

◆ in

template<typename Tout , int Zout>
pipereader<u8> leansdr::cstln_transmitter< Tout, Zout >::in
private

Definition at line 1640 of file sdr.h.

◆ out

template<typename Tout , int Zout>
pipewriter<complex<Tout> > leansdr::cstln_transmitter< Tout, Zout >::out
private

Definition at line 1641 of file sdr.h.


The documentation for this struct was generated from the following file: