Commit 146bc28d authored by Joanne Hugé's avatar Joanne Hugé

wip

parent 961d41cc
......@@ -480,12 +480,11 @@ static void *send_thread(void *p) {
log_info("SEND_THREAD", "Starting loop");
for(int64_t i = 1;; i++) {
// If we have frames to encode (is there space in TX buffer)
// And if there are frames from trx_write callback to encode
int to_send = s->tx_burst / s->tx_n_channel;
for(int k = 0; k < s->tx_n_channel; k++) {
int to_read = rbuf_read_amount(&trxw_rbuf[k]);
int to_read = rbuf_read_amount(&trxw_rbuf[k]) / IQ_PAYLOAD;
if(to_read < to_send)
to_send = to_read;
}
......@@ -760,7 +759,7 @@ int start(TRXEcpriState * s) {
ecpri_iq_header,
ECPRI_IQ_HEADER + ORAN_HEADER);
for(int i = 0; i < MAX_TX_BURST; i+= PACKET_SIZE)
for(int i = 0; i < MAX_TX_BURST; i++)
memcpy(tx_buf + i * PACKET_SIZE, packet_header, PACKET_HEADER);
start_threads(s);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment