Get RSSI from received uplink data and send to PCU

This bumps the PCU API version and thus requires a new version of the
code on the sysmoBTS side!
This commit is contained in:
Andreas Eversberg 2013-03-17 16:33:11 +01:00 committed by Harald Welte
parent 4ad8d4d3c0
commit 5cbc7e9167
4 changed files with 11 additions and 5 deletions

View File

@ -5,7 +5,8 @@ int pcu_tx_info_ind(void);
int pcu_tx_rts_req(struct gsm_bts_trx_ts *ts, uint8_t is_ptcch, uint32_t fn,
uint16_t arfcn, uint8_t block_nr);
int pcu_tx_data_ind(struct gsm_bts_trx_ts *ts, uint8_t is_ptcch, uint32_t fn,
uint16_t arfcn, uint8_t block_nr, uint8_t *data, uint8_t len);
uint16_t arfcn, uint8_t block_nr, uint8_t *data, uint8_t len,
int8_t rssi);
int pcu_tx_rach_ind(struct gsm_bts *bts, int16_t qta, uint8_t ra, uint32_t fn);
int pcu_tx_time_ind(uint32_t fn);
int pcu_tx_pag_req(const uint8_t *identity_lv, uint8_t chan_needed);

View File

@ -1,7 +1,7 @@
#ifndef _PCUIF_PROTO_H
#define _PCUIF_PROTO_H
#define PCU_IF_VERSION 0x04
#define PCU_IF_VERSION 0x05
/* msg_type */
#define PCU_IF_MSG_DATA_REQ 0x00 /* send data to given channel */
@ -49,6 +49,7 @@ struct gsm_pcu_if_data {
uint8_t trx_nr;
uint8_t ts_nr;
uint8_t block_nr;
int8_t rssi;
} __attribute__ ((packed));
struct gsm_pcu_if_rts_req {

View File

@ -315,7 +315,8 @@ int pcu_tx_rts_req(struct gsm_bts_trx_ts *ts, uint8_t is_ptcch, uint32_t fn,
}
int pcu_tx_data_ind(struct gsm_bts_trx_ts *ts, uint8_t is_ptcch, uint32_t fn,
uint16_t arfcn, uint8_t block_nr, uint8_t *data, uint8_t len)
uint16_t arfcn, uint8_t block_nr, uint8_t *data, uint8_t len,
int8_t rssi)
{
struct msgb *msg;
struct gsm_pcu_if *pcu_prim;
@ -338,6 +339,7 @@ int pcu_tx_data_ind(struct gsm_bts_trx_ts *ts, uint8_t is_ptcch, uint32_t fn,
data_ind->trx_nr = ts->trx->nr;
data_ind->ts_nr = ts->nr;
data_ind->block_nr = block_nr;
data_ind->rssi = rssi;
memcpy(data_ind->data, data, len);
data_ind->len = len;

View File

@ -787,7 +787,8 @@ static int handle_ph_data_ind(struct femtol1_hdl *fl1, GsmL1_PhDataInd_t *data_i
data_ind->u32Fn, data_ind->u16Arfcn,
data_ind->u8BlockNbr,
data_ind->msgUnitParam.u8Buffer + 1,
data_ind->msgUnitParam.u8Size - 1);
data_ind->msgUnitParam.u8Size - 1,
(int8_t) (data_ind->measParam.fRssi));
break;
case GsmL1_Sapi_Ptcch:
/* PTCCH frame handling */
@ -795,7 +796,8 @@ static int handle_ph_data_ind(struct femtol1_hdl *fl1, GsmL1_PhDataInd_t *data_i
data_ind->u32Fn, data_ind->u16Arfcn,
data_ind->u8BlockNbr,
data_ind->msgUnitParam.u8Buffer,
data_ind->msgUnitParam.u8Size);
data_ind->msgUnitParam.u8Size,
(int8_t) (data_ind->measParam.fRssi));
break;
default:
LOGP(DL1C, LOGL_NOTICE, "Rx PH-DATA.ind for unknown L1 SAPI %s\n",