mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-25 01:18:38 -05:00
Removed all remaining references to remote UDP Tx delay
This commit is contained in:
parent
20ed490018
commit
ef4b54a7b1
@ -85,7 +85,6 @@ void RemoteSinkSender::sendDataBlock(RemoteDataBlock *dataBlock)
|
||||
|
||||
uint16_t frameIndex = dataBlock->m_txControlBlock.m_frameIndex;
|
||||
int nbBlocksFEC = dataBlock->m_txControlBlock.m_nbBlocksFEC;
|
||||
int txDelay = dataBlock->m_txControlBlock.m_txDelay;
|
||||
m_address.setAddress(dataBlock->m_txControlBlock.m_dataAddress);
|
||||
uint16_t dataPort = dataBlock->m_txControlBlock.m_dataPort;
|
||||
RemoteSuperBlock *txBlockx = dataBlock->m_superBlocks;
|
||||
@ -94,11 +93,8 @@ void RemoteSinkSender::sendDataBlock(RemoteDataBlock *dataBlock)
|
||||
{
|
||||
if (m_socket)
|
||||
{
|
||||
for (int i = 0; i < RemoteNbOrginalBlocks; i++)
|
||||
{
|
||||
// send block via UDP
|
||||
for (int i = 0; i < RemoteNbOrginalBlocks; i++) { // send block via UDP
|
||||
m_socket->writeDatagram((const char*)&txBlockx[i], (qint64 ) RemoteUdpSize, m_address, dataPort);
|
||||
std::this_thread::sleep_for(std::chrono::microseconds(txDelay));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -139,11 +135,8 @@ void RemoteSinkSender::sendDataBlock(RemoteDataBlock *dataBlock)
|
||||
// Transmit all blocks
|
||||
if (m_socket)
|
||||
{
|
||||
for (int i = 0; i < cm256Params.OriginalCount + cm256Params.RecoveryCount; i++)
|
||||
{
|
||||
// send block via UDP
|
||||
for (int i = 0; i < cm256Params.OriginalCount + cm256Params.RecoveryCount; i++) { // send block via UDP
|
||||
m_socket->writeDatagram((const char*)&txBlockx[i], (qint64 ) RemoteUdpSize, m_address, dataPort);
|
||||
std::this_thread::sleep_for(std::chrono::microseconds(txDelay));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -36,7 +36,6 @@ RemoteSinkSink::RemoteSinkSink() :
|
||||
m_frequencyOffset(0),
|
||||
m_basebandSampleRate(48000),
|
||||
m_nbBlocksFEC(0),
|
||||
m_txDelay(35),
|
||||
m_dataAddress("127.0.0.1"),
|
||||
m_dataPort(9090)
|
||||
{
|
||||
@ -165,7 +164,6 @@ void RemoteSinkSink::feed(const SampleVector::const_iterator& begin, const Sampl
|
||||
m_dataBlock->m_txControlBlock.m_processed = false;
|
||||
m_dataBlock->m_txControlBlock.m_complete = true;
|
||||
m_dataBlock->m_txControlBlock.m_nbBlocksFEC = m_nbBlocksFEC;
|
||||
m_dataBlock->m_txControlBlock.m_txDelay = m_txDelay;
|
||||
m_dataBlock->m_txControlBlock.m_dataAddress = m_dataAddress;
|
||||
m_dataBlock->m_txControlBlock.m_dataPort = m_dataPort;
|
||||
|
||||
|
@ -61,7 +61,6 @@ private:
|
||||
int64_t m_frequencyOffset;
|
||||
uint32_t m_basebandSampleRate;
|
||||
int m_nbBlocksFEC;
|
||||
int m_txDelay;
|
||||
QString m_dataAddress;
|
||||
uint16_t m_dataPort;
|
||||
|
||||
|
@ -68,8 +68,7 @@ LocalInputGui::LocalInputGui(DeviceUISet *deviceUISet, QWidget* parent) :
|
||||
m_countUnrecoverable(0),
|
||||
m_countRecovered(0),
|
||||
m_doApplySettings(true),
|
||||
m_forceSettings(true),
|
||||
m_txDelay(0.0)
|
||||
m_forceSettings(true)
|
||||
{
|
||||
m_paletteGreenText.setColor(QPalette::WindowText, Qt::green);
|
||||
m_paletteWhiteText.setColor(QPalette::WindowText, Qt::white);
|
||||
|
@ -92,7 +92,6 @@ private:
|
||||
|
||||
bool m_doApplySettings;
|
||||
bool m_forceSettings;
|
||||
double m_txDelay;
|
||||
|
||||
QPalette m_paletteGreenText;
|
||||
QPalette m_paletteWhiteText;
|
||||
|
@ -68,8 +68,7 @@ RemoteInputGui::RemoteInputGui(DeviceUISet *deviceUISet, QWidget* parent) :
|
||||
m_countUnrecoverable(0),
|
||||
m_countRecovered(0),
|
||||
m_doApplySettings(true),
|
||||
m_forceSettings(true),
|
||||
m_txDelay(0.0)
|
||||
m_forceSettings(true)
|
||||
{
|
||||
m_paletteGreenText.setColor(QPalette::WindowText, Qt::green);
|
||||
m_paletteWhiteText.setColor(QPalette::WindowText, Qt::white);
|
||||
|
@ -94,7 +94,6 @@ private:
|
||||
|
||||
bool m_doApplySettings;
|
||||
bool m_forceSettings;
|
||||
double m_txDelay;
|
||||
|
||||
QPalette m_paletteGreenText;
|
||||
QPalette m_paletteWhiteText;
|
||||
|
@ -177,7 +177,6 @@ Example of a JSON file (delay is an example you normally do not need it):
|
||||
"reverseAPIPort": 8888,
|
||||
"rgbColor": -7601148,
|
||||
"title": "Channel 0",
|
||||
"txDelay": 0,
|
||||
"useReverseAPI": 0
|
||||
},
|
||||
"channelType": "RemoteSink",
|
||||
|
@ -126,16 +126,15 @@ struct RemoteTxControlBlock
|
||||
bool m_processed;
|
||||
uint16_t m_frameIndex;
|
||||
int m_nbBlocksFEC;
|
||||
int m_txDelay;
|
||||
QString m_dataAddress;
|
||||
uint16_t m_dataPort;
|
||||
|
||||
RemoteTxControlBlock() {
|
||||
RemoteTxControlBlock()
|
||||
{
|
||||
m_complete = false;
|
||||
m_processed = false;
|
||||
m_frameIndex = 0;
|
||||
m_nbBlocksFEC = 0;
|
||||
m_txDelay = 100;
|
||||
m_dataAddress = "127.0.0.1";
|
||||
m_dataPort = 9090;
|
||||
}
|
||||
|
@ -9841,11 +9841,6 @@ margin-bottom: 20px;
|
||||
"sampleRate" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"txDelay" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "minimum delay in ms between two consecutive packets sending"
|
||||
},
|
||||
"nbFECBlocks" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
@ -51601,7 +51596,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2021-12-04T20:19:18.225+01:00
|
||||
Generated 2021-12-07T06:38:29.681+01:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -6,10 +6,6 @@ RemoteOutputSettings:
|
||||
format: int64
|
||||
sampleRate:
|
||||
type: integer
|
||||
txDelay:
|
||||
description: minimum delay in ms between two consecutive packets sending
|
||||
type: number
|
||||
format: float
|
||||
nbFECBlocks:
|
||||
type: integer
|
||||
apiAddress:
|
||||
|
@ -6,10 +6,6 @@ RemoteOutputSettings:
|
||||
format: int64
|
||||
sampleRate:
|
||||
type: integer
|
||||
txDelay:
|
||||
description: minimum delay in ms between two consecutive packets sending
|
||||
type: number
|
||||
format: float
|
||||
nbFECBlocks:
|
||||
type: integer
|
||||
apiAddress:
|
||||
|
@ -9841,11 +9841,6 @@ margin-bottom: 20px;
|
||||
"sampleRate" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"txDelay" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "minimum delay in ms between two consecutive packets sending"
|
||||
},
|
||||
"nbFECBlocks" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
@ -51601,7 +51596,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2021-12-04T20:19:18.225+01:00
|
||||
Generated 2021-12-07T06:38:29.681+01:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -32,8 +32,6 @@ SWGRemoteOutputSettings::SWGRemoteOutputSettings() {
|
||||
m_center_frequency_isSet = false;
|
||||
sample_rate = 0;
|
||||
m_sample_rate_isSet = false;
|
||||
tx_delay = 0.0f;
|
||||
m_tx_delay_isSet = false;
|
||||
nb_fec_blocks = 0;
|
||||
m_nb_fec_blocks_isSet = false;
|
||||
api_address = nullptr;
|
||||
@ -68,8 +66,6 @@ SWGRemoteOutputSettings::init() {
|
||||
m_center_frequency_isSet = false;
|
||||
sample_rate = 0;
|
||||
m_sample_rate_isSet = false;
|
||||
tx_delay = 0.0f;
|
||||
m_tx_delay_isSet = false;
|
||||
nb_fec_blocks = 0;
|
||||
m_nb_fec_blocks_isSet = false;
|
||||
api_address = new QString("");
|
||||
@ -99,7 +95,6 @@ SWGRemoteOutputSettings::cleanup() {
|
||||
|
||||
|
||||
|
||||
|
||||
if(api_address != nullptr) {
|
||||
delete api_address;
|
||||
}
|
||||
@ -133,8 +128,6 @@ SWGRemoteOutputSettings::fromJsonObject(QJsonObject &pJson) {
|
||||
|
||||
::SWGSDRangel::setValue(&sample_rate, pJson["sampleRate"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&tx_delay, pJson["txDelay"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&nb_fec_blocks, pJson["nbFECBlocks"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&api_address, pJson["apiAddress"], "QString", "QString");
|
||||
@ -179,9 +172,6 @@ SWGRemoteOutputSettings::asJsonObject() {
|
||||
if(m_sample_rate_isSet){
|
||||
obj->insert("sampleRate", QJsonValue(sample_rate));
|
||||
}
|
||||
if(m_tx_delay_isSet){
|
||||
obj->insert("txDelay", QJsonValue(tx_delay));
|
||||
}
|
||||
if(m_nb_fec_blocks_isSet){
|
||||
obj->insert("nbFECBlocks", QJsonValue(nb_fec_blocks));
|
||||
}
|
||||
@ -239,16 +229,6 @@ SWGRemoteOutputSettings::setSampleRate(qint32 sample_rate) {
|
||||
this->m_sample_rate_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGRemoteOutputSettings::getTxDelay() {
|
||||
return tx_delay;
|
||||
}
|
||||
void
|
||||
SWGRemoteOutputSettings::setTxDelay(float tx_delay) {
|
||||
this->tx_delay = tx_delay;
|
||||
this->m_tx_delay_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGRemoteOutputSettings::getNbFecBlocks() {
|
||||
return nb_fec_blocks;
|
||||
@ -370,9 +350,6 @@ SWGRemoteOutputSettings::isSet(){
|
||||
if(m_sample_rate_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_tx_delay_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_nb_fec_blocks_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
|
@ -48,9 +48,6 @@ public:
|
||||
qint32 getSampleRate();
|
||||
void setSampleRate(qint32 sample_rate);
|
||||
|
||||
float getTxDelay();
|
||||
void setTxDelay(float tx_delay);
|
||||
|
||||
qint32 getNbFecBlocks();
|
||||
void setNbFecBlocks(qint32 nb_fec_blocks);
|
||||
|
||||
@ -94,9 +91,6 @@ private:
|
||||
qint32 sample_rate;
|
||||
bool m_sample_rate_isSet;
|
||||
|
||||
float tx_delay;
|
||||
bool m_tx_delay_isSet;
|
||||
|
||||
qint32 nb_fec_blocks;
|
||||
bool m_nb_fec_blocks_isSet;
|
||||
|
||||
|
@ -53,7 +53,6 @@ def getInputOptions():
|
||||
parser.add_option("--rmt-address", dest="remote_address", help="RemoteSink: destination data address", metavar="IP_ADDRESS", type="string")
|
||||
parser.add_option("--rmt-port", dest="remote_port", help="RemoteSink: destination data port", metavar="PORT", type="int")
|
||||
parser.add_option("--rmt-fec", dest="remote_fec", help="RemoteSink: number of FEC blocks per frame", metavar="NUMBER", type="int")
|
||||
parser.add_option("--rmt-txdelay", dest="remote_tx_delay", help="RemoteSink: inter block UDP Tx delay percentage", metavar="PERCENT", type="int")
|
||||
|
||||
(options, args) = parser.parse_args()
|
||||
|
||||
@ -326,8 +325,6 @@ def setupChannel(deviceset_url, options):
|
||||
settings["RemoteSinkSettings"]["dataPort"] = options.remote_port
|
||||
if options.remote_fec:
|
||||
settings["RemoteSinkSettings"]["nbFECBlocks"] = options.remote_fec
|
||||
if options.remote_tx_delay:
|
||||
settings["RemoteSinkSettings"]["txDelay"] = options.remote_tx_delay
|
||||
|
||||
r = callAPI(deviceset_url + "/channel/%d/settings" % i, "PATCH", None, settings, "Change demod")
|
||||
if r is None:
|
||||
|
@ -63,7 +63,6 @@
|
||||
"reverseAPIPort": 8888,
|
||||
"rgbColor": -7601148,
|
||||
"title": "Channel 0",
|
||||
"txDelay": 0,
|
||||
"useReverseAPI": 0
|
||||
},
|
||||
"channelType": "RemoteSink",
|
||||
@ -98,7 +97,6 @@
|
||||
"reverseAPIPort": 8888,
|
||||
"rgbColor": -7601148,
|
||||
"title": "Remote sink",
|
||||
"txDelay": 0,
|
||||
"useReverseAPI": 0
|
||||
},
|
||||
"channelType": "RemoteSink",
|
||||
@ -133,7 +131,6 @@
|
||||
"reverseAPIPort": 8888,
|
||||
"rgbColor": -7601148,
|
||||
"title": "Remote sink",
|
||||
"txDelay": 0,
|
||||
"useReverseAPI": 0
|
||||
},
|
||||
"channelType": "RemoteSink",
|
||||
|
Loading…
Reference in New Issue
Block a user