aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bts-trx/loops.h
blob: 978cb7ec27ddc456c404c6fe4636bcd9f879e51d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#ifndef _TRX_LOOPS_H
#define _TRX_LOOPS_H

#include <osmo-bts/scheduler.h>

/*
 * calibration of loops
 */

/* how much power levels do we raise/lower as maximum (1 level = 2 dB) */
#define MS_RAISE_MAX_DB 4
#define MS_LOWER_MAX_DB 8

/*
 * loops api
 */

void trx_loop_sacch_input(struct l1sched_trx *l1t, uint8_t chan_nr,
	struct l1sched_chan_state *chan_state, int8_t rssi, int16_t toa);

void trx_loop_sacch_clock(struct l1sched_trx *l1t, uint8_t chan_nr,
        struct l1sched_chan_state *chan_state);

void trx_loop_amr_input(struct l1sched_trx *l1t, uint8_t chan_nr,
	struct l1sched_chan_state *chan_state,
	int n_errors, int n_bits_total);

void trx_loop_amr_set(struct l1sched_chan_state *chan_state, int loop);

#endif /* _TRX_LOOPS_H */