summaryrefslogtreecommitdiffstats
path: root/src/target/firmware/board
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2011-07-17 09:27:35 +0200
committerAndreas Eversberg <jolly@eversberg.eu>2011-07-17 09:27:35 +0200
commit065b6e35a35e290450f3a7e2958c11cd4fd25131 (patch)
tree257b300e0c049714acc8af22342d9148ee673969 /src/target/firmware/board
parente91dfa950e85d12cb35765670762906bbc6f0846 (diff)
[rf] Adding rffe_set_gain() and rffe_get_gain() to get/set computed gain
rffe_compute_gain() is the new name for rffe_set_gain(). I needed to change this, to solve the name collision with the rffe_set_gain() function, which actually sets the absolute gain. rffe_get_gain() will now read the absolute gain which has been computed by rffe_compute_gain() or set by rffe_set_gain().
Diffstat (limited to 'src/target/firmware/board')
-rw-r--r--src/target/firmware/board/compal/rffe_dualband.c7
-rw-r--r--src/target/firmware/board/gta0x/rffe_gta0x_triband.c7
-rw-r--r--src/target/firmware/board/pirelli_dpl10/rffe_dpl10_triband.c7
3 files changed, 18 insertions, 3 deletions
diff --git a/src/target/firmware/board/compal/rffe_dualband.c b/src/target/firmware/board/compal/rffe_dualband.c
index 152f31ba..f4b73618 100644
--- a/src/target/firmware/board/compal/rffe_dualband.c
+++ b/src/target/firmware/board/compal/rffe_dualband.c
@@ -82,11 +82,16 @@ uint8_t rffe_get_gain(void)
return trf6151_get_gain();
}
+void rffe_set_gain(uint8_t dbm)
+{
+ trf6151_set_gain(dbm);
+}
+
const uint8_t system_inherent_gain = SYSTEM_INHERENT_GAIN;
/* Given the expected input level of exp_inp dBm/8 and the target of target_bb
* dBm8, configure the RF Frontend with the respective gain */
-void rffe_set_gain(int16_t exp_inp, int16_t target_bb)
+void rffe_compute_gain(int16_t exp_inp, int16_t target_bb)
{
trf6151_compute_gain(exp_inp, target_bb);
}
diff --git a/src/target/firmware/board/gta0x/rffe_gta0x_triband.c b/src/target/firmware/board/gta0x/rffe_gta0x_triband.c
index 63f15137..f118d291 100644
--- a/src/target/firmware/board/gta0x/rffe_gta0x_triband.c
+++ b/src/target/firmware/board/gta0x/rffe_gta0x_triband.c
@@ -111,11 +111,16 @@ uint8_t rffe_get_gain(void)
return trf6151_get_gain();
}
+void rffe_set_gain(uint8_t dbm)
+{
+ trf6151_set_gain(dbm);
+}
+
const uint8_t system_inherent_gain = SYSTEM_INHERENT_GAIN;
/* Given the expected input level of exp_inp dBm/8 and the target of target_bb
* dBm8, configure the RF Frontend with the respective gain */
-void rffe_set_gain(int16_t exp_inp, int16_t target_bb)
+void rffe_compute_gain(int16_t exp_inp, int16_t target_bb)
{
trf6151_compute_gain(exp_inp, target_bb);
}
diff --git a/src/target/firmware/board/pirelli_dpl10/rffe_dpl10_triband.c b/src/target/firmware/board/pirelli_dpl10/rffe_dpl10_triband.c
index 00f10892..d4d13424 100644
--- a/src/target/firmware/board/pirelli_dpl10/rffe_dpl10_triband.c
+++ b/src/target/firmware/board/pirelli_dpl10/rffe_dpl10_triband.c
@@ -116,11 +116,16 @@ uint8_t rffe_get_gain(void)
return trf6151_get_gain();
}
+void rffe_set_gain(uint8_t dbm)
+{
+ trf6151_set_gain(dbm);
+}
+
const uint8_t system_inherent_gain = SYSTEM_INHERENT_GAIN;
/* Given the expected input level of exp_inp dBm/8 and the target of target_bb
* dBm8, configure the RF Frontend with the respective gain */
-void rffe_set_gain(int16_t exp_inp, int16_t target_bb)
+void rffe_compute_gain(int16_t exp_inp, int16_t target_bb)
{
trf6151_compute_gain(exp_inp, target_bb);
}