treewide: remove FSF address
[osmocom-bb.git] / src / target / firmware / include / rffe.h
blob02fc1fdabcf73cc48e3aefe5180db8d4dc107324
1 #ifndef _RFFE_H
2 #define _RFFE_H
4 #include <osmocom/gsm/gsm_utils.h>
6 extern const uint8_t system_inherent_gain;
8 /* initialize RF Frontend */
9 void rffe_init(void);
11 /* switch RF Frontend Mode */
12 void rffe_mode(enum gsm_band band, int tx);
14 /* query RF wiring */
15 enum rffe_port
17 PORT_LO = 0, /* Combined 850/900 port */
18 PORT_HI = 1, /* Combined 1800/1900 port */
19 PORT_GSM850 = 2,
20 PORT_GSM900 = 3,
21 PORT_DCS1800 = 4,
22 PORT_PCS1900 = 5,
25 uint32_t rffe_get_rx_ports(void);
26 uint32_t rffe_get_tx_ports(void);
28 /* IQ swap requirements */
29 int rffe_iq_swapped(uint16_t band_arfcn, int tx);
31 /* get current gain of RF frontend (anything between antenna and baseband in dBm */
32 uint8_t rffe_get_gain(void);
34 void rffe_set_gain(uint8_t dbm);
36 void rffe_compute_gain(int16_t exp_inp, int16_t target_bb);
38 #endif